Package org.actioncontroller.exceptions
Class HttpActionException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.actioncontroller.exceptions.HttpActionException
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
HttpNotModifiedException,HttpRedirectException,HttpRequestException,HttpServerErrorException,JsonHttpActionException
public class HttpActionException extends RuntimeException
Indicates that an error happened during the invocation of an action and that the user agent should receive the HTTPstatusCode.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description HttpActionException(int statusCode, String message)HttpActionException(int statusCode, Throwable e)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetStatusCode()voidsendError(ApiHttpExchange exchange)StringtoString()-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-
Method Detail
-
getStatusCode
public int getStatusCode()
-
sendError
public void sendError(ApiHttpExchange exchange) throws IOException
- Throws:
IOException
-
-