[][src]Enum uritemplate::TemplateVar

pub enum TemplateVar {
    Scalar(String),
    List(Vec<String>),
    AssociativeArray(Vec<(String, String)>),
}

TemplateVar represents the value of a template variable, which can be a scalar (a simple string), a list of strings, or an associative array of strings.

Normally, it is not necessary to use this class unless you are implementing the IntoTemplateVar trait for your own classes.

Variants

Scalar(String)

A simple string such as "foo"

List(Vec<String>)

A list of strings such as ["foo", "bar"]

AssociativeArray(Vec<(String, String)>)

An associative array of strings, such as [("key1", "value1"), ("key2", "value2")]

Trait Implementations

impl Clone for TemplateVar[src]

impl IntoTemplateVar for TemplateVar[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.