iri_string::template::context

Trait Context

source
pub trait Context: Sized {
    // Required method
    fn visit<V: Visitor>(&self, visitor: V) -> V::Result;
}
Expand description

A trait for types that can behave as a static URI template expansion context.

This type is for use with UriTemplateStr::expand method.

See the module documentation for usage.

Required Methods§

source

fn visit<V: Visitor>(&self, visitor: V) -> V::Result

Visits a variable.

To get variable name, use Visitor::var_name().

Object Safety§

This trait is not object safe.

Implementors§

source§

impl Context for SimpleContext

Available on crate feature alloc only.