QueriableContainer

Trait QueriableContainer 

Source
pub trait QueriableContainer {
    type Idx;
    type SubqueryId: FieldId;

    const IDX_PLACEHOLDER: &'static str = "<idx>.";

    // Required method
    fn get_item(
        &self,
        idx: &Self::Idx,
    ) -> Option<&<Self::SubqueryId as FieldId>::Queriable>;

    // Provided method
    fn split(s: &str) -> Option<(&str, &str)> { ... }
}
Expand description

Type that contains sub-queriables of the same type, individually retrieveable by some index. It is itself a Queriable.

Provided Associated Constants§

Source

const IDX_PLACEHOLDER: &'static str = "<idx>."

Required Associated Types§

Required Methods§

Source

fn get_item( &self, idx: &Self::Idx, ) -> Option<&<Self::SubqueryId as FieldId>::Queriable>

Provided Methods§

Source

fn split(s: &str) -> Option<(&str, &str)>

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<K: Ord, Q: Queriable> QueriableContainer for BTreeMap<K, Q>

Source§

const IDX_PLACEHOLDER: &'static str = "<key>."

Source§

type Idx = K

Source§

type SubqueryId = <Q as Queriable>::FieldId

Source§

fn get_item(&self, idx: &K) -> Option<&Q>

Source§

impl<Q: Queriable> QueriableContainer for Vec<Q>

Implementors§