SQLite VFS Shim
Single header with classes for easily implementing SQLite VFS shims in C++11
|
#include <SQLiteVfs.hpp>
Public Types | |
using | FileImpl = TFileImpl |
Public Member Functions | |
void | setup (int open_result) |
Public Attributes | |
sqlite3_io_methods | methods |
FileImpl | implementation |
sqlite3_file | original_file [0] |
POD sqlite3_file
subclass that forwards all invocations to an embedded object that inherits SQLiteFileImpl
.
You should not create objects of this type manually nor subclass it.
TFileImpl | SQLiteFileImpl subclass |
using sqlitevfs::SQLiteFile< TFileImpl >::FileImpl = TFileImpl |
|
inline |
Setup internal state based on the open_result
flag.
This function is called automatically by SQLiteVfs::wrap_xOpen
. If open_result
is SQLITE_OK
, pMethods
will be populated. Otherwise, pMethods
will be set to NULL and SQLite won't call them.
open_result | A SQLite error code. Pass SQLITE_OK to fully setup the file object. Pass anything else to set pMethods to NULL. |
FileImpl sqlitevfs::SQLiteFile< TFileImpl >::implementation |
File implementation object of the SQLiteFileImpl
subclass passed as template parameter to SQLiteVfsImpl<>
.
sqlite3_io_methods sqlitevfs::SQLiteFile< TFileImpl >::methods |
SQLite IO methods populated by SQLiteFile::setup
.
sqlite3_file sqlitevfs::SQLiteFile< TFileImpl >::original_file[0] |