org.apache.tiles.velocity.template
Class AddAttributeDirective
java.lang.Object
org.apache.velocity.runtime.directive.Directive
org.apache.tiles.velocity.template.BodyBlockDirective
org.apache.tiles.velocity.template.AddAttributeDirective
- All Implemented Interfaces:
- Cloneable, org.apache.velocity.runtime.directive.DirectiveConstants
public class AddAttributeDirective
- extends BodyBlockDirective
Wraps AddAttributeModel
to be used in Velocity. For the list of
parameters, see AddAttributeModel#start(java.util.Stack)
,
AddAttributeModel#end(java.util.Stack, Object, String, String, String, String)
and AddAttributeModel#execute(java.util.Stack, Object, String, String, String, String)
- Since:
- 2.2.2
- Version:
- $Rev: 902403 $ $Date: 2010-01-23 14:31:17 +0100 (sab, 23 gen 2010) $
Fields inherited from class org.apache.velocity.runtime.directive.Directive |
rsvc |
Fields inherited from interface org.apache.velocity.runtime.directive.DirectiveConstants |
BLOCK, LINE |
Method Summary |
protected void |
end(org.apache.velocity.context.InternalContextAdapter context,
Writer writer,
Map<String,Object> params,
String body,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
javax.servlet.ServletContext servletContext)
Ends the directive, after evaluating the body. |
String |
getName()
|
protected void |
start(org.apache.velocity.context.InternalContextAdapter context,
Writer writer,
Map<String,Object> params,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
javax.servlet.ServletContext servletContext)
Starts the directive, before evaluating the body. |
Methods inherited from class org.apache.velocity.runtime.directive.Directive |
getColumn, getLine, getTemplateName, init, setLocation, setLocation |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AddAttributeDirective
public AddAttributeDirective()
- Default constructor.
- Since:
- 2.2.2
AddAttributeDirective
public AddAttributeDirective(AddAttributeModel model)
- Constructor.
- Parameters:
model
- The used model.- Since:
- 2.2.2
getName
public String getName()
-
- Specified by:
getName
in class org.apache.velocity.runtime.directive.Directive
end
protected void end(org.apache.velocity.context.InternalContextAdapter context,
Writer writer,
Map<String,Object> params,
String body,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
javax.servlet.ServletContext servletContext)
- Ends the directive, after evaluating the body.
- Specified by:
end
in class BodyBlockDirective
- Parameters:
context
- The Velocity context.writer
- The writer user to write the result.params
- The parameters got from the first node of the directive.body
- The body contained in this directive, as a string.request
- The HTTP request.response
- The HTTP response.servletContext
- The servlet context.
start
protected void start(org.apache.velocity.context.InternalContextAdapter context,
Writer writer,
Map<String,Object> params,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
javax.servlet.ServletContext servletContext)
- Starts the directive, before evaluating the body.
- Specified by:
start
in class BodyBlockDirective
- Parameters:
context
- The Velocity context.writer
- The writer user to write the result.params
- The parameters got from the first node of the directive.request
- The HTTP request.response
- The HTTP response.servletContext
- The servlet context.
Copyright © 2001-2011 Apache Software Foundation. All Rights Reserved.