Struct trimmer::Var
[−]
[src]
pub struct Var<'a, 'render: 'a>(_);
Variable reference returned from methods of Variable trait
It can contain borrowed reference from current variable or owned (reference counted) box to another object
Methods
impl<'a, 'render> Var<'a, 'render>
[src]
fn owned<'x, 'y: 'x, T: Variable<'y> + 'y>(x: T) -> Var<'x, 'y> where
'y: 'x,
T: 'y,
'y: 'x,
T: 'y,
Embed and owned reference to a value
fn str(x: &'static str) -> Var<'a, 'render>
Embed a static string as a variable
Currently this uses reference counted object that contains pointer, but we want to figure out better way to reference static strings
fn borrow<'x, T: Variable<'render> + 'render>(x: &'x T) -> Var<'x, 'render> where
'render: 'x,
'render: 'x,
Create a borrowed reference to the variable
fn undefined<'x, 'y: 'x>() -> Var<'x, 'y>
Create an undefined variable reference
fn empty<'x, 'y: 'x>() -> Var<'x, 'y>
Create a variable that contains an empty string