Class ResponseFactory

java.lang.Object
com.djrapitops.plan.delivery.webserver.ResponseFactory

@Singleton public class ResponseFactory extends Object
Factory for creating different Response objects.
  • Constructor Details

  • Method Details

    • getResource

      public WebResource getResource(String resourceName)
    • playersPageResponse

      public Response playersPageResponse()
    • internalErrorResponse

      public Response internalErrorResponse(Throwable e, String cause)
    • networkPageResponse

      public Response networkPageResponse()
    • serverPageResponse

      public Response serverPageResponse(ServerUUID serverUUID)
    • rawPlayerPageResponse

      public Response rawPlayerPageResponse(UUID playerUUID)
    • javaScriptResponse

      public Response javaScriptResponse(String fileName)
    • cssResponse

      public Response cssResponse(String fileName)
    • imageResponse

      public Response imageResponse(String fileName)
    • fontResponse

      public Response fontResponse(String fileName)
    • redirectResponse

      public Response redirectResponse(String location)
    • faviconResponse

      public Response faviconResponse()
    • robotsResponse

      public Response robotsResponse()
    • pageNotFound404

      public Response pageNotFound404()
    • uuidNotFound404

      public Response uuidNotFound404()
    • playerNotFound404

      public Response playerNotFound404()
    • notFound404

      public Response notFound404(String message)
    • basicAuthFail

      public Response basicAuthFail(WebUserAuthException e)
    • forbidden403

      public Response forbidden403()
    • forbidden403

      public Response forbidden403(String message)
    • failedLoginAttempts403

      public Response failedLoginAttempts403()
    • ipWhitelist403

      public Response ipWhitelist403(String accessor)
    • basicAuth

      public Response basicAuth()
    • badRequest

      public Response badRequest(String errorMessage, String target)
    • playerPageResponse

      public Response playerPageResponse(UUID playerUUID)
    • loginPageResponse

      public Response loginPageResponse()
    • registerPageResponse

      public Response registerPageResponse()
    • queryPageResponse

      public Response queryPageResponse()
    • errorsPageResponse

      public Response errorsPageResponse()
    • jsonFileResponse

      public Response jsonFileResponse(String file)