public class ChunkDirective
extends org.apache.velocity.runtime.directive.Directive
chain.
Usage of chunk is the following:
#chunk()...#end - e.g. #chunk()A = 5#end #chunk($paramKey)...#end - e.g. #chunk($a)A = $a#end
If context contains paramKey and it's value isn't null, chunk is included in the chain, and if it is not the first chunk, it is prefixed with chain join (OR/AND). If context doesn't contain paramKey or it's value is null, chunk is skipped.
| Constructor and Description |
|---|
ChunkDirective() |
| Modifier and Type | Method and Description |
|---|---|
String |
getName() |
int |
getType() |
boolean |
render(org.apache.velocity.context.InternalContextAdapter context,
Writer writer,
org.apache.velocity.runtime.parser.node.Node node) |
public String getName()
getName in class org.apache.velocity.runtime.directive.Directivepublic int getType()
getType in class org.apache.velocity.runtime.directive.Directivepublic boolean render(org.apache.velocity.context.InternalContextAdapter context,
Writer writer,
org.apache.velocity.runtime.parser.node.Node node)
throws IOException,
org.apache.velocity.exception.ResourceNotFoundException,
org.apache.velocity.exception.ParseErrorException,
org.apache.velocity.exception.MethodInvocationException
render in class org.apache.velocity.runtime.directive.DirectiveIOExceptionorg.apache.velocity.exception.ResourceNotFoundExceptionorg.apache.velocity.exception.ParseErrorExceptionorg.apache.velocity.exception.MethodInvocationExceptionCopyright © 2001–2018 Apache Cayenne. All rights reserved.