ConnBuilder

Struct ConnBuilder 

Source
pub struct ConnBuilder<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> { /* private fields */ }

Implementations§

Source§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>

Source

pub fn with_db_path( self, db_path: PathBuf, ) -> ConnBuilder<PathBuf, STATS_ENABLED, StatsPeriod, FDLimit>

Source

pub fn with_create_if_missing( self, create_if_missing: bool, ) -> ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>

Source

pub fn with_parallelism( self, parallelism: impl Into<usize>, ) -> ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>

Source

pub fn with_mem_budget( self, mem_budget: impl Into<usize>, ) -> ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>

Source

pub fn with_files_limit( self, files_limit: impl Into<i32>, ) -> ConnBuilder<Path, STATS_ENABLED, StatsPeriod, i32>

Source§

impl<Path, FDLimit> ConnBuilder<Path, false, Unspecified, FDLimit>

Source

pub fn enable_stats(self) -> ConnBuilder<Path, true, Unspecified, FDLimit>

Source§

impl<Path, StatsPeriod, FDLimit> ConnBuilder<Path, true, StatsPeriod, FDLimit>

Source

pub fn disable_stats(self) -> ConnBuilder<Path, false, Unspecified, FDLimit>

Source

pub fn with_stats_period( self, stats_period: impl Into<u32>, ) -> ConnBuilder<Path, true, u32, FDLimit>

Source§

impl ConnBuilder<PathBuf, false, Unspecified, i32>

Source

pub fn build(self) -> Result<Arc<DB>, Error>

Source§

impl ConnBuilder<PathBuf, true, Unspecified, i32>

Source

pub fn build(self) -> Result<Arc<DB>, Error>

Source§

impl ConnBuilder<PathBuf, true, u32, i32>

Source

pub fn build(self) -> Result<Arc<DB>, Error>

Trait Implementations§

Source§

impl<Path: Debug, const STATS_ENABLED: bool, StatsPeriod: Debug, FDLimit: Debug> Debug for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for ConnBuilder<Unspecified, false, Unspecified, Unspecified>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> Freeze for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>
where Path: Freeze, FDLimit: Freeze, StatsPeriod: Freeze,

§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> RefUnwindSafe for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>
where Path: RefUnwindSafe, FDLimit: RefUnwindSafe, StatsPeriod: RefUnwindSafe,

§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> Send for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>
where Path: Send, FDLimit: Send, StatsPeriod: Send,

§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> Sync for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>
where Path: Sync, FDLimit: Sync, StatsPeriod: Sync,

§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> Unpin for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>
where Path: Unpin, FDLimit: Unpin, StatsPeriod: Unpin,

§

impl<Path, const STATS_ENABLED: bool, StatsPeriod, FDLimit> UnwindSafe for ConnBuilder<Path, STATS_ENABLED, StatsPeriod, FDLimit>
where Path: UnwindSafe, FDLimit: UnwindSafe, StatsPeriod: UnwindSafe,

Blanket Implementations§

§

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

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Any for T
where T: Any,

Source§

fn into_any(self: Box<T>) -> Box<dyn Any>

Source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Source§

fn type_name(&self) -> &'static str

Source§

impl<T> AnySync for T
where T: Any + Send + Sync,

Source§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Sync + Send>

§

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

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

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

§

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

Mutably borrows from an owned value. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

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

§

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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
§

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

§

type Error = Infallible

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

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

Performs the conversion.
§

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

§

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

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

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

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V