com.sun.sgs.protocol
Class RequestFailureException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.sun.sgs.protocol.RequestFailureException
All Implemented Interfaces:
Serializable

public class RequestFailureException
extends Exception

An exception indicating that processing a request has failed, and therefore that request has been dropped. The getMessage method returns a detail message containing an explanation for the failure (possibly null), the getReason method returns the failure reason, and if the failure reason is RequestFailureException.FailureReason.OTHER, the getCause method returns the possibly-null cause of the failure.

See Also:
Serialized Form

Nested Class Summary
static class RequestFailureException.FailureReason
          Reasons why a request fails.
 
Constructor Summary
RequestFailureException(String message, RequestFailureException.FailureReason reason)
          Constructs an instance with the specified detail message and reason.
RequestFailureException(String message, Throwable cause)
          Constructs an instance with the specified detail message and cause.
 
Method Summary
 RequestFailureException.FailureReason getReason()
          Returns a failure reason.
 
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
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RequestFailureException

public RequestFailureException(String message,
                               RequestFailureException.FailureReason reason)
Constructs an instance with the specified detail message and reason.

Parameters:
message - a detail message, or null
reason - a reason why the request failed

RequestFailureException

public RequestFailureException(String message,
                               Throwable cause)
Constructs an instance with the specified detail message and cause.

Parameters:
message - a detail message, or null
cause - the cause of this exception, or null
Method Detail

getReason

public RequestFailureException.FailureReason getReason()
Returns a failure reason. If the returned reason is RequestFailureException.FailureReason.OTHER, then the cause may contain an exception that caused the failure.

Returns:
a failure reason

RedDwarf, Version 0.10.1
2010-03-14 10:56:12

Copyright © 2010 The RedDwarf Authors. All rights reserved
Copyright © 2007-2010 Sun Microsystems, Inc. All rights reserved