pub struct Storage { /* private fields */ }
Expand description
The storage model stores a value, and responds with it upon request. Values are stored and value requests are handled instantantaneously.
Implementations
sourceimpl Storage
impl Storage
pub fn from_value(value: Value) -> Option<Box<dyn ReportableModel>>
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Storage
impl<'de> Deserialize<'de> for Storage
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl DevsModel for Storage
impl DevsModel for Storage
fn events_ext(
&mut self,
incoming_message: &ModelMessage,
services: &mut Services
) -> Result<(), SimulationError>
fn events_int(
&mut self,
services: &mut Services
) -> Result<Vec<ModelMessage>, SimulationError>
fn time_advance(&mut self, time_delta: f64)
fn until_next_event(&self) -> f64
sourceimpl Reportable for Storage
impl Reportable for Storage
sourceimpl SerializableModel for Storage
impl SerializableModel for Storage
impl ReportableModel for Storage
Auto Trait Implementations
impl RefUnwindSafe for Storage
impl Send for Storage
impl Sync for Storage
impl Unpin for Storage
impl UnwindSafe for Storage
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ModelClone for T where
T: 'static + ReportableModel + Clone,
impl<T> ModelClone for T where
T: 'static + ReportableModel + Clone,
fn clone_box(&self) -> Box<dyn ReportableModel>
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more