mirror of
https://github.com/fluencelabs/sqlite-wasm-connector
synced 2025-04-24 16:32:12 +00:00
Move the columns method of Cursor
This commit is contained in:
parent
3119f63fec
commit
47e36dc392
@ -20,6 +20,12 @@ impl<'l> Cursor<'l> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Return the number of columns.
|
||||
#[inline]
|
||||
pub fn columns(&self) -> usize {
|
||||
self.statement.columns()
|
||||
}
|
||||
|
||||
/// Advance to the next row and read all columns.
|
||||
pub fn next(&mut self) -> Result<Option<&[Value]>> {
|
||||
match self.state {
|
||||
@ -65,12 +71,6 @@ impl<'l> Cursor<'l> {
|
||||
Ok(Some(self.values.as_ref().unwrap()))
|
||||
}
|
||||
|
||||
/// Return the number of columns.
|
||||
#[inline]
|
||||
pub fn columns(&self) -> usize {
|
||||
self.statement.columns()
|
||||
}
|
||||
|
||||
/// Return the raw pointer.
|
||||
#[inline]
|
||||
pub fn as_raw(&self) -> *mut ffi::sqlite3_stmt {
|
||||
|
Loading…
x
Reference in New Issue
Block a user