Struct mdl::bcache::Cache[][src]

pub struct Cache { /* fields omitted */ }

BTreeMap cache. This struct implements the Store trait so it can be used to cache Model structs A BTreeMap is used to store the data in memory. This struct implements clone so it can be shared between threads safely creating a clone

Methods

impl Cache
[src]

Trait Implementations

impl Debug for Cache
[src]

Formats the value using the given formatter. Read more

impl Clone for Cache
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Store for Cache
[src]

Stores the value in the database with the corresponding key

Retrieves the value in the database with the corresponding key Returns an error if the key doesn't exists Read more

Iterates over all objects that starts with the prefix and run the function f. If f returns Continue(false) the iteration stops Read more

Remove the corresponding data in the database by key

Retrieves all items in the database that starts with the prefix key

Auto Trait Implementations

impl Send for Cache

impl Sync for Cache