Struct dvcompute::simulation::resource::stats::Resource [−][src]
pub struct Resource<S> where
S: QueueStrategy, { /* fields omitted */ }
Expand description
Represents a simple resource that gathers its statistics.
Implementations
Create a new resource by the specified queue storage and initial count, where the latter becomes the capacity as well.
pub fn new_with_max_count(
strategy: S,
count: isize,
max_count: Option<isize>
) -> NewResource<S>
pub fn new_with_max_count(
strategy: S,
count: isize,
max_count: Option<isize>
) -> NewResource<S>
Create a new resource by the specified queue storage, initial count and optional maximum count, i.e. capacity.
Return the current available count of the resource.
Return the statistics for available count of the resource.
Notifies when the count
property changes.
Notifies when the count
property changes.
Return the current utilization count of the resource.
Return the statistics for utilization count of the resource.
Notifies when the util_count
property changes.
Notifies when the util_count
property changes.
Return the current queue length of the resource.
Return the statistics for queue length of the resource.
Notifies when the queue_count
property changes.
Notifies when the queue_count
property changes.
Return the total wait time of the resource.
Return the statistics for wait time of the resource.
Notifies when the wait_time
property changes.
Notifies when the wait_time
property changes.
Triggered when one of the Resource
properties changes.