Skip to main content

IntoSyntax

Trait IntoSyntax 

Source
pub trait IntoSyntax<T = IriBuf, B = BlankIdBuf> {
    // Required method
    fn into_syntax(
        self,
        vocabulary: &impl Vocabulary<Iri = T, BlankId = B>,
    ) -> Result<Context, InvalidContextError>;
}
Expand description

Conversion of a processed context back into its syntactic form.

Required Methods§

Source

fn into_syntax( self, vocabulary: &impl Vocabulary<Iri = T, BlankId = B>, ) -> Result<Context, InvalidContextError>

Consumes this value, returning the equivalent syntactic context. The given vocabulary must be the one the context was built with, so its IRI handles can be resolved back to actual IRIs.

§Errors

Returns an error when a term in the context cannot be represented in syntax form.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T, B> IntoSyntax<T, B> for Context

Source§

fn into_syntax( self, _namespace: &impl Vocabulary<Iri = T, BlankId = B>, ) -> Result<Context, InvalidContextError>

Implementors§

Source§

impl<T: Clone, B: Clone> IntoSyntax<T, B> for jsonld_core::context::Context<T, B>