Class HttpMethodConstraintElement
java.lang.Object
jakarta.servlet.HttpConstraintElement
jakarta.servlet.HttpMethodConstraintElement
Programmatic equivalent of a security constraint defined for a single HTTP method.
- Since:
- Servlet 3.0
-
Constructor Summary
ConstructorDescriptionHttpMethodConstraintElement
(String methodName) Construct an instance for the given HTTP method name and a defaultHttpConstraintElement
.HttpMethodConstraintElement
(String methodName, HttpConstraintElement constraint) Construct an instance for the given HTTP method name andHttpConstraintElement
. -
Method Summary
Modifier and TypeMethodDescriptionObtain the name of the HTTP method for which this constraint was created.Methods inherited from class jakarta.servlet.HttpConstraintElement
getEmptyRoleSemantic, getRolesAllowed, getTransportGuarantee
-
Constructor Details
-
HttpMethodConstraintElement
Construct an instance for the given HTTP method name and a defaultHttpConstraintElement
.- Parameters:
methodName
- The HTTP method name
-
HttpMethodConstraintElement
Construct an instance for the given HTTP method name andHttpConstraintElement
.- Parameters:
methodName
- The HTTP method nameconstraint
- The constraint for the given method
-
-
Method Details
-
getMethodName
Obtain the name of the HTTP method for which this constraint was created.- Returns:
- The HTTP method name as provided to the constructor
-