This project has retired. For details please refer to its Attic page.
GetAsStringDirective (Tiles 2 2.2.2 API)

org.apache.tiles.velocity.template
Class GetAsStringDirective

Package class diagram package GetAsStringDirective
java.lang.Object
  extended by org.apache.velocity.runtime.directive.Directive
      extended by org.apache.tiles.velocity.template.BlockDirective
          extended by org.apache.tiles.velocity.template.GetAsStringDirective
All Implemented Interfaces:
Cloneable, org.apache.velocity.runtime.directive.DirectiveConstants

public class GetAsStringDirective
extends BlockDirective

Wraps GetAsStringModel to be used in Velocity. For the list of parameters, see GetAsStringModel#start(java.util.Stack, org.apache.tiles.TilesContainer, boolean, String, String, Object, String, String, String, Attribute, Object...) , GetAsStringModel#end(java.util.Stack, org.apache.tiles.TilesContainer, Writer, boolean, Object...) and GetAsStringModel.execute(TilesContainer, Writer, boolean, String, String, Object, String, String, String, Attribute, Object...).

Since:
2.2.2
Version:
$Rev: 902403 $ $Date: 2010-01-23 14:31:17 +0100 (sab, 23 gen 2010) $

Field Summary
 
Fields inherited from class org.apache.velocity.runtime.directive.Directive
rsvc
 
Fields inherited from interface org.apache.velocity.runtime.directive.DirectiveConstants
BLOCK, LINE
 
Constructor Summary
GetAsStringDirective()
          Default constructor.
GetAsStringDirective(GetAsStringModel model)
          Constructor.
 
Method Summary
protected  void end(org.apache.velocity.context.InternalContextAdapter context, Writer writer, Map<String,Object> params, HttpServletRequest request, HttpServletResponse response, 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, HttpServletRequest request, HttpServletResponse response, ServletContext servletContext)
          Starts the directive, before evaluating the body.
 
Methods inherited from class org.apache.tiles.velocity.template.BlockDirective
getType, render
 
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
 

Constructor Detail

GetAsStringDirective

public GetAsStringDirective()
Default constructor.

Since:
2.2.2

GetAsStringDirective

public GetAsStringDirective(GetAsStringModel model)
Constructor.

Parameters:
model - The used model.
Since:
2.2.2
Method Detail

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,
                   HttpServletRequest request,
                   HttpServletResponse response,
                   ServletContext servletContext)
            throws IOException
Ends the directive, after evaluating the body.

Specified by:
end in class BlockDirective
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.
Throws:
IOException - If something goes wrong when finishing this directive.

start

protected void start(org.apache.velocity.context.InternalContextAdapter context,
                     Writer writer,
                     Map<String,Object> params,
                     HttpServletRequest request,
                     HttpServletResponse response,
                     ServletContext servletContext)
Starts the directive, before evaluating the body.

Specified by:
start in class BlockDirective
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-2010 Apache Software Foundation. All Rights Reserved.