[−][src]Struct caminos_lib::traffic::Burst
Initialize an amount of messages to send from each server. The traffic will be considered complete when all servers have generated their messages and all of them have been consumed.
Implementations
impl Burst
[src]
pub fn new(arg: TrafficBuilderArgument<'_>) -> Burst
[src]
Trait Implementations
impl Debug for Burst
[src]
impl Quantifiable for Burst
[src]
pub fn total_memory(&self) -> usize
[src]
pub fn print_memory_breakdown(&self)
[src]
pub fn forecast_total_memory(&self) -> usize
[src]
impl Traffic for Burst
[src]
pub fn generate_message(
&mut self,
origin: usize,
cycle: usize,
topology: &Box<dyn Topology>,
rng: &RefCell<StdRng>
) -> Result<Rc<Message>, TrafficError>
[src]
&mut self,
origin: usize,
cycle: usize,
topology: &Box<dyn Topology>,
rng: &RefCell<StdRng>
) -> Result<Rc<Message>, TrafficError>
pub fn probability_per_cycle(&self, server: usize) -> f32
[src]
pub fn try_consume(
&mut self,
message: Rc<Message>,
_cycle: usize,
_topology: &Box<dyn Topology>,
_rng: &RefCell<StdRng>
) -> bool
[src]
&mut self,
message: Rc<Message>,
_cycle: usize,
_topology: &Box<dyn Topology>,
_rng: &RefCell<StdRng>
) -> bool
pub fn is_finished(&self) -> bool
[src]
pub fn should_generate(&self, server: usize, rng: &RefCell<StdRng>) -> bool
[src]
Auto Trait Implementations
impl !RefUnwindSafe for Burst
impl !Send for Burst
impl !Sync for Burst
impl Unpin for Burst
impl !UnwindSafe for Burst
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,