com.shephertz.app42.paas.sdk.java
Class App42Exception

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by com.shephertz.app42.paas.sdk.java.App42Exception
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
App42BadParameterException, App42LimitException, App42NotFoundException, App42SecurityException

public class App42Exception
extends java.lang.RuntimeException

Author:
Ajay Tiwari
See Also:
Serialized Form

Constructor Summary
App42Exception()
           
App42Exception(int httpErrorCode, int appErrorCode)
          Constructor which takes httpErrorCode and the appErrorCode
App42Exception(java.lang.String detailMessage)
           
App42Exception(java.lang.String detailMessage, int httpErrorCode, int appErrorCode)
          Constructor which takes message, httpErrorCode and the appErrorCode
App42Exception(java.lang.String detailMessage, java.lang.Throwable throwable)
           
App42Exception(java.lang.Throwable throwable)
           
 
Method Summary
 int getAppErrorCode()
          Gets the AppErrorCode for the Exception.
 int getHttpErrorCode()
          Gets the HttpErrorCode for the Exception e.g.
 void setAppErrorCode(int appErrorCode)
          Sets the AppErrorCode for the Exception
 void setHttpErrorCode(int httpErrorCode)
          Sets the HttpErrorCode for the Exception
 
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

App42Exception

public App42Exception()

App42Exception

public App42Exception(java.lang.String detailMessage)
Parameters:
detailMessage -

App42Exception

public App42Exception(java.lang.Throwable throwable)
Parameters:
throwable -

App42Exception

public App42Exception(java.lang.String detailMessage,
                      java.lang.Throwable throwable)
Parameters:
detailMessage -
throwable -

App42Exception

public App42Exception(java.lang.String detailMessage,
                      int httpErrorCode,
                      int appErrorCode)
Constructor which takes message, httpErrorCode and the appErrorCode

Parameters:
detailMessage -
httpErrorCode -
appErrorCode -

App42Exception

public App42Exception(int httpErrorCode,
                      int appErrorCode)
Constructor which takes httpErrorCode and the appErrorCode

Parameters:
httpErrorCode -
appErrorCode -
Method Detail

setHttpErrorCode

public void setHttpErrorCode(int httpErrorCode)
Sets the HttpErrorCode for the Exception

Parameters:
httpErrorCode - The http error code e.g. 404, 500, 401 etc.

getHttpErrorCode

public int getHttpErrorCode()
Gets the HttpErrorCode for the Exception e.g. 404, 500, 401 etc.


setAppErrorCode

public void setAppErrorCode(int appErrorCode)
Sets the AppErrorCode for the Exception

Parameters:
appErrorCode - App error codes correspond to the error which specific to the service. This error code can help App developers to take decisions and take action when a particular error occurs for a service

getAppErrorCode

public int getAppErrorCode()
Gets the AppErrorCode for the Exception. App error codes correspond to the error which specific to the service. This error code can help App developers to take decisions and take action when a particular error occurs for a service