Package com.chargehound.errors
Class ChargehoundExceptionFactory
- java.lang.Object
-
- com.chargehound.errors.ChargehoundExceptionFactory
-
public class ChargehoundExceptionFactory extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classChargehoundExceptionFactory.ChargehoundErrorDetailsDefine a class to parse the error message, status, and type.static classChargehoundExceptionFactory.ChargehoundErrorJsonDefine a class to parse the error Json.
-
Constructor Summary
Constructors Constructor Description ChargehoundExceptionFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ChargehoundExceptiongenericChargehoundException(java.lang.Exception error)Create a Chargehound exception from a generic exception.ChargehoundExceptionhttpResponseException(com.google.api.client.http.HttpResponseException error)Create a Chargehound exception from an Http exception.
-
-
-
Method Detail
-
httpResponseException
public ChargehoundException httpResponseException(com.google.api.client.http.HttpResponseException error)
Create a Chargehound exception from an Http exception.- Parameters:
error- an HTTP exception- Returns:
- ChargehoundException
-
genericChargehoundException
public ChargehoundException genericChargehoundException(java.lang.Exception error)
Create a Chargehound exception from a generic exception.- Parameters:
error- any exception exception- Returns:
- ChargehoundException
-
-