| org.apache.turbine.modules.Screen org.apache.turbine.modules.screens.RawScreen
All known Subclasses: org.apache.turbine.modules.screens.JSONScreen,
RawScreen | abstract public class RawScreen extends Screen (Code) | | Base class for writing Screens that output binary data. This class
is provided as a helper class for those who want to write Screens
that output raw binary data. For example, it may be extended into
a Screen that outputs a SVG file or a SWF (Flash Player format)
movie. The only thing one has to do is to implement the two
methods getContentType(RunData data) and
doOutput(RunData data) (see below).
You migth want to take a look at the ImageServer screen class
contained in the TDK.
author: Regis Koenig version: $Id: RawScreen.java 534527 2007-05-02 16:10:59Z tv $ |
doBuild | final protected ConcreteElement doBuild(RunData data) throws Exception(Code) | | Build the Screen. This method actually makes a call to the
doOutput() method in order to generate the Screen content.
Parameters: data - Turbine information. A ConcreteElement. exception: Exception - , a generic exception. |
doOutput | abstract protected void doOutput(RunData data) throws Exception(Code) | | Actually output the dynamic content. The OutputStream can be
accessed like this: OutputStream out =
data.getResponse().getOutputStream(); .
Parameters: data - Turbine information. exception: Exception - , a generic exception. |
getContentType | abstract protected String getContentType(RunData data)(Code) | | Set the content type. This method should be overidden to
actually set the real content-type header of the output.
Parameters: data - Turbine information. A String with the content type. |
getLayout | final public String getLayout(RunData data)(Code) | | The layout must be set to null.
Parameters: data - Turbine information. A null String. |
|
|