Trait sea_orm::TryGetable

source ยท
pub trait TryGetable: Sized {
    // Required method
    fn try_get_by<I: ColIdx>(
        res: &QueryResult,
        index: I
    ) -> Result<Self, TryGetError>;

    // Provided methods
    fn try_get(
        res: &QueryResult,
        pre: &str,
        col: &str
    ) -> Result<Self, TryGetError> { ... }
    fn try_get_by_index(
        res: &QueryResult,
        index: usize
    ) -> Result<Self, TryGetError> { ... }
}
Expand description

An interface to get a value from the query result

Required Methodsยง

source

fn try_get_by<I: ColIdx>( res: &QueryResult, index: I ) -> Result<Self, TryGetError>

Get a value from the query result with an ColIdx

Provided Methodsยง

source

fn try_get(res: &QueryResult, pre: &str, col: &str) -> Result<Self, TryGetError>

Get a value from the query result with prefixed column name

source

fn try_get_by_index( res: &QueryResult, index: usize ) -> Result<Self, TryGetError>

Get a value from the query result based on the order in the select expressions

Object Safetyยง

This trait is not object safe.

Implementations on Foreign Typesยง

sourceยง

impl TryGetable for bool

sourceยง

impl TryGetable for f32

sourceยง

impl TryGetable for f64

sourceยง

impl TryGetable for i8

sourceยง

impl TryGetable for i16

sourceยง

impl TryGetable for i32

sourceยง

impl TryGetable for i64

sourceยง

impl TryGetable for u8

sourceยง

impl TryGetable for u16

sourceยง

impl TryGetable for u32

sourceยง

impl TryGetable for u64

sourceยง

impl TryGetable for String

sourceยง

impl TryGetable for Vec<Value>

sourceยง

impl TryGetable for Vec<bool>

sourceยง

impl TryGetable for Vec<f32>

sourceยง

impl TryGetable for Vec<f64>

sourceยง

impl TryGetable for Vec<i8>

sourceยง

impl TryGetable for Vec<i16>

sourceยง

impl TryGetable for Vec<i32>

sourceยง

impl TryGetable for Vec<i64>

sourceยง

impl TryGetable for Vec<u8>

sourceยง

impl TryGetable for Vec<u32>

sourceยง

impl TryGetable for Vec<BigDecimal>

sourceยง

impl TryGetable for Vec<NaiveDate>

sourceยง

impl TryGetable for Vec<NaiveDateTime>

sourceยง

impl TryGetable for Vec<NaiveTime>

sourceยง

impl TryGetable for Vec<Decimal>

sourceยง

impl TryGetable for Vec<Date>

sourceยง

impl TryGetable for Vec<PrimitiveDateTime>

sourceยง

impl TryGetable for Vec<OffsetDateTime>

sourceยง

impl TryGetable for Vec<Time>

sourceยง

impl TryGetable for Vec<Uuid>

sourceยง

impl TryGetable for Vec<String>

sourceยง

impl TryGetable for Vec<DateTime<FixedOffset>>

sourceยง

impl TryGetable for Vec<DateTime<Local>>

sourceยง

impl TryGetable for Vec<DateTime<Utc>>

sourceยง

impl TryGetable for Vec<Braced>

sourceยง

impl TryGetable for Vec<Hyphenated>

sourceยง

impl TryGetable for Vec<Simple>

sourceยง

impl TryGetable for Vec<Urn>

sourceยง

impl TryGetable for DateTime<FixedOffset>

sourceยง

impl TryGetable for DateTime<Local>

sourceยง

impl TryGetable for DateTime<Utc>

sourceยง

impl TryGetable for Braced

sourceยง

impl TryGetable for Hyphenated

sourceยง

impl TryGetable for Simple

sourceยง

impl TryGetable for Urn

sourceยง

impl<T> TryGetable for Vec<T>
where T: TryGetableArray,

sourceยง

fn try_get_by<I: ColIdx>( res: &QueryResult, index: I ) -> Result<Self, TryGetError>

sourceยง

impl<T: TryGetable> TryGetable for Option<T>

sourceยง

fn try_get_by<I: ColIdx>( res: &QueryResult, index: I ) -> Result<Self, TryGetError>

Implementorsยง