pub struct RowDescription { /* private fields */ }Expand description
Shared column metadata for a result set.
Created once from RowDescription, shared across all rows via Arc.
Implementations§
Source§impl RowDescription
impl RowDescription
pub fn new(fields: Vec<FieldDescription>) -> Self
pub fn is_empty(&self) -> bool
Sourcepub fn field(&self, idx: usize) -> Option<&FieldDescription>
pub fn field(&self, idx: usize) -> Option<&FieldDescription>
Get field description by index.
Sourcepub fn column_index(&self, name: &str) -> Option<usize>
pub fn column_index(&self, name: &str) -> Option<usize>
Get column index by name.
Sourcepub fn fields(&self) -> &[FieldDescription]
pub fn fields(&self) -> &[FieldDescription]
Iterator over field descriptions.
Trait Implementations§
Source§impl Clone for RowDescription
impl Clone for RowDescription
Source§fn clone(&self) -> RowDescription
fn clone(&self) -> RowDescription
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 RowDescription
impl RefUnwindSafe for RowDescription
impl Send for RowDescription
impl Sync for RowDescription
impl Unpin for RowDescription
impl UnsafeUnpin for RowDescription
impl UnwindSafe for RowDescription
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