pub trait CandidateData:
Default
+ Clone
+ Debug
+ Default
+ IntoIterator<Item = (Key, DataValue)>
+ Send
+ Sync
+ 'static {
// Required methods
fn get_value(&self, key: &Key) -> Result<DataValue, Error>;
fn get_value_ref(&self, key: &Key) -> Option<&DataValue>;
fn store_value(&mut self, key: &Key, value: DataValue) -> Option<DataValue>;
fn merge(&mut self, other: &Self);
fn keys(&self) -> Vec<Key>;
fn select(&self, keys: &[Key]) -> Vec<DataValue>;
fn remove(&mut self, key: &Key) -> Option<DataValue>;
}
Expand description
Basic trait for the work with the candidate data This trait is used to store and retrive the data for the candidates
Required Methods§
fn get_value_ref(&self, key: &Key) -> Option<&DataValue>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.