pub struct ExecutorResult { /* private fields */ }Implementations§
Source§impl ExecutorResult
impl ExecutorResult
Sourcepub fn new(columns: Vec<String>, rows: RowVec) -> Self
pub fn new(columns: Vec<String>, rows: RowVec) -> Self
Create a new memory result with columns and pooled rows
Sourcepub fn with_arc_columns(columns: CompactArc<Vec<String>>, rows: RowVec) -> Self
pub fn with_arc_columns(columns: CompactArc<Vec<String>>, rows: RowVec) -> Self
Create a new memory result with Arc columns (zero-copy)
Create a new memory result with shared rows from cache (zero-copy for rows)
This avoids cloning the entire Vec
Create a new memory result with Arc columns and shared rows (zero-copy for both)
Sourcepub fn with_arc_all(
columns: CompactArc<Vec<String>>,
rows: CompactArc<Vec<Row>>,
) -> Self
pub fn with_arc_all( columns: CompactArc<Vec<String>>, rows: CompactArc<Vec<Row>>, ) -> Self
Create a new memory result with both Arc columns and Arc rows (fully zero-copy) This is the most efficient constructor for cached/shared results
Sourcepub fn with_columns(columns: Vec<String>) -> Self
pub fn with_columns(columns: Vec<String>) -> Self
Create with columns only (no rows yet)
Sourcepub fn with_schema(columns: Vec<String>, rows: RowVec, _schema: Schema) -> Self
pub fn with_schema(columns: Vec<String>, rows: RowVec, _schema: Schema) -> Self
Create with schema
Sourcepub fn into_arc_rows(self) -> CompactArc<Vec<Row>>
pub fn into_arc_rows(self) -> CompactArc<Vec<Row>>
Take rows as CompactArc for zero-copy sharing with joins
Returns CompactArc<Vec
Sourcepub fn set_rows_affected(&mut self, count: i64)
pub fn set_rows_affected(&mut self, count: i64)
Set rows affected (for modification results)
Sourcepub fn set_last_insert_id(&mut self, id: i64)
pub fn set_last_insert_id(&mut self, id: i64)
Set last insert ID
Trait Implementations§
Source§impl QueryResult for ExecutorResult
impl QueryResult for ExecutorResult
Source§fn columns_arc(&self) -> Option<CompactArc<Vec<String>>>
fn columns_arc(&self) -> Option<CompactArc<Vec<String>>>
Returns column names as Arc for zero-copy sharing Read more
Source§fn scan(&self, dest: &mut [Value]) -> Result<()>
fn scan(&self, dest: &mut [Value]) -> Result<()>
Scans the current row into the provided values Read more
Source§fn rows_affected(&self) -> i64
fn rows_affected(&self) -> i64
Returns the number of rows affected by an INSERT, UPDATE, or DELETE Read more
Source§fn last_insert_id(&self) -> i64
fn last_insert_id(&self) -> i64
Returns the last inserted ID for an INSERT operation Read more
Source§fn try_into_arc_rows(&mut self) -> Option<CompactArc<Vec<Row>>>
fn try_into_arc_rows(&mut self) -> Option<CompactArc<Vec<Row>>>
Try to extract all rows as CompactArc<Vec> for zero-copy joins Read more
Source§fn with_aliases(
self: Box<Self>,
aliases: FxHashMap<String, String>,
) -> Box<dyn QueryResult>
fn with_aliases( self: Box<Self>, aliases: FxHashMap<String, String>, ) -> Box<dyn QueryResult>
Sets column aliases for this result Read more
Auto Trait Implementations§
impl Freeze for ExecutorResult
impl RefUnwindSafe for ExecutorResult
impl Send for ExecutorResult
impl Sync for ExecutorResult
impl Unpin for ExecutorResult
impl UnwindSafe for ExecutorResult
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more