Trait ColumnIndex

Source
pub trait ColumnIndex: Copy + Debug {
    // Required method
    fn index(self, statement: &Statement<'_>) -> Result<usize>;
}
Expand description

A type suitable for indexing columns in a prepared statement.

Required Methods§

Source

fn index(self, statement: &Statement<'_>) -> Result<usize>

Identify the ordinal position.

The first column has index 0.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl ColumnIndex for &str

Source§

fn index(self, statement: &Statement<'_>) -> Result<usize>

Source§

impl ColumnIndex for usize

Source§

fn index(self, statement: &Statement<'_>) -> Result<usize>

Implementors§