| org.apache.turbine.services.velocity.VelocityService
All known Subclasses: org.apache.turbine.services.velocity.TurbineVelocityService,
Method Summary | |
Context | getContext() Create an empty WebContext object. | Context | getContext(RunData data) Create a Context from the RunData object. | Context | getNewContext() This method returns a new, empty Context object. | String | handleRequest(Context context, String template) Process the request and fill in the template with the values
you set in the Context.
Parameters: context - A Context. Parameters: template - A String with the filename of the template. | void | handleRequest(Context context, String filename, OutputStream out) Process the request and fill in the template with the values
you set in the Context. | void | handleRequest(Context context, String filename, Writer writer) Process the request and fill in the template with the values
you set in the Context. | void | requestFinished(Context context) Performs post-request actions (releases context
tools back to the object pool). |
CATCH_ERRORS_DEFAULT | boolean CATCH_ERRORS_DEFAULT(Code) | | Default: Yes
|
CATCH_ERRORS_KEY | String CATCH_ERRORS_KEY(Code) | | Shall we catch Velocity Errors and report them?
|
CONTEXT | String CONTEXT(Code) | | Key for storing the Context in the RunData object
|
RUNDATA_KEY | String RUNDATA_KEY(Code) | | The Key for storing the RunData Object in the Context
|
VELOCITY_EXTENSION | String VELOCITY_EXTENSION(Code) | | The default extension of Velocity Pages
|
getContext | Context getContext()(Code) | | Create an empty WebContext object.
An empty WebContext object. |
getContext | Context getContext(RunData data)(Code) | | Create a Context from the RunData object. Adds a pointer to
the RunData object to the Context so that RunData is available in
the templates.
Parameters: data - The Turbine RunData object. A clone of the Context needed by Velocity. |
getNewContext | Context getNewContext()(Code) | | This method returns a new, empty Context object.
A WebContext. |
handleRequest | String handleRequest(Context context, String template) throws Exception(Code) | | Process the request and fill in the template with the values
you set in the Context.
Parameters: context - A Context. Parameters: template - A String with the filename of the template. The process template as a String. exception: Exception - a generic exception. |
handleRequest | void handleRequest(Context context, String filename, OutputStream out) throws TurbineException(Code) | | Process the request and fill in the template with the values
you set in the Context.
Parameters: context - A Context. Parameters: filename - A String with the filename of the template. Parameters: out - A OutputStream where we will write the process template asa String. throws: TurbineException - Any exception trown while processing will bewrapped into a TurbineException and rethrown. |
handleRequest | void handleRequest(Context context, String filename, Writer writer) throws TurbineException(Code) | | Process the request and fill in the template with the values
you set in the Context.
Parameters: context - A Context. Parameters: filename - A String with the filename of the template. Parameters: writer - A Writer where we will write the process template asa String. throws: TurbineException - Any exception trown while processing will bewrapped into a TurbineException and rethrown. |
requestFinished | void requestFinished(Context context)(Code) | | Performs post-request actions (releases context
tools back to the object pool).
Parameters: context - a Velocity Context |
|
|