pub struct Rows { /* private fields */ }Expand description
A set of rows returned from a connection.
Implementations§
source§impl Rows
impl Rows
sourcepub async fn next(&mut self) -> Result<Option<Row>>
pub async fn next(&mut self) -> Result<Option<Row>>
Get the next Row returning an error if it failed and
None if there are no more rows.
sourcepub fn column_count(&self) -> i32
pub fn column_count(&self) -> i32
Get the count of columns in this set of rows.
sourcepub fn column_name(&self, idx: i32) -> Option<&str>
pub fn column_name(&self, idx: i32) -> Option<&str>
Fetch the name of the column for the provided column index.
sourcepub fn column_type(&self, idx: i32) -> Result<ValueType>
pub fn column_type(&self, idx: i32) -> Result<ValueType>
Fetch the column type from the provided column index.
sourcepub fn into_stream(self) -> impl Stream<Item = Result<Row>>
pub fn into_stream(self) -> impl Stream<Item = Result<Row>>
Converts current Rows into asynchronous stream, fetching rows one by one. This stream can be further used with futures::StreamExt operators.
Auto Trait Implementations§
impl !RefUnwindSafe for Rows
impl Send for Rows
impl Sync for Rows
impl Unpin for Rows
impl !UnwindSafe for Rows
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> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request