com.sas.servlet.util
Class StreamContentCommand

com.sas.servlet.util.StreamContentCommand
All Implemented Interfaces:
com.sas.lang.StringDataInterface, com.sas.PublicClonable, CommandProcessorCommandInterface, com.sas.util.Command, com.sas.util.SimpleCommand, java.lang.Cloneable

Deprecated. As of Version 3.0 this class has been replaced by com.sas.servlet.util.commandprocessor.StreamContentCommand.

public class StreamContentCommand
implements CommandProcessorCommandInterface


Constructor Summary
StreamContentCommand()
          Deprecated. StreamContentCommand constructor
StreamContentCommand(GetStreamInterface gsi)
          Deprecated. StreamContentCommand constructor
StreamContentCommand(GetStreamInterface gsi, java.lang.String contentType)
          Deprecated. StreamContentCommand constructor
StreamContentCommand(GetStreamInterface gsi, java.lang.String contentType, java.lang.String servletURL)
          Deprecated. StreamContentCommand constructor
 
Method Summary
 java.lang.Object clone()
          Deprecated.  
 void execute(java.lang.Object arg)
          Deprecated. Calls performAction(Object o) but if exceptions are caught nothing is done.
 java.lang.String getContentDisposition()
          Deprecated. Returns the Content-Disposition response header.
 java.lang.String getContentServletURL()
          Deprecated. Returns the URL for the ContentServlet.
 java.lang.String getContentType()
          Deprecated. Returns Content-type associated with the stream.
 java.util.Locale getLocale()
          Deprecated. Get the locale
 java.lang.String getName()
          Deprecated. Returns the name of the command.
static java.lang.String getNextCommandName()
          Deprecated.  
 javax.servlet.http.HttpServletRequest getRequest()
          Deprecated. Gets the current request object.
 javax.servlet.http.HttpServletResponse getResponse()
          Deprecated. Gets the current response object.
 GetStreamInterface getStreamInterface()
          Deprecated. Returns the GetStreamInterface.
 java.lang.Object getTarget()
          Deprecated. This method always returns null.
 java.lang.String getText()
          Deprecated.  
 boolean isExecutable()
          Deprecated. This method always return true.
 boolean isUndoable()
          Deprecated. This method always returns false.
 void performAction(java.lang.Object o)
          Deprecated. Executes the command and offers the opportunity to catch exceptions.
 void setContentDisposition(java.lang.String cd)
          Deprecated. Sets the Content-Disposition response header.
 void setContentServletURL(java.lang.String url)
          Deprecated. Sets the URL for the ContentServlet.
 void setContentType(java.lang.String contentType)
          Deprecated. Set the Content-type associated with the stream.
 void setLocale(java.util.Locale loc)
          Deprecated. Set the locale
 void setName(java.lang.String name)
          Deprecated. Sets the name of the command.
 void setRequest(javax.servlet.http.HttpServletRequest request)
          Deprecated. Sets the request object.
 void setResponse(javax.servlet.http.HttpServletResponse response)
          Deprecated. Sets the response object.
 void setTarget(java.lang.Object o)
          Deprecated. This method is not implemented for the StreamContentCommand.
 void setText(java.lang.String text)
          Deprecated. This method is not implemented.
 void undo()
          Deprecated. This method is not implemented.
 

Constructor Detail

StreamContentCommand

public StreamContentCommand()
Deprecated. 
StreamContentCommand constructor


StreamContentCommand

public StreamContentCommand(GetStreamInterface gsi)
Deprecated. 
StreamContentCommand constructor


StreamContentCommand

public StreamContentCommand(GetStreamInterface gsi,
                            java.lang.String contentType)
Deprecated. 
StreamContentCommand constructor

Parameters:
gsi - GetStreamInterface
contentType - Content-type

StreamContentCommand

public StreamContentCommand(GetStreamInterface gsi,
                            java.lang.String contentType,
                            java.lang.String servletURL)
Deprecated. 
StreamContentCommand constructor

Parameters:
gsi - GetStreamInterface
contentType - Content-type
servletURL - ContentServlet URL
Method Detail

getName

public java.lang.String getName()
Deprecated. 
Returns the name of the command. Each Command must have a unique name.

Specified by:
getName in interface CommandProcessorCommandInterface
Returns:
name of the command

setName

public void setName(java.lang.String name)
Deprecated. 
Sets the name of the command. Each Command must have a unique name

Specified by:
setName in interface CommandProcessorCommandInterface
Parameters:
name - unique name of the command. To ensure unique command names use the @link #getNextCommandName method.

getStreamInterface

public GetStreamInterface getStreamInterface()
Deprecated. 
Returns the GetStreamInterface.

Returns:
GetStreamInterface object.

performAction

public void performAction(java.lang.Object o)
                   throws java.io.IOException
Deprecated. 
Description copied from interface: CommandProcessorCommandInterface
Executes the command and offers the opportunity to catch exceptions.

Specified by:
performAction in interface CommandProcessorCommandInterface
Parameters:
o - Object. The object should be a PageContext object for JSP and a HttpServletResponse Object for servlets
Throws:
java.io.IOException
See Also:
GetStreamInterface

getNextCommandName

public static java.lang.String getNextCommandName()
Deprecated. 

getContentServletURL

public java.lang.String getContentServletURL()
Deprecated. 
Returns the URL for the ContentServlet. The default value is /servlet/ContentServlet.

Returns:
URL for the ContentServlet.

setContentServletURL

public void setContentServletURL(java.lang.String url)
Deprecated. 
Sets the URL for the ContentServlet. The default value is /servlet/ContentServlet.


getContentType

public java.lang.String getContentType()
Deprecated. 
Returns Content-type associated with the stream.

Returns:
content-type

setContentType

public void setContentType(java.lang.String contentType)
Deprecated. 
Set the Content-type associated with the stream.

Parameters:
contentType - content type associated with the stream.

getTarget

public java.lang.Object getTarget()
Deprecated. 
This method always returns null.

Specified by:
getTarget in interface CommandProcessorCommandInterface
Returns:
command target

setTarget

public void setTarget(java.lang.Object o)
Deprecated. 
This method is not implemented for the StreamContentCommand.

Specified by:
setTarget in interface CommandProcessorCommandInterface
Parameters:
o - target object for the command.

isExecutable

public boolean isExecutable()
Deprecated. 
This method always return true.

Specified by:
isExecutable in interface com.sas.util.Command

isUndoable

public boolean isUndoable()
Deprecated. 
This method always returns false.

Specified by:
isUndoable in interface com.sas.util.Command

undo

public void undo()
Deprecated. 
This method is not implemented.

Specified by:
undo in interface com.sas.util.Command

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Deprecated. 
Specified by:
clone in interface com.sas.PublicClonable
Specified by:
clone in interface com.sas.util.Command
Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException

execute

public void execute(java.lang.Object arg)
Deprecated. 
Calls performAction(Object o) but if exceptions are caught nothing is done.

Specified by:
execute in interface com.sas.util.SimpleCommand
See Also:
CommandProcessorCommandInterface.performAction(java.lang.Object)

getText

public java.lang.String getText()
Deprecated. 
Specified by:
getText in interface com.sas.lang.StringDataInterface

setText

public void setText(java.lang.String text)
Deprecated. 
This method is not implemented.

Specified by:
setText in interface com.sas.lang.StringDataInterface

setLocale

public void setLocale(java.util.Locale loc)
Deprecated. 
Set the locale

Specified by:
setLocale in interface CommandProcessorCommandInterface
Parameters:
locale -

getLocale

public java.util.Locale getLocale()
Deprecated. 
Get the locale

Specified by:
getLocale in interface CommandProcessorCommandInterface
Returns:
locale

setRequest

public void setRequest(javax.servlet.http.HttpServletRequest request)
Deprecated. 
Sets the request object. The request object is needed for localization. The request object should be set before the performAction method is called.

Specified by:
setRequest in interface CommandProcessorCommandInterface
Parameters:
request - The request object

getRequest

public javax.servlet.http.HttpServletRequest getRequest()
Deprecated. 
Gets the current request object.

Specified by:
getRequest in interface CommandProcessorCommandInterface
Returns:
The request object

getResponse

public javax.servlet.http.HttpServletResponse getResponse()
Deprecated. 
Gets the current response object.

Specified by:
getResponse in interface CommandProcessorCommandInterface
Returns:
The response object

setResponse

public void setResponse(javax.servlet.http.HttpServletResponse response)
Deprecated. 
Sets the response object. The request object is needed url encoding. The response object should be set before the performAction method is called.

Specified by:
setResponse in interface CommandProcessorCommandInterface
Parameters:
response - The response object

setContentDisposition

public void setContentDisposition(java.lang.String cd)
Deprecated. 
Sets the Content-Disposition response header.

Parameters:
cd - Content-Disposition response header.

getContentDisposition

public java.lang.String getContentDisposition()
Deprecated. 
Returns the Content-Disposition response header. The default value is null.

Returns:
Content-Disposition response header.



Copyright © 2009 SAS Institute Inc. All Rights Reserved.