pub struct BACnetRouter { /* private fields */ }Expand description
BACnet router connecting multiple networks.
The router holds multiple ports, each bound to a different BACnet network. When an NPDU arrives on one port with a destination network that maps to another port, the router forwards the message.
Implementations§
Source§impl BACnetRouter
impl BACnetRouter
Sourcepub async fn start<T: TransportPort + 'static>(
ports: Vec<RouterPort<T>>,
) -> Result<(Self, Receiver<ReceivedApdu>), Error>
pub async fn start<T: TransportPort + 'static>( ports: Vec<RouterPort<T>>, ) -> Result<(Self, Receiver<ReceivedApdu>), Error>
Create and start a router from a list of ports.
Returns the router and a receiver for APDUs destined to local applications (messages without remote destination or where this router is the final hop).
Sourcepub fn table(&self) -> &Arc<Mutex<RouterTable>>
pub fn table(&self) -> &Arc<Mutex<RouterTable>>
Get a reference to the routing table.
Auto Trait Implementations§
impl Freeze for BACnetRouter
impl !RefUnwindSafe for BACnetRouter
impl Send for BACnetRouter
impl Sync for BACnetRouter
impl Unpin for BACnetRouter
impl UnsafeUnpin for BACnetRouter
impl !UnwindSafe for BACnetRouter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more