org.apache.struts.util
Class ResponseUtils

java.lang.Object
  extended byorg.apache.struts.util.ResponseUtils

Deprecated. Use the corresponding TagUtils methods instead. This class will be removed after Struts 1.2.

public class ResponseUtils
extends java.lang.Object

General purpose utility methods related to generating a servlet response in the Struts controller framework.

Version:
$Revision: 1.11 $ $Date: 2004/03/14 06:23:51 $

Field Summary
protected static MessageResources messages
          Deprecated. The message resources for this package.
 
Constructor Summary
ResponseUtils()
          Deprecated.  
 
Method Summary
static java.lang.String filter(java.lang.String value)
          Deprecated.  
static java.lang.String filterIfQuote(java.lang.String value)
          Deprecated. Replace double-quote characters in the input string with proper HTML encoding.
static void write(PageContext pageContext, java.lang.String text)
          Deprecated.  
static void writePrevious(PageContext pageContext, java.lang.String text)
          Deprecated.  
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

messages

protected static MessageResources messages
Deprecated. 
The message resources for this package.

Constructor Detail

ResponseUtils

public ResponseUtils()
Deprecated. 
Method Detail

filter

public static java.lang.String filter(java.lang.String value)
Deprecated.  

Filter the specified string for characters that are senstive to HTML interpreters, returning the string with these characters replaced by the corresponding character entities.

Parameters:
value - The string to be filtered and returned

write

public static void write(PageContext pageContext,
                         java.lang.String text)
                  throws JspException
Deprecated.  

Write the specified text as the response to the writer associated with this page. WARNING - If you are writing body content from the doAfterBody() method of a custom tag class that implements BodyTag, you should be calling writePrevious() instead.

Parameters:
pageContext - The PageContext object for this page
text - The text to be written
Throws:
JspException - if an input/output error occurs (already saved)

writePrevious

public static void writePrevious(PageContext pageContext,
                                 java.lang.String text)
                          throws JspException
Deprecated.  

Write the specified text as the response to the writer associated with the body content for the tag within which we are currently nested.

Parameters:
pageContext - The PageContext object for this page
text - The text to be written
Throws:
JspException - if an input/output error occurs (already saved)

filterIfQuote

public static java.lang.String filterIfQuote(java.lang.String value)
Deprecated. 
Replace double-quote characters in the input string with proper HTML encoding. No other HTML-encoding is performed. As a result, the return value can only be safely used in (X)HTML attributes surrounded by double-quote characters (").

Note that you should not use this function in new code. It is only intended for old code which needs to be backwards-compatible with incompletely-quoted attributes.

Returns:
a fresh string object if quoting is needed, otherwise the input string


Copyright ? 2000-2009 - The Apache Software Foundation