pub fn update(
        &self,
        update_fn: Box<dyn DataUpdater<T>>,
    ) -> Result<(), Box<dyn DataUpdater<T>>> {
        self.update_sender
            .send(VersionedUpdaterAction::Update(update_fn))
            .map_err(|action| match action {
                mpsc::error::SendError(VersionedUpdaterAction::Update(update_fn)) => update_fn,
                _ => panic!("Received illegal error"),
            })
    }
/// Allows the data to be upated by passing the latest version to the provided DataUpdater,
/// and storing the result if one is provided. The update is delegated to the update task,
/// which is also where the DataUpdater will be called.
Allows the data to be upated by passing the latest version to the provided DataUpdater,
and storing the result if one is provided. The update is delegated to the update task,
which is also where the DataUpdater will be called.
Allows the data to be upated by passing the latest version to the provided DataUpdater and storing the result if one is provided . The update is delegated to the update task which is also where the DataUpdater will be called .
pub fn update(
        &self,
        update_fn: Box<dyn DataUpdater<T>>,
    ) -> Result<(), Box<dyn DataUpdater<T>>> {
        self.update_sender
            .send(VersionedUpdaterAction::Update(update_fn))
            .map_err(|action| match action {
                mpsc::error::SendError(VersionedUpdaterAction::Update(update_fn)) => update_fn,
                _ => panic!("Received illegal error"),
            })
    }
pub fn update ( & self , update_fn : Box < dyn DataUpdater < T > > , ) -> Result < ( ) , Box < dyn DataUpdater < T > > > { self . update_sender . send ( VersionedUpdaterAction :: Update ( update_fn ) ) . map_err ( | action | match action { mpsc :: error :: SendError ( VersionedUpdaterAction :: Update ( update_fn ) ) => update_fn , _ => panic ! ( " " ) , } ) }
Allows the data to be upated by passing the latest version to the provided DataUpdater,
and storing the result if one is provided.
Allows the data to be upated by passing the latest version to the provided DataUpdater and storing the result if one is provided .
&self
update_fn
Box<dyn DataUpdater<T>>
&self
update_fn
Box<dyn DataUpdater<T>>