com.thirtyboxes.api
Class MethodCallFailedException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.thirtyboxes.api.MethodCallFailedException
All Implemented Interfaces:
java.io.Serializable

public class MethodCallFailedException
extends java.lang.Exception

Represents a failed call to the 30 Boxes API.

Version:
1.0
Author:
keith@kludge.co.uk
See Also:
ThirtyBoxes, Serialized Form

Constructor Summary
protected MethodCallFailedException(java.lang.String methodName, java.lang.Exception thrownException)
          Exception constructor.
protected MethodCallFailedException(java.lang.String methodName, RESTResult result)
          RESTResult constructor.
 
Method Summary
 java.lang.String getReasonString()
          Returns a user-readable explanation of the failure.
 
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
 

Constructor Detail

MethodCallFailedException

protected MethodCallFailedException(java.lang.String methodName,
                                    RESTResult result)
RESTResult constructor.

Parameters:
methodName - the method that failed during calling.
result - the RESTResult object returned from the call.

MethodCallFailedException

protected MethodCallFailedException(java.lang.String methodName,
                                    java.lang.Exception thrownException)
Exception constructor.

Parameters:
methodName - the method that failed during calling.
thrownException - the Exception that caused this to fail.
Method Detail

getReasonString

public java.lang.String getReasonString()
Returns a user-readable explanation of the failure.

Returns:
Explanation of the failure.