com.jdroid.java.exception
Interface ErrorCode


public interface ErrorCode

Common interface for all the possible errors of the application


Method Summary
 Integer getResourceId()
           
 String getStatusCode()
           
 ApplicationException newApplicationException(String message)
           
 ApplicationException newApplicationException(Throwable throwable)
           
 BusinessException newBusinessException(Object... errorCodeParameters)
           
 

Method Detail

newBusinessException

BusinessException newBusinessException(Object... errorCodeParameters)
Parameters:
errorCodeParameters - The parameters for this ErrorCode's message.
Returns:
A new BusinessException with this ErrorCode

newApplicationException

ApplicationException newApplicationException(Throwable throwable)
Parameters:
throwable -
Returns:
A new ApplicationException with this ErrorCode

newApplicationException

ApplicationException newApplicationException(String message)
Parameters:
message -
Returns:
A new ApplicationException with this message

getResourceId

Integer getResourceId()
Returns:
The resource id

getStatusCode

String getStatusCode()
Returns:
The status code


Copyright © 2014. All rights reserved.