org.w3c.www.http
Class HttpWarning

java.lang.Object
  extended by org.w3c.www.http.BasicValue
      extended by org.w3c.www.http.HttpWarning
All Implemented Interfaces:
java.lang.Cloneable, HeaderValue

public class HttpWarning
extends BasicValue


Field Summary
protected  java.lang.String agent
           
static int DISCONNECTED_OPERATION
          Warning status - Disconnected opertaion.
static int HEURISTIC_EXPIRATION
          Warning status - Heuristic expiration.
protected  HttpWarningList list
           
static int MISCELLANEOUS
          Warning status - Miscellaneous warning
static int PERSISTENT_MISCELLANEOUS
          Warning status - Miscellaneous warning
static int REVALIDATION_FAILED
          Warning status - Revalidation failed.
static int STALE
          Warning status - Response is stale.
protected  int status
           
protected  java.lang.String text
           
static int TRANSFORMATION_APPLIED
          Warning status - Transformation applied.
 
Fields inherited from class org.w3c.www.http.BasicValue
isValid, raw, rlen, roff
 
Constructor Summary
HttpWarning()
           
 
Method Summary
 java.lang.String getAgent()
          Get this warning agent.
 int getStatus()
          Get this warning status code.
 java.lang.String getText()
          Get the warning text message.
 java.lang.Object getValue()
          HeaderValue implemenntation - Get this header value.
protected  void invalidateByteValue()
          Invalidate the current byte value for this header, if any.
protected  void parse()
          parse.
 void setAgent(java.lang.String agent)
          Set the agent that is generating the warning.
 void setStatus(int status)
          Set this warning status code.
 void setText(java.lang.String text)
          Set the text warning message.
protected  void updateByteValue()
          Update the RFC822 compatible header value for this object.
 
Methods inherited from class org.w3c.www.http.BasicValue
addBytes, appendValue, checkByteValue, clone, emit, error, setBytes, setString, toExternalForm, toString, validate
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

STALE

public static final int STALE
Warning status - Response is stale.

See Also:
Constant Field Values

REVALIDATION_FAILED

public static final int REVALIDATION_FAILED
Warning status - Revalidation failed.

See Also:
Constant Field Values

DISCONNECTED_OPERATION

public static final int DISCONNECTED_OPERATION
Warning status - Disconnected opertaion.

See Also:
Constant Field Values

HEURISTIC_EXPIRATION

public static final int HEURISTIC_EXPIRATION
Warning status - Heuristic expiration.

See Also:
Constant Field Values

MISCELLANEOUS

public static final int MISCELLANEOUS
Warning status - Miscellaneous warning

See Also:
Constant Field Values

TRANSFORMATION_APPLIED

public static final int TRANSFORMATION_APPLIED
Warning status - Transformation applied.

See Also:
Constant Field Values

PERSISTENT_MISCELLANEOUS

public static final int PERSISTENT_MISCELLANEOUS
Warning status - Miscellaneous warning

See Also:
Constant Field Values

list

protected HttpWarningList list

status

protected int status

agent

protected java.lang.String agent

text

protected java.lang.String text
Constructor Detail

HttpWarning

public HttpWarning()
Method Detail

parse

protected void parse()
              throws HttpParserException
parse.

Specified by:
parse in class BasicValue
Throws:
HttpParserException - if parsing failed.

updateByteValue

protected void updateByteValue()
Description copied from class: BasicValue
Update the RFC822 compatible header value for this object.

Specified by:
updateByteValue in class BasicValue

invalidateByteValue

protected void invalidateByteValue()
Description copied from class: BasicValue
Invalidate the current byte value for this header, if any.

Overrides:
invalidateByteValue in class BasicValue

getValue

public java.lang.Object getValue()
Description copied from class: BasicValue
HeaderValue implemenntation - Get this header value.

Specified by:
getValue in interface HeaderValue
Specified by:
getValue in class BasicValue
Returns:
An object representing the parsed value for this header.

getStatus

public int getStatus()
Get this warning status code.

Returns:
An integer giving the warning status code.

setStatus

public void setStatus(int status)
Set this warning status code.

Parameters:
status - The status code for this warning.

getAgent

public java.lang.String getAgent()
Get this warning agent.

Returns:
A String encoding the agent that generated the warning.

setAgent

public void setAgent(java.lang.String agent)
Set the agent that is generating the warning.

Parameters:
agent - The String describing the agent emitting the warning.

getText

public java.lang.String getText()
Get the warning text message.

Returns:
A String encoding the text message.

setText

public void setText(java.lang.String text)
Set the text warning message.

Parameters:
text - The new text of the warning message.