Class NotAllowedException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
io.micronaut.http.exceptions.HttpException
io.micronaut.http.exceptions.HttpStatusException
io.micronaut.http.server.exceptions.NotAllowedException
All Implemented Interfaces:
Serializable

public final class NotAllowedException extends io.micronaut.http.exceptions.HttpStatusException
Exception thrown when the request HTTP Method is not allowed.
Since:
4.6.0
See Also:
  • Constructor Details

    • NotAllowedException

      public NotAllowedException(String requestMethod, URI uri, Set<String> allowedMethods)
      Parameters:
      requestMethod - Request Method
      uri - The URI
      allowedMethods - Allowed methods for URI
  • Method Details

    • getRequestMethod

      public String getRequestMethod()
      Returns:
      Request Method
    • getUri

      public URI getUri()
      Returns:
      The URI
    • getAllowedMethods

      public Set<String> getAllowedMethods()
      Returns:
      Allowed methods for URI