SK.gnome.dwarf.http
Class ResponseException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byjava.io.IOException
              extended bySK.gnome.dwarf.http.ResponseException
All Implemented Interfaces:
java.io.Serializable

public class ResponseException
extends java.io.IOException

This exception indicates that an error occured while constructing or sending the HTTP response.

It contains also the response status code for sending back to the client in the error messages.

See Also:
Serialized Form

Field Summary
protected  int code
          The response status code.
 
Constructor Summary
ResponseException(int code)
          Constructs a new ResponseException with the status code.
ResponseException(int code, java.lang.String message)
          Constructs a new ResponseException with the given status code and message.
ResponseException(java.lang.String message)
          Constructs a new ResponseException with the given message.
 
Method Summary
 int getCode()
          Returns the status code.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

code

protected int code
The response status code.

Constructor Detail

ResponseException

public ResponseException(int code,
                         java.lang.String message)
Constructs a new ResponseException with the given status code and message.

Parameters:
code - the status code
message - the message

ResponseException

public ResponseException(java.lang.String message)
Constructs a new ResponseException with the given message.

The Response.SC_BAD_REQUEST is used as the status code.

Parameters:
message - the message

ResponseException

public ResponseException(int code)
Constructs a new ResponseException with the status code.

Parameters:
code - the status code
Method Detail

getCode

public int getCode()
Returns the status code.

Returns:
the value of the code field
See Also:
code


Copyright (c) 1999-2005, Gnome Ltd. All rights reserved.