## org.plovr
Class HttpUtil

    java.lang.Object
      org.plovr.HttpUtil

    public final class HttpUtil

extends java.lang.Object

Method Summary
`static java.net.URI` `getReferrer(com.sun.net.httpserver.HttpExchange exchange)`
`static void` `return404(com.sun.net.httpserver.HttpExchange exchange)`
`static void` `writeErrorMessageResponse(com.sun.net.httpserver.HttpExchange exchange, java.lang.String message)` Returns a 400 with the specified message.
`static void` `writeHtmlErrorMessageResponse(com.sun.net.httpserver.HttpExchange exchange, java.lang.String htmlMessage)` Returns a 400 with the specified HTML message.
`static void` `writeHtmlErrorMessageResponse(com.sun.net.httpserver.HttpExchange exchange, java.lang.String htmlMessage, int errorCode)`
`static void` `writeNotFound(com.sun.net.httpserver.HttpExchange exchange)`
`static void` `writeNullResponse(com.sun.net.httpserver.HttpExchange exchange)` Returns a 400 with no message.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### getReferrer

    public static java.net.URI getReferrer(com.sun.net.httpserver.HttpExchange exchange)

### writeNullResponse

    public static void writeNullResponse(com.sun.net.httpserver.HttpExchange exchange)
                                  throws java.io.IOException

  Returns a 400 with no message.

  Throws:
    `java.io.IOException`

### writeNotFound

    public static void writeNotFound(com.sun.net.httpserver.HttpExchange exchange)
                              throws java.io.IOException

  Throws:
    `java.io.IOException`

### writeErrorMessageResponse

    public static void writeErrorMessageResponse(com.sun.net.httpserver.HttpExchange exchange,
                                                 java.lang.String message)
                                          throws java.io.IOException

  Returns a 400 with the specified message.

  Throws:
    `java.io.IOException`

### return404

    public static void return404(com.sun.net.httpserver.HttpExchange exchange)
                          throws java.io.IOException

  Throws:
    `java.io.IOException`

### writeHtmlErrorMessageResponse

    public static void writeHtmlErrorMessageResponse(com.sun.net.httpserver.HttpExchange exchange,
                                                     java.lang.String htmlMessage,
                                                     int errorCode)
                                              throws java.io.IOException

  Throws:
    `java.io.IOException`

### writeHtmlErrorMessageResponse

    public static void writeHtmlErrorMessageResponse(com.sun.net.httpserver.HttpExchange exchange,
                                                     java.lang.String htmlMessage)
                                              throws java.io.IOException

  Returns a 400 with the specified HTML message.

  Throws:
    `java.io.IOException`