org.apache.turbine.services.webmacro
Interface WebMacroService

All Superinterfaces:
Initable, Service
All Known Implementing Classes:
TurbineWebMacroService

public interface WebMacroService
extends Service

Implementations of the WebMacroService interface.

Version:
$Id: WebMacroService.java,v 1.1.1.1 2001/08/16 05:09:26 jvanzyl Exp $
Author:
Dave Bryson, Daniel Rall

Field Summary
static java.lang.String SERVICE_NAME
          Deprecated. The name of this service.
static java.lang.String WEBMACRO_CONTEXT
          Deprecated. The key for a WebMacro context.
 
Method Summary
 org.webmacro.servlet.WebContext getContext()
          Deprecated. Create an empty WebContext object.
 org.webmacro.servlet.WebContext getContext(RunData data)
          Deprecated. Create a WebContext from the RunData object.
 org.webmacro.Template getTemplate(java.lang.String template)
          Deprecated. Return a template from WebMacro.
 java.lang.String handleRequest(org.webmacro.servlet.WebContext wc, java.lang.String template)
          Deprecated. Process the request and fill in the template with the values you set in the WebContext.
 void handleRequest(org.webmacro.servlet.WebContext wc, java.lang.String template, org.webmacro.FastWriter out)
          Deprecated. Process the request and fill in the template with the values you set in the WebContext.
 void handleRequest(org.webmacro.servlet.WebContext wc, java.lang.String filename, java.io.OutputStream out)
          Deprecated. Process the request and fill in the template with the values you set in the WebContext.
 
Methods inherited from interface org.apache.turbine.services.Service
getConfiguration, getName, getProperties, setName, setServiceBroker
 
Methods inherited from interface org.apache.turbine.services.Initable
getInit, init, init, setInitableBroker, shutdown
 

Field Detail

SERVICE_NAME

public static final java.lang.String SERVICE_NAME
Deprecated. 
The name of this service. Used to retrieve it from the broker.

WEBMACRO_CONTEXT

public static final java.lang.String WEBMACRO_CONTEXT
Deprecated. 
The key for a WebMacro context.
Method Detail

handleRequest

public java.lang.String handleRequest(org.webmacro.servlet.WebContext wc,
                                      java.lang.String template)
                               throws TurbineException
Deprecated. 
Process the request and fill in the template with the values you set in the WebContext.
Parameters:
wc - A WebContext.
template - A String with the filename of the template.
Returns:
The process template as a String.
Throws:
TurbineException - Error processing request.

handleRequest

public void handleRequest(org.webmacro.servlet.WebContext wc,
                          java.lang.String filename,
                          java.io.OutputStream out)
                   throws java.lang.Exception
Deprecated. 
Process the request and fill in the template with the values you set in the WebContext.
Parameters:
wc - The populated context.
filename - The file name of the template.
out - A stream to write the processed template to.
Throws:
java.lang.Exception - Error processing request.

handleRequest

public void handleRequest(org.webmacro.servlet.WebContext wc,
                          java.lang.String template,
                          org.webmacro.FastWriter out)
                   throws java.lang.Exception
Deprecated. 
Process the request and fill in the template with the values you set in the WebContext.
Parameters:
wc - A WebContext.
filename - A String with the filename of the template.
out - A Writer where we will write the process template as a String.
Throws:
java.lang.Exception - Error processing request.

getContext

public org.webmacro.servlet.WebContext getContext()
Deprecated. 
Create an empty WebContext object.
Returns:
An empty WebContext object.

getContext

public org.webmacro.servlet.WebContext getContext(RunData data)
Deprecated. 
Create a WebContext from the RunData object. Adds a pointer to the RunData object to the WC so that RunData is available in the templates.
Parameters:
data - The Turbine RunData object.
Returns:
A clone of the WebContext needed by WebMacro.

getTemplate

public org.webmacro.Template getTemplate(java.lang.String template)
                                  throws org.webmacro.NotFoundException
Deprecated. 
Return a template from WebMacro.
Parameters:
filename - A String with the name of the template.
Returns:
A Template.
Throws:
org.webmacro.NotFoundException - The template could not be found.


Copyright © 2000-2002 Apache Software Foundation. All Rights Reserved.