Skip to main content

FileControl

Enum FileControl 

Source
#[non_exhaustive]
pub enum FileControl<'p> { SizeHint(&'p mut sqlite3_int64), SizeLimit(&'p mut sqlite3_int64), ChunkSize(&'p mut c_int), PersistWal(&'p mut c_int), PowerSafeOverwrite(&'p mut c_int), MMapSize(&'p mut sqlite3_int64), HasMoved(&'p mut c_int), LockTimeout(&'p mut c_int), BlockOnConnect(&'p mut c_int), DataVersion(&'p mut c_uint), ReserveBytes(&'p mut c_int), }
Expand description

Standard File Control Opcodes

See https://sqlite.org/c3ref/c_fcntl_begin_atomic_write.html for explanations of each.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

SizeHint(&'p mut sqlite3_int64)

Give the VFS layer a hint of how large the database file will grow to be during the current transaction.

§

SizeLimit(&'p mut sqlite3_int64)

Used by in-memory VFS that implements sqlite3_deserialize() to set an upper bound on the size of the in-memory database.

§

ChunkSize(&'p mut c_int)

Used to request that the VFS extends and truncates the database file in chunks of a size specified by the user.

§

PersistWal(&'p mut c_int)

Used to set or query the persistent Write Ahead Log setting.

§

PowerSafeOverwrite(&'p mut c_int)

Used to set or query the persistent “powersafe-overwrite” or “PSOW” setting.

§

MMapSize(&'p mut sqlite3_int64)

Used to query or set the maximum number of bytes that will be used for memory-mapped I/O.

§

HasMoved(&'p mut c_int)

Whether or not the file has been renamed, moved, or deleted since it was first opened.

§

LockTimeout(&'p mut c_int)

Used to configure a VFS to block for up to M milliseconds before failing when attempting to obtain a file lock using the xLock or xShmLock methods of the VFS.

§

BlockOnConnect(&'p mut c_int)

Used to configure the VFS to block when taking a SHARED lock to connect to a wal mode database.

§

DataVersion(&'p mut c_uint)

Detect changes to a database file.

§

ReserveBytes(&'p mut c_int)

Used to query or set the reserve bytes

Trait Implementations§

Source§

impl<'p> Debug for FileControl<'p>

Source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<'p> !UnwindSafe for FileControl<'p>

§

impl<'p> Freeze for FileControl<'p>

§

impl<'p> RefUnwindSafe for FileControl<'p>

§

impl<'p> Send for FileControl<'p>

§

impl<'p> Sync for FileControl<'p>

§

impl<'p> Unpin for FileControl<'p>

§

impl<'p> UnsafeUnpin for FileControl<'p>

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where 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 T
where 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 T
where U: Into<T>,

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

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

Source§

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.