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
155
156
157
pub fn sqlite3_characters_init(db: *mut sqlite3) -> Result<()> {
define_table_function::<CharactersTable>(db, "characters", None)?;
Ok(())
}
More examples
Hide additional examples
168
169
170
171
pub fn sqlite3_seriesrs_init(db: *mut sqlite3) -> Result<()> {
define_table_function::<GenerateSeriesTable>(db, "generate_series_rs", None)?;
Ok(())
}
24
25
26
27
28
pub fn sqlite3_hello_init(db: *mut sqlite3) -> Result<()> {
let flags = FunctionFlags::UTF8 | FunctionFlags::DETERMINISTIC;
define_scalar_function(db, "hello", 1, hello, flags)?;
Ok(())
}
42
43
44
45
46
47
48
49
pub fn sqlite3_scalarrs_init(db: *mut sqlite3) -> Result<()> {
let flags = FunctionFlags::UTF8 | FunctionFlags::DETERMINISTIC;
define_scalar_function(db, "surround_rs", 1, surround, flags)?;
define_scalar_function(db, "connect", -1, connect, flags)?;
define_scalar_function(db, "yo_rs", 0, yo, flags)?;
define_scalar_function(db, "add_rs", 2, add, flags)?;
Ok(())
}