[][src]Trait liquid::compiler::ParseTag

pub trait ParseTag: ParseTagClone + Send + Sync {
    fn parse(
        &self,
        tag_name: &str,
        arguments: TagTokenIter,
        options: &Language
    ) -> Result<Box<dyn Renderable + 'static>, Error>; }

A trait for creating custom tags. This is a simple type alias for a function.

This function will be called whenever the parser encounters a tag and returns a new Renderable based on its parameters. The received parameters specify the name of the tag, the argument Tokens passed to the tag and the global Language.

Required methods

fn parse(
    &self,
    tag_name: &str,
    arguments: TagTokenIter,
    options: &Language
) -> Result<Box<dyn Renderable + 'static>, Error>

Loading content...

Implementors

impl ParseTag for BoxedTagParser
[src]

Loading content...