org.apache.wsrp4j.exception
Class WSRPException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byorg.apache.wsrp4j.exception.WSRPException
All Implemented Interfaces:
java.io.Serializable

public class WSRPException
extends java.lang.Exception

Common Exception class within the WSRP environment

Version:
$Id: WSRPException.java,v 1.5 2005/08/10 14:51:45 cziegeler Exp $
See Also:
Serialized Form

Field Summary
private static int COMMON_EXCEPTION
           
private static int CONSUMER_EXCEPTION
           
private  int errCode
           
private  int exceptionRange
           
private  java.lang.Throwable nestedThrowable
           
private static int PRODUCER_EXCEPTION
           
private static int PROVIDER_EXCEPTION
           
 
Fields inherited from class java.lang.Exception
 
Fields inherited from class java.lang.Throwable
 
Constructor Summary
WSRPException()
           
WSRPException(int errorCode)
          Creates a new common excpetion.
WSRPException(int errorCode, java.lang.Throwable t)
          Creates a new common excpetion.
 
Method Summary
 int getErrorCode()
          Returns an error code
 int getExceptionRange()
          Returns the range identifier of this exception.
 java.lang.Throwable getNestedThrowable()
          Returns a nested Throwable
 void setCommonExceptionRange()
          Assign the exception to the common range
 void setConsumerExceptionRange()
          Assign the exception to the consumer range
 void setProducerExceptionRange()
          Assign the exception to the producer range
 void setProviderExceptionRange()
          Assign the exception to the provider range
 java.lang.String toHTMLString()
          Returns the Exception in the HTML string format.
 java.lang.String toString()
          Returns the exception as String
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

errCode

private int errCode

nestedThrowable

private java.lang.Throwable nestedThrowable

COMMON_EXCEPTION

private static final int COMMON_EXCEPTION
See Also:
Constant Field Values

CONSUMER_EXCEPTION

private static final int CONSUMER_EXCEPTION
See Also:
Constant Field Values

PRODUCER_EXCEPTION

private static final int PRODUCER_EXCEPTION
See Also:
Constant Field Values

PROVIDER_EXCEPTION

private static final int PROVIDER_EXCEPTION
See Also:
Constant Field Values

exceptionRange

private int exceptionRange
Constructor Detail

WSRPException

public WSRPException()

WSRPException

public WSRPException(int errorCode)
Creates a new common excpetion. The message to be passed will be ignored

Parameters:
errorCode - integer representing an error code

WSRPException

public WSRPException(int errorCode,
                     java.lang.Throwable t)
Creates a new common excpetion. The message to be passed will be ignored

Parameters:
errorCode - integer representing an error code
t - Throwable to be wrapped
Method Detail

getErrorCode

public int getErrorCode()
Returns an error code

Returns:
integer representing an error code

getNestedThrowable

public java.lang.Throwable getNestedThrowable()
Returns a nested Throwable

Returns:
Throwable if a nested Throwable exists or null

toString

public java.lang.String toString()
Returns the exception as String


toHTMLString

public java.lang.String toHTMLString()
Returns the Exception in the HTML string format. Nested exceptions are included in the report.


getExceptionRange

public int getExceptionRange()
Returns the range identifier of this exception. E.g. Common, Consumer, Producer or Provider range.

Returns:
the exception range id

setCommonExceptionRange

public void setCommonExceptionRange()
Assign the exception to the common range


setConsumerExceptionRange

public void setConsumerExceptionRange()
Assign the exception to the consumer range


setProducerExceptionRange

public void setProducerExceptionRange()
Assign the exception to the producer range


setProviderExceptionRange

public void setProviderExceptionRange()
Assign the exception to the provider range



--