pub struct PickleDbIteratorItem<'a> { /* private fields */ }
Expand description

The object returned in each iteration when iterating over keys and values in PickleDB

Implementations

Get the key

Get the value of the key.

The key is always a string but the value can be of any type. It’s the user’s responsibility to know the value type and give it while calling this method. If the key doesn’t exist or if the type is wrong, None will be returned. Otherwise Some(V) will be returned. Since the values are stored in a serialized way the returned object is not a reference to the value stored in a DB but actually a new instance of it. The method returns Some(V) if deserialization succeeds or None otherwise.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.