freemarker.template.compiler
Class TemplateArrayList

java.lang.Object
  |
  +--freemarker.template.compiler.TemplateArrayList
All Implemented Interfaces:
java.io.Serializable, TemplateProcessor

public final class TemplateArrayList
extends java.lang.Object
implements TemplateProcessor, java.io.Serializable

Encapsulates an array of TemplateProcessor objects. At run time, the contents of each item are processed in order.

Version:
$Id: TemplateArrayList.java,v 1.16 2003/11/27 08:10:39 run2000 Exp $
See Also:
Serialized Form

Constructor Summary
TemplateArrayList(java.util.List processorList)
          Create a new TemplateArrayList, given a list of TemplateProcessors to build the internal data structure.
 
Method Summary
 void process(TemplateModelRoot modelRoot, java.io.Writer out, TemplateRuntimeHandler eventHandler)
          Processes the contents of the internal TemplateProcessor list, and outputs the resulting text to a Writer.
 java.lang.String toString()
          Returns a string representation of the object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TemplateArrayList

public TemplateArrayList(java.util.List processorList)
Create a new TemplateArrayList, given a list of TemplateProcessors to build the internal data structure.
Parameters:
processorList - a List of TemplateProcessor objects to be added to the internal list.
Throws:
NullPointerException - processorList is null
Method Detail

process

public void process(TemplateModelRoot modelRoot,
                    java.io.Writer out,
                    TemplateRuntimeHandler eventHandler)
             throws java.io.IOException
Processes the contents of the internal TemplateProcessor list, and outputs the resulting text to a Writer.
Specified by:
process in interface TemplateProcessor
Parameters:
modelRoot - the root node of the data model.
out - a Writer to send the output to.
eventHandler - a TemplateEventAdapter for handling any events that occur during processing.

toString

public java.lang.String toString()
Returns a string representation of the object.
Overrides:
toString in class java.lang.Object
Returns:
a String representation of the object