com.ibm.commerce.command
Class AbstractDirectViewCommand

java.lang.Object
  |
  +--com.ibm.commerce.command.AbstractECCommand
        |
        +--com.ibm.commerce.command.AbstractViewCommand
              |
              +--com.ibm.commerce.command.AbstractDirectViewCommand
All Implemented Interfaces:
AccCommand, DirectViewCommand, ECCommand, ViewCommand
Direct Known Subclasses:
HttpDirectViewCommandImpl

public abstract class AbstractDirectViewCommand
extends AbstractViewCommand
implements DirectViewCommand

This is the abstract base implementation of direct view commands.


Field Summary
 
Fields inherited from class com.ibm.commerce.command. AbstractViewCommand
requestProperties, responseProperties
 
Fields inherited from class com.ibm.commerce.command. AbstractECCommand
commandContext
 
Fields inherited from interface com.ibm.commerce.command. DirectViewCommand
COPYRIGHT
 
Fields inherited from interface com.ibm.commerce.command. ECCommand
defaultCommandClassName
 
Constructor Summary
AbstractDirectViewCommand()
          AbstractDirectViewCommand constructor comment.
 
Method Summary
static  TypedProperty createTextResponse(java.lang.String textResponse)
          Prepares a TypedProperty object for sending text response.
 int getContentLength()
          Gets the length of the data
 java.lang.String getContentType()
          Gets the content type.
 java.lang.Object getRawDocument()
          Gets the raw document data from the requestProperties.
 java.io.InputStream getTextDocument()
          Gets the text document data as an input stream from requestProperties.
 
Methods inherited from class com.ibm.commerce.command. AbstractViewCommand
fulfills, getForUserId, getOwner, getRequestProperties, getResourceOwners, getResponseProperties, getViewName, mergeProperties, performExecute, setForUserId, setOwner, setRequestProperties, setResponseProperties, setViewName
 
Methods inherited from class com.ibm.commerce.command. AbstractECCommand
accessControlCheck, checkIsAllowed, checkParameters, checkResourcePermission, createCommandExecutionEvent, execute, finalize, getAccCheck, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getResources, getStoreId, getUser, getUserId, isReadyToCallExecute, reset, setAccCheck, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties, validateParameters
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ibm.commerce.command. ViewCommand
getRequestProperties, getResponseProperties, getViewName, mergeProperties, setRequestProperties, setViewName
 
Methods inherited from interface com.ibm.commerce.command. AccCommand
accessControlCheck, getAccCheck, getForUserId, getResourceOwners, setAccCheck, setForUserId, setOwner
 
Methods inherited from interface com.ibm.commerce.command. ECCommand
checkIsAllowed, checkResourcePermission, createCommandExecutionEvent, execute, getCommandContext, getCommandIfName, getCommandName, getCommandStoreId, getDefaultProperties, getResources, getStoreId, getUser, getUserId, performExecute, setCommandContext, setCommandIfName, setCommandStoreId, setDefaultProperties, validateParameters
 

Constructor Detail

AbstractDirectViewCommand

public AbstractDirectViewCommand()
AbstractDirectViewCommand constructor comment.
Method Detail

getContentLength

public final int getContentLength()
Gets the length of the data
Specified by:
getContentLength in interface DirectViewCommand
Returns:
length of the data

getContentType

public final java.lang.String getContentType()
Gets the content type. Content type can be Text/html etc.
Specified by:
getContentType in interface DirectViewCommand
Returns:
content type

getRawDocument

public final java.lang.Object getRawDocument()
Gets the raw document data from the requestProperties.
Specified by:
getRawDocument in interface DirectViewCommand
Returns:
raw document object

getTextDocument

public final java.io.InputStream getTextDocument()
Gets the text document data as an input stream from requestProperties.
Specified by:
getTextDocument in interface DirectViewCommand
Returns:
InputStream of the text document

createTextResponse

public static TypedProperty createTextResponse(java.lang.String textResponse)
Prepares a TypedProperty object for sending text response. This is done by adding the additional values to the typed property object for calling the DirectView.
Parameters:
textResponse - the text to be returned
Returns:
A TypedProperty representation of the given text.