Trait ContextLoadable

Source
pub trait ContextLoadable<C: ?Sized>: Sized {
    // Required methods
    fn static_context_builder<'namespaces>(    ) -> StaticContextBuilder<'namespaces>;
    fn load_with_context(
        queries: &Queries<'_>,
        context: &C,
    ) -> Result<impl Query<Self>>;

    // Provided methods
    fn load_from_xml_with_context(xml: &str, context: &C) -> Result<Self> { ... }
    fn load_from_node_with_context(
        documents: Documents,
        document_id: DocumentHandle,
        context: &C,
    ) -> Result<Self> { ... }
}

Required Methods§

Source

fn static_context_builder<'namespaces>() -> StaticContextBuilder<'namespaces>

Source

fn load_with_context( queries: &Queries<'_>, context: &C, ) -> Result<impl Query<Self>>

Provided Methods§

Source

fn load_from_xml_with_context(xml: &str, context: &C) -> Result<Self>

Source

fn load_from_node_with_context( documents: Documents, document_id: DocumentHandle, context: &C, ) -> Result<Self>

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.

Implementors§