Template Engine

Class TemplateManager

Extends:
EventDispatcher
Requires:
Class
Event
EventDispatcher
JsonRpcError
Template
Defined in:
TemplateManager.js

Responsible for managing templates.

Constructor

TemplateManager()

Static Fields

Field
TemplateManager.ERROR
[constant]
TemplateManager.JQTEMPLATE
[constant]
TemplateManager.RENDERED
[constant]

Static Methods

Method
TemplateManager.createTemplate(name, configuration)
Makes new template of specific type.

Methods

Method
abort(error)
Aborts rendering current tree.
Inherited from EventDispatcher
addEventListener(type, callbackFunction, context)
Adding listener
addTemplate(template)
Adds a template to collection
Inherited from EventDispatcher
Dispatches event
Returns template instance by given name
Return templates content object.
Inherited from EventDispatcher
Checks if given event type listener is registered
Indicates if rendering process was aborded.
Inherited from EventDispatcher
Remove group of listeners or all listeners
Inherited from EventDispatcher
removeEventListener(type, callbackFunction)
Remove listener
removeTemplate(template)
Removes template from collecion
Class Detail
TemplateManager()
Static Field Details
TemplateManager.ERROR
[constant]
TemplateManager.JQTEMPLATE
[constant]
TemplateManager.RENDERED
[constant]
Static Method Details
TemplateManager.createTemplate(name, configuration) :{Template}
Makes new template of specific type. Factory method
Parameters (optional)
name {string} Template's name/file path
configuration {object} Configuration of transformation rule
Returns:
{Template}
Method Details
abort(error)
Aborts rendering current tree. Dispatchig TemplateManager.RENDERED
Parameters (optional)
error
addTemplate(template) :{boolean}
Adds a template to collection
Parameters (optional)
template {Template}
Throws:
{TemplateManager.Exception.TEMPLATE_HAS_TO_INHERIT}
Returns:
{boolean}
getTemplateByName(name) :{Template|null}
Returns template instance by given name
Parameters (optional)
name {string} templates name
Throws:
{TemplateManager.Exception.NAME_MUST_BE_A_STRING}
Returns:
{Template|null}
getTemplatesContent() :{Object}
Return templates content object.
Returns:
{Object}
isAborted() :{boolean}
Indicates if rendering process was aborded.
Returns:
{boolean}
removeTemplate(template) :{boolean}
Removes template from collecion
Parameters (optional)
template {Template}
Throws:
{TemplateManager.Exception.TEMPLATE_HAS_TO_INHERIT}
Returns:
{boolean}
Documentation generated by JsDoc Toolkit 2.4.0 on Wed Aug 17 2011 15:33:34 GMT+0200 (CEST)