public class HttpRequestMethodNotSupportedException extends ServletException
Constructor and Description |
---|
HttpRequestMethodNotSupportedException(String method)
Create a new HttpRequestMethodNotSupportedException.
|
HttpRequestMethodNotSupportedException(String method,
Collection<String> supportedMethods)
Create a new HttpRequestMethodNotSupportedException.
|
HttpRequestMethodNotSupportedException(String method,
String msg)
Create a new HttpRequestMethodNotSupportedException.
|
HttpRequestMethodNotSupportedException(String method,
String[] supportedMethods)
Create a new HttpRequestMethodNotSupportedException.
|
HttpRequestMethodNotSupportedException(String method,
String[] supportedMethods,
String msg)
Create a new HttpRequestMethodNotSupportedException.
|
Modifier and Type | Method and Description |
---|---|
String |
getMethod()
Return the HTTP request method that caused the failure.
|
Set<HttpMethod> |
getSupportedHttpMethods()
Return the actually supported HTTP methods as
HttpMethod instances,
or null if not known. |
String[] |
getSupportedMethods()
Return the actually supported HTTP methods, or
null if not known. |
getRootCause
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public HttpRequestMethodNotSupportedException(String method)
method
- the unsupported HTTP request methodpublic HttpRequestMethodNotSupportedException(String method, String msg)
method
- the unsupported HTTP request methodmsg
- the detail messagepublic HttpRequestMethodNotSupportedException(String method, @Nullable Collection<String> supportedMethods)
method
- the unsupported HTTP request methodsupportedMethods
- the actually supported HTTP methods (may be null
)public HttpRequestMethodNotSupportedException(String method, @Nullable String[] supportedMethods)
method
- the unsupported HTTP request methodsupportedMethods
- the actually supported HTTP methods (may be null
)public HttpRequestMethodNotSupportedException(String method, @Nullable String[] supportedMethods, String msg)
method
- the unsupported HTTP request methodsupportedMethods
- the actually supported HTTP methodsmsg
- the detail messagepublic String getMethod()
@Nullable public String[] getSupportedMethods()
null
if not known.@Nullable public Set<HttpMethod> getSupportedHttpMethods()
HttpMethod
instances,
or null
if not known.