Class PolicyFromMatcherId
java.lang.Object
net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
net.shibboleth.idp.attribute.filter.BaseBridgingClass
net.shibboleth.idp.attribute.filter.PolicyFromMatcherId
- All Implemented Interfaces:
PolicyRequirementRule
,Component
,DestructableComponent
,IdentifiableComponent
,IdentifiedComponent
,InitializableComponent
public final class PolicyFromMatcherId
extends BaseBridgingClass
implements PolicyRequirementRule, IdentifiedComponent, DestructableComponent
Bridging class to go from a
Matcher
to a PolicyRequirementRule
.
If the value of the supplied attribute matches then this is true, otherwise false.
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.shibboleth.idp.attribute.filter.PolicyRequirementRule
PolicyRequirementRule.Tristate
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final String
The attribute Id we care about.private final org.slf4j.Logger
Class logger.private final Matcher
The rule we are shadowing.Fields inherited from interface net.shibboleth.idp.attribute.filter.PolicyRequirementRule
MATCHES_ALL, MATCHES_NONE, REQUIREMENT_RULE_FAILS
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the Id of the attribute in question.Testing support.matches
(AttributeFilterContext context) Evaluate what this rule means.Methods inherited from class net.shibboleth.idp.attribute.filter.BaseBridgingClass
doDestroy, doInitialize, getLogPrefix
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
setId
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
getId
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, initialize, isDestroyed, isInitialized
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.shibboleth.utilities.java.support.component.DestructableComponent
destroy, isDestroyed
Methods inherited from interface net.shibboleth.utilities.java.support.component.IdentifiableComponent
setId
Methods inherited from interface net.shibboleth.utilities.java.support.component.IdentifiedComponent
getId
-
Field Details
-
theMatcher
The rule we are shadowing. -
attributeId
The attribute Id we care about. -
log
private final org.slf4j.Logger logClass logger.
-
-
Constructor Details
-
PolicyFromMatcherId
public PolicyFromMatcherId(@Nonnull @ParameterName(name="matcher") Matcher matcher, @Nonnull @NotEmpty @ParameterName(name="attribute") String attribute) Constructor.- Parameters:
matcher
- the class we are bridging toattribute
- the Id of the attribute in question.
-
-
Method Details
-
getAttributeId
Gets the Id of the attribute in question.- Returns:
- the id.
-
getMatcher
Testing support. Get the embedded matcher.- Returns:
- the embedded matcher.
-
matches
Evaluate what this rule means.- Specified by:
matches
in interfacePolicyRequirementRule
- Parameters:
context
- the context.- Returns:
- whether the rule holds
-