Function register_entrypoint Copy item path Source pub fn register_entrypoint<F>(
db: *mut sqlite3 ,
_pz_err_msg: *mut *mut c_char ,
p_api: *mut sqlite3_api_routines ,
callback: F,
) -> c_uint Expand description Low-level wrapper around a typical entrypoint to a SQLite extension.
You shouldn’t have to use this directly - the sqlite_entrypoint
macro will do this for you.
154 pub fn sqlite3_characters_init(db: *mut sqlite3) -> Result <()> {
155 define_table_function::<CharactersTable>(db, "characters" , None )? ;
156 Ok (())
157 }More examples Hide additional examples
168 pub fn sqlite3_seriesrs_init(db: *mut sqlite3) -> Result <()> {
169 define_table_function::<GenerateSeriesTable>(db, "generate_series_rs" , None )? ;
170 Ok (())
171 }24 pub fn sqlite3_hello_init(db: *mut sqlite3) -> Result <()> {
25 let flags = FunctionFlags::UTF8 | FunctionFlags::DETERMINISTIC;
26 define_scalar_function(db, "hello" , 1 , hello, flags)? ;
27 Ok (())
28 }42 pub fn sqlite3_scalarrs_init(db: *mut sqlite3) -> Result <()> {
43 let flags = FunctionFlags::UTF8 | FunctionFlags::DETERMINISTIC;
44 define_scalar_function(db, "surround_rs" , 1 , surround, flags)? ;
45 define_scalar_function(db, "connect" , -1 , connect, flags)? ;
46 define_scalar_function(db, "yo_rs" , 0 , yo, flags)? ;
47 define_scalar_function(db, "add_rs" , 2 , add, flags)? ;
48 Ok (())
49 }