HttpServerException

class HttpServerException(val status: HttpStatus, msg: String, cause: Throwable) extends Exception with HttpServerExceptionBase

Exception to report errors to client

class Exception
class Throwable
trait Serializable
class Object
trait Matchable
class Any

Value members

Constructors

def this(status: HttpStatus)

Concrete methods

def accept: Seq[String]
def acceptsJson: Boolean
def acceptsMsgPack: Boolean
def addHeader(key: String, value: String): HttpServerException
def allow: Option[String]
def authorization: Option[String]
def cacheControl: Option[String]
def contentBytes: Array[Byte]
def contentEncoding: Option[String]
def contentLength: Option[Long]
def contentString: String
def contentType: Option[String]
def date: Option[String]
def expires: Option[String]
def getAllHeader(key: String): Seq[String]
def getHeader(key: String): Option[String]
def host: Option[String]
def isContentTypeJson: Boolean
def lastModified: Option[String]
def referer: Option[String]
def statusCode: Int
def userAgent: Option[String]
def withAccept(acceptType: String): HttpServerException
def withAllow(allow: String): HttpServerException
def withAuthorization(authorization: String): HttpServerException
def withCacheControl(cacheControl: String): HttpServerException
def withContent(content: String): HttpServerException
def withContent(content: Array[Byte]): HttpServerException
def withContentType(contentType: String): HttpServerException
def withDate(date: String): HttpServerException
def withDate(date: Instant): HttpServerException
def withExpires(expires: String): HttpServerException
def withHeader(key: String, value: String): HttpServerException
def withHost(host: String): HttpServerException
def withJson(json: String): HttpServerException
def withLastModified(lastModified: String): HttpServerException
def withMsgPack(msgPack: MsgPack): HttpServerException
def withReferer(referer: String): HttpServerException
def withUserAgent(userAgent: String): HttpServerException
def withXForwardedFor(xForwardedFor: String): HttpServerException
def withXForwardedProto(xForwardedProto: String): HttpServerException
def xForwardedFor: Option[String]
def xForwardedProto: Option[String]

Inherited methods

final def addSuppressed(x$0: Throwable): Unit
Inherited from:
Throwable
def fillInStackTrace(): Throwable
Inherited from:
Throwable
def getCause(): Throwable
Inherited from:
Throwable
def getLocalizedMessage(): String
Inherited from:
Throwable
def getMessage(): String
Inherited from:
Throwable
def getStackTrace(): Array[StackTraceElement]
Inherited from:
Throwable
final def getSuppressed(): Array[Throwable]
Inherited from:
Throwable
def initCause(x$0: Throwable): Throwable
Inherited from:
Throwable
def printStackTrace(x$0: PrintWriter): Unit
Inherited from:
Throwable
def printStackTrace(x$0: PrintStream): Unit
Inherited from:
Throwable
def printStackTrace(): Unit
Inherited from:
Throwable
def setStackTrace(x$0: Array[StackTraceElement]): Unit
Inherited from:
Throwable
def toString(): String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Returns:

a string representation of the object.

Inherited from:
Throwable
inline def withContentOf[A](a: A, codecFactory: MessageCodecFactory): HttpServerException

Set the content body using a given object and codec factory. Encoding can be JSON or MsgPack based on Content-Type header.

Set the content body using a given object and codec factory. Encoding can be JSON or MsgPack based on Content-Type header.

Inherited from:
HttpServerExceptionBase
inline def withContentOf[A](a: A): HttpServerException

Set the content body using a given object. Encoding can be JSON or MsgPack based on Content-Type header.

Set the content body using a given object. Encoding can be JSON or MsgPack based on Content-Type header.

Inherited from:
HttpServerExceptionBase
inline def withJsonOf[A](a: A, codecFactory: MessageCodecFactory): HttpServerException
inline def withJsonOf[A](a: A): HttpServerException
inline def withMsgPackOf[A](a: A, codecFactory: MessageCodecFactory): HttpServerException
inline def withMsgPackOf[A](a: A): HttpServerException

Concrete fields