pub struct RunningSimulation { /* private fields */ }Expand description
A running simulation with all engines active.
Implementations§
Source§impl RunningSimulation
impl RunningSimulation
Sourcepub fn engine(&self, node: NodeId) -> &ForwarderEngine
pub fn engine(&self, node: NodeId) -> &ForwarderEngine
Get the engine for a node.
Sourcepub fn engines(&self) -> &[ForwarderEngine]
pub fn engines(&self) -> &[ForwarderEngine]
Get all engines.
Sourcepub fn node_count(&self) -> usize
pub fn node_count(&self) -> usize
Number of nodes in the simulation.
Sourcepub fn add_route(
&self,
node: NodeId,
prefix: &str,
nexthop: NodeId,
) -> Result<()>
pub fn add_route( &self, node: NodeId, prefix: &str, nexthop: NodeId, ) -> Result<()>
Add a FIB route at runtime.
Auto Trait Implementations§
impl Freeze for RunningSimulation
impl !RefUnwindSafe for RunningSimulation
impl Send for RunningSimulation
impl Sync for RunningSimulation
impl Unpin for RunningSimulation
impl !UnwindSafe for RunningSimulation
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