org.apache.velocity.runtime.directive
public class Foreach extends Directive
Version: $Id: Foreach.java,v 1.42.4.1 2004/03/03 23:22:55 geirm Exp $
| Field Summary | |
|---|---|
| int | counterInitialValue
What value to start the loop counter at. |
| String | counterName
The name of the variable to use when placing
the counter value into the context. |
| String | elementKey
The reference name used to access each
of the elements in the list object. |
| protected Info | uberInfo
immutable, so create in init |
| Method Summary | |
|---|---|
| String | getName()
Return name of this directive. |
| int | getType()
Return type of this directive. |
| void | init(RuntimeServices rs, InternalContextAdapter context, Node node)
simple init - init the tree and get the elementKey from
the AST |
| boolean | render(InternalContextAdapter context, Writer writer, Node node)
renders the #foreach() block |