Struct dvcompute_results::simulation::results::ResultContainer [−][src]
pub struct ResultContainer<E> {
pub name: ResultName,
pub name_path: Vec<ResultName>,
pub id: ResultId,
pub id_path: Vec<ResultId>,
pub data: Rc<E>,
pub observable: Rc<dyn Fn() -> ResultObservable>,
}
Expand description
A container of the simulation results such as queue, facility or array.
Fields
name: ResultName
The container name.
name_path: Vec<ResultName>
The container name path.
id: ResultId
The container identifier.
id_path: Vec<ResultId>
The container identifier path.
data: Rc<E>
The container data.
observable: Rc<dyn Fn() -> ResultObservable>
Whether the container emits a signal when changing simulation data.
Implementations
Map the contained data by applying the corresponding function.
pub fn raw_prop_source<F1, F2, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F1,
prop_observable: F2
) -> ResultSource where
F1: FnOnce(Rc<E>) -> ResultData<B> + Clone + 'static,
F2: FnOnce(Rc<E>) -> ResultObservable + Clone + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
pub fn raw_prop_source<F1, F2, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F1,
prop_observable: F2
) -> ResultSource where
F1: FnOnce(Rc<E>) -> ResultData<B> + Clone + 'static,
F2: FnOnce(Rc<E>) -> ResultObservable + Clone + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
Create a new raw property source by the specified container.
pub fn raw_prop<F1, F2, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F1,
prop_observable: F2
) -> ResultProperty where
F1: FnOnce(Rc<E>) -> ResultData<B> + Clone + 'static,
F2: FnOnce(Rc<E>) -> ResultObservable + Clone + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
pub fn raw_prop<F1, F2, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F1,
prop_observable: F2
) -> ResultProperty where
F1: FnOnce(Rc<E>) -> ResultData<B> + Clone + 'static,
F2: FnOnce(Rc<E>) -> ResultObservable + Clone + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
Create a new raw property by the specified container.
pub fn const_prop<F, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F
) -> ResultProperty where
F: FnOnce(Rc<E>) -> B + Clone + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
pub fn const_prop<F, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F
) -> ResultProperty where
F: FnOnce(Rc<E>) -> B + Clone + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
Create a new constant property source by the specified container.
pub fn integ_prop<F, M, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F
) -> ResultProperty where
F: FnOnce(Rc<E>) -> M + Clone + 'static,
M: Event<Item = B> + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
pub fn integ_prop<F, M, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F
) -> ResultProperty where
F: FnOnce(Rc<E>) -> M + Clone + 'static,
M: Event<Item = B> + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
Create by the specified container a property that changes in the integration time points,
pub fn prop<F1, F2, M, O, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F1,
prop_observable: F2
) -> ResultProperty where
F1: FnOnce(Rc<E>) -> M + Clone + 'static,
F2: FnOnce(Rc<E>) -> O + Clone + 'static,
M: Event<Item = B> + 'static,
O: Observable<Message = ()> + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
pub fn prop<F1, F2, M, O, B>(
self,
prop_name: &str,
prop_id: ResultId,
prop_data: F1,
prop_observable: F2
) -> ResultProperty where
F1: FnOnce(Rc<E>) -> M + Clone + 'static,
F2: FnOnce(Rc<E>) -> O + Clone + 'static,
M: Event<Item = B> + 'static,
O: Observable<Message = ()> + 'static,
ResultValue<B>: ResultItem,
B: 'static,
E: 'static,
Create a new property by the specified container.
Trait Implementations
Auto Trait Implementations
impl<E> !RefUnwindSafe for ResultContainer<E>
impl<E> !Send for ResultContainer<E>
impl<E> !Sync for ResultContainer<E>
impl<E> Unpin for ResultContainer<E>
impl<E> !UnwindSafe for ResultContainer<E>
Blanket Implementations
Mutably borrows from an owned value. Read more