Solstice::Compiler::View - Compiles a View and Template into a perl structure


Solstice documentation  | view source Contained in the Solstice distribution.

Index


NAME

Top

Solstice::Compiler::View - Compiles a View and Template into a perl structure

SYNOPSIS

Top

  my $compiler = Solstice::Compiler::View->new();
  my $paint_method = $compiler->makePaintMethod($view_object);

DESCRIPTION

Top

This module will take a Solstice::View object and the HTML::Template template that it specifies, and create a paint method for the view.

We do this because painting a template is very expensive... on complicated screens we were seeing %50 of page creation time in template painting.

The compiled paint methods will end up in the path specified in the compiled_template_path in the app's configuration file. If there is no path specified, no compiled view will be made.

The goal of this module to support the syntax of HTML::Template, at least for some limited uses. It is heavily biased towards the parts of HTML::Template that we use, it is very possible that there will be bugs in other parts of the syntax. We will try to fix such bugs, provided they don't have a noticable impact on the performance of the compiled paint method.

Very important note - this will not work for modules that choose their templates dynamically. You should change those so views are chosen dynamically, or disable compiled views for that application.

Methods

new()

constructor.

makePaintMethod($package_name)

Takes a package name, and creates a paint method based on the template it uses.

AUTHOR

Top

Catalyst Group, <catalyst@u.washington.edu>

VERSION

Top

$Revision: 2944 $

COPYRIGHT

Top


Solstice documentation  | view source Contained in the Solstice distribution.