Trait SQLiteIoMethods

Source
pub trait SQLiteIoMethods {
    type Store: VfsStore;
    type StoreControl: StoreControl<Self::Store>;

    const VERSION: c_int;
    const METHODS: sqlite3_io_methods = _;

    // Provided methods
    unsafe extern "C" fn xClose(pFile: *mut sqlite3_file) -> c_int { ... }
    unsafe extern "C" fn xRead(
        pFile: *mut sqlite3_file,
        zBuf: *mut c_void,
        iAmt: c_int,
        iOfst: sqlite3_int64,
    ) -> c_int { ... }
    unsafe extern "C" fn xWrite(
        pFile: *mut sqlite3_file,
        zBuf: *const c_void,
        iAmt: c_int,
        iOfst: sqlite3_int64,
    ) -> c_int { ... }
    unsafe extern "C" fn xTruncate(
        pFile: *mut sqlite3_file,
        size: sqlite3_int64,
    ) -> c_int { ... }
    unsafe extern "C" fn xSync(
        _pFile: *mut sqlite3_file,
        _flags: c_int,
    ) -> c_int { ... }
    unsafe extern "C" fn xFileSize(
        pFile: *mut sqlite3_file,
        pSize: *mut sqlite3_int64,
    ) -> c_int { ... }
    unsafe extern "C" fn xLock(
        _pFile: *mut sqlite3_file,
        _eLock: c_int,
    ) -> c_int { ... }
    unsafe extern "C" fn xUnlock(
        _pFile: *mut sqlite3_file,
        _eLock: c_int,
    ) -> c_int { ... }
    unsafe extern "C" fn xCheckReservedLock(
        _pFile: *mut sqlite3_file,
        pResOut: *mut c_int,
    ) -> c_int { ... }
    unsafe extern "C" fn xFileControl(
        _pFile: *mut sqlite3_file,
        _op: c_int,
        _pArg: *mut c_void,
    ) -> c_int { ... }
    unsafe extern "C" fn xSectorSize(
        _pFile: *mut sqlite3_file,
    ) -> c_int { ... }
    unsafe extern "C" fn xDeviceCharacteristics(
        _arg1: *mut sqlite3_file,
    ) -> c_int { ... }
}
Expand description

Abstraction of SQLite vfs’s io methods

Required Associated Constants§

Provided Associated Constants§

Required Associated Types§

Provided Methods§

Source

unsafe extern "C" fn xClose(pFile: *mut sqlite3_file) -> c_int

Source

unsafe extern "C" fn xRead( pFile: *mut sqlite3_file, zBuf: *mut c_void, iAmt: c_int, iOfst: sqlite3_int64, ) -> c_int

Source

unsafe extern "C" fn xWrite( pFile: *mut sqlite3_file, zBuf: *const c_void, iAmt: c_int, iOfst: sqlite3_int64, ) -> c_int

Source

unsafe extern "C" fn xTruncate( pFile: *mut sqlite3_file, size: sqlite3_int64, ) -> c_int

Source

unsafe extern "C" fn xSync( _pFile: *mut sqlite3_file, _flags: c_int, ) -> c_int

Source

unsafe extern "C" fn xFileSize( pFile: *mut sqlite3_file, pSize: *mut sqlite3_int64, ) -> c_int

Source

unsafe extern "C" fn xLock( _pFile: *mut sqlite3_file, _eLock: c_int, ) -> c_int

Source

unsafe extern "C" fn xUnlock( _pFile: *mut sqlite3_file, _eLock: c_int, ) -> c_int

Source

unsafe extern "C" fn xCheckReservedLock( _pFile: *mut sqlite3_file, pResOut: *mut c_int, ) -> c_int

Source

unsafe extern "C" fn xFileControl( _pFile: *mut sqlite3_file, _op: c_int, _pArg: *mut c_void, ) -> c_int

Source

unsafe extern "C" fn xSectorSize(_pFile: *mut sqlite3_file) -> c_int

Source

unsafe extern "C" fn xDeviceCharacteristics( _arg1: *mut sqlite3_file, ) -> c_int

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§