public class ServletSecurityElement extends HttpConstraintElement
ServletSecurity
used to configre
security constraints for a Servlet.Constructor and Description |
---|
ServletSecurityElement()
Use default HttpConstraint.
|
ServletSecurityElement(java.util.Collection<HttpMethodConstraintElement> httpMethodConstraints)
Use specific constraints for specified methods and default
HttpConstraintElement for all other methods.
|
ServletSecurityElement(HttpConstraintElement httpConstraintElement)
Use specified HttpConstraintElement.
|
ServletSecurityElement(HttpConstraintElement httpConstraintElement,
java.util.Collection<HttpMethodConstraintElement> httpMethodConstraints)
Use specified HttpConstraintElement as default and specific constraints
for specified methods.
|
ServletSecurityElement(ServletSecurity annotation)
Create from an annotation.
|
Modifier and Type | Method and Description |
---|---|
java.util.Collection<HttpMethodConstraintElement> |
getHttpMethodConstraints()
Obtain the collection of security constraints configured for specific
methods.
|
java.util.Collection<java.lang.String> |
getMethodNames()
Obtain the collection HTTP methods for which security constraints have
been defined.
|
getEmptyRoleSemantic, getRolesAllowed, getTransportGuarantee
public ServletSecurityElement()
public ServletSecurityElement(HttpConstraintElement httpConstraintElement)
httpConstraintElement
- The constraintpublic ServletSecurityElement(java.util.Collection<HttpMethodConstraintElement> httpMethodConstraints)
httpMethodConstraints
- Method constraintsjava.lang.IllegalArgumentException
- if a method name is specified more than
oncepublic ServletSecurityElement(HttpConstraintElement httpConstraintElement, java.util.Collection<HttpMethodConstraintElement> httpMethodConstraints)
httpConstraintElement
- Default constrainthttpMethodConstraints
- Method constraintsjava.lang.IllegalArgumentException
- if a method name is specified more than
oncepublic ServletSecurityElement(ServletSecurity annotation)
annotation
- Annotation to use as the basis for the new instancejava.lang.IllegalArgumentException
- if a method name is specified more than
oncepublic java.util.Collection<HttpMethodConstraintElement> getHttpMethodConstraints()
public java.util.Collection<java.lang.String> getMethodNames()
Copyright © 2000-2022 Apache Software Foundation. All Rights Reserved.