Timothy Appnel > Typist-0.02 > Typist::Template

Download:
Typist-0.02.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
Report a bug
Module Version: 0.04   Source  

NAME ^

Typist::Template - A simple file-based template object

METHODS ^

Typist::Template->new

Constructor called by load.

Typist::Template->load($filename)

Reads a $filename relative to the value return by the tmpl_path method for the current instance of Typist and returns a object

$tmpl->build($ctx, \%cond)

Takes two required parameters, an initialized Typist::Template::Context object and a HASH reference of conditional flags.

This method will take the template object, compile the template and cache the tokens for later builds and then call the build method. Returns a string of the output of the result.