Package play.server

Class ServerHelper

java.lang.Object
play.server.ServerHelper

@ParametersAreNonnullByDefault public class ServerHelper extends Object
  • Field Details

    • SERVER_HELPER_FIND_FILE_TMP_PATH_PREFIX

      public static final String SERVER_HELPER_FIND_FILE_TMP_PATH_PREFIX
      See Also:
  • Constructor Details

    • ServerHelper

      public ServerHelper()
  • Method Details

    • maxContentLength

      @CheckReturnValue public static int maxContentLength(int defaultValue)
    • isKeepAlive

      @CheckReturnValue public boolean isKeepAlive(String protocol, String connectionHeader)
    • isModified

      @CheckReturnValue public boolean isModified(String eTag, long last, @Nullable String ifNoneMatch, @Nullable String ifModifiedSince)
    • generateNotFoundResponse

      @Nonnull @CheckReturnValue public String generateNotFoundResponse(Http.Request request, String format, NotFound e)
    • generateErrorResponse

      @Nonnull @CheckReturnValue public String generateErrorResponse(Http.Request request, String format, Exception e)
    • getContentTypeValue

      public String getContentTypeValue(Http.Response response)
    • findFile

      @Nullable @CheckReturnValue public static File findFile(String resource)
    • relativeUrl

      @Nonnull @CheckReturnValue public String relativeUrl(String path, @Nullable String query)