Struct sqlite_collections::ds::map::Map

source ·
pub struct Map<'db, 'tbl, K, V, C>where
    K: Format,
    V: Format,
    C: Savepointable,{ /* private fields */ }
Expand description

Deterministic store set.

Implementations§

source§

impl<K, V, C> Map<'static, 'static, K, V, C>where K: Format, V: Format, C: Savepointable,

source

pub fn open(connection: C) -> Result<Self, OpenError>

source

pub fn unchecked_open(connection: C) -> Self

Open a set without creating it or checking if it exists. This is safe if you call a safe open in (or under) the same transaction or savepoint beforehand.

source§

impl<'db, 'tbl, K, V, C> Map<'db, 'tbl, K, V, C>where K: Format, V: Format, C: Savepointable,

source

pub fn open_with_config( connection: C, config: Config<'db, 'tbl> ) -> Result<Self, OpenError>

source

pub fn unchecked_open_with_config( connection: C, config: Config<'db, 'tbl> ) -> Self

Open a set without creating it or checking if it exists. This is safe if you call a safe open in (or under) the same transaction or savepoint beforehand.

source

pub fn insert( &mut self, key: &K::In, value: &V::In ) -> Result<Option<V::Out>, Error<K, V>>

source

pub fn get(&mut self, key: &K::In) -> Result<Option<V::Out>, Error<K, V>>

source

pub fn contains_key(&mut self, key: &K::In) -> Result<bool, Error<K, V>>

Auto Trait Implementations§

§

impl<'db, 'tbl, K, V, C> RefUnwindSafe for Map<'db, 'tbl, K, V, C>where C: RefUnwindSafe, K: RefUnwindSafe, V: RefUnwindSafe,

§

impl<'db, 'tbl, K, V, C> Send for Map<'db, 'tbl, K, V, C>where C: Send, K: Send, V: Send,

§

impl<'db, 'tbl, K, V, C> Sync for Map<'db, 'tbl, K, V, C>where C: Sync, K: Sync, V: Sync,

§

impl<'db, 'tbl, K, V, C> Unpin for Map<'db, 'tbl, K, V, C>where C: Unpin, K: Unpin, V: Unpin,

§

impl<'db, 'tbl, K, V, C> UnwindSafe for Map<'db, 'tbl, K, V, C>where C: UnwindSafe, K: UnwindSafe, V: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

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

source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.