pub struct QueryResult { /* private fields */ }Expand description
Query result
Implementations§
Source§impl QueryResult
impl QueryResult
Sourcepub fn from_rows(rows: Vec<Vec<Value>>, columns: Vec<ColumnInfo>) -> Self
pub fn from_rows(rows: Vec<Vec<Value>>, columns: Vec<ColumnInfo>) -> Self
Create a new query result from rows and columns
Sourcepub fn from_command(
affected_rows: u64,
command_tag: Option<String>,
_query: String,
) -> Self
pub fn from_command( affected_rows: u64, command_tag: Option<String>, _query: String, ) -> Self
Create a query result from command execution
Sourcepub fn columns(&self) -> &[ColumnInfo]
pub fn columns(&self) -> &[ColumnInfo]
Get columns
Sourcepub fn affected_rows(&self) -> u64
pub fn affected_rows(&self) -> u64
Get affected rows count
Sourcepub fn command_tag(&self) -> Option<&str>
pub fn command_tag(&self) -> Option<&str>
Get command tag
Trait Implementations§
Source§impl Clone for QueryResult
impl Clone for QueryResult
Source§fn clone(&self) -> QueryResult
fn clone(&self) -> QueryResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for QueryResult
impl RefUnwindSafe for QueryResult
impl Send for QueryResult
impl Sync for QueryResult
impl Unpin for QueryResult
impl UnwindSafe for QueryResult
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more