Class BasicHttpServletRequestMethodValidator
java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
net.shibboleth.shared.servlet.impl.BasicHttpServletRequestMethodValidator
- All Implemented Interfaces:
Component,DestructableComponent,InitializableComponent,HttpServletRequestValidator
public class BasicHttpServletRequestMethodValidator
extends AbstractInitializableComponent
implements HttpServletRequestValidator
Component that validates the HTTP request method as one of an allowed set.
- Since:
- 9.2.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the allowed methods.voidsetAllowedMethods(Collection<String> methods) Set the allowed methods.voidvalidate(HttpServletRequest request) Validate the request.Methods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent
checkComponentActive, checkSetterPreconditions, destroy, doDestroy, doInitialize, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, initialize, isDestroyed, isInitialized
-
Field Details
-
allowedMethods
Allowed parameters.
-
-
Constructor Details
-
BasicHttpServletRequestMethodValidator
public BasicHttpServletRequestMethodValidator()Constructor.
-
-
Method Details
-
getAllowedMethods
Get the allowed methods.- Returns:
- the allowed methods
-
setAllowedMethods
Set the allowed methods.- Parameters:
methods- the allowed methods
-
validate
Validate the request.- Specified by:
validatein interfaceHttpServletRequestValidator- Parameters:
request- the request to validate- Throws:
ServletException- if the request is determined to be invalid
-