Class ErrorResponseContentCreator


  • public class ErrorResponseContentCreator
    extends java.lang.Object
    Creates HTML body having the status code, error message and request uri. The body is constructed from a template that is inspired by the default Jetty template (see Response.sendError(int, String)). The content is written using the ISO-8859-1 charset.
    Author:
    bjorncs
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      byte[] createErrorContent​(java.lang.String requestUri, int statusCode, java.util.Optional<java.lang.String> message)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ErrorResponseContentCreator

        public ErrorResponseContentCreator()
    • Method Detail

      • createErrorContent

        public byte[] createErrorContent​(java.lang.String requestUri,
                                         int statusCode,
                                         java.util.Optional<java.lang.String> message)