Struct handlebars_iron::HandlebarsEngine [] [src]

pub struct HandlebarsEngine {
    pub prefix: String,
    pub suffix: String,
    pub registry: RwLock<Box<Handlebars>>,
}

Fields

prefix: String suffix: String registry: RwLock<Box<Handlebars>>

Methods

impl HandlebarsEngine
[src]

fn reload(&self)

fn from(prefix: &str, suffix: &str, custom: Handlebars) -> HandlebarsEngine

fn new(prefix: &str, suffix: &str) -> HandlebarsEngine

Trait Implementations

impl Key for HandlebarsEngine
[src]

type Value = Template

The value type associated with this key type.

impl PluginFor<Response> for HandlebarsEngine
[src]

type Error = ()

The error type associated with this plugin.

fn eval(resp: &mut Response) -> Result<Template()>

Create the plugin from an instance of the extended type. Read more

impl AfterMiddleware for HandlebarsEngine
[src]

fn after(&self, _: &mut Request, r: Response) -> IronResult<Response>

Do whatever post-processing this middleware should do.

fn catch(&self, &mut Request, err: IronError) -> Result<ResponseIronError>

Respond to an error thrown by previous AfterMiddleware, the Handler, or a BeforeMiddleware. Read more