pub struct StreamGraphFanout {
pub max_inputs: usize,
pub record_domain_size: u64,
pub left_queue: Buffer<u64>,
pub right_queue: Buffer<u64>,
pub ingested: Counter,
pub left_emitted: Counter,
pub right_emitted: Counter,
}Expand description
Retained verification profile for a source fanning out to two FIFO sinks.
Fields§
§max_inputs: usizeMaximum records admitted by the source.
record_domain_size: u64Exclusive upper bound of record values.
left_queue: Buffer<u64>Left-branch FIFO owner.
right_queue: Buffer<u64>Right-branch FIFO owner.
ingested: CounterSource-admission counter.
left_emitted: CounterLeft-sink emission counter.
right_emitted: CounterRight-sink emission counter.
Implementations§
Source§impl StreamGraphFanout
impl StreamGraphFanout
Sourcepub fn valid_config(capacity: usize, record_domain_size: u64) -> bool
pub fn valid_config(capacity: usize, record_domain_size: u64) -> bool
Test whether the shared queue capacity and value domain are valid.
Sourcepub fn new(
capacity: usize,
max_inputs: usize,
record_domain_size: u64,
) -> StreamGraphFanout
pub fn new( capacity: usize, max_inputs: usize, record_domain_size: u64, ) -> StreamGraphFanout
Construct an empty valid fan-out execution.
Sourcepub fn source_ingest(&mut self, value: u64) -> bool
pub fn source_ingest(&mut self, value: u64) -> bool
Replicate one source record into both branch queues.
Sourcepub fn consume_left(&mut self) -> bool
pub fn consume_left(&mut self) -> bool
Consume one record from the left FIFO branch.
Sourcepub fn consume_right(&mut self) -> bool
pub fn consume_right(&mut self) -> bool
Consume one record from the right FIFO branch.
Auto Trait Implementations§
impl Freeze for StreamGraphFanout
impl RefUnwindSafe for StreamGraphFanout
impl Send for StreamGraphFanout
impl Sync for StreamGraphFanout
impl Unpin for StreamGraphFanout
impl UnsafeUnpin for StreamGraphFanout
impl UnwindSafe for StreamGraphFanout
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