Class NameIdentifierCanonicalization.ActivationCondition
- java.lang.Object
-
- net.shibboleth.idp.saml.nameid.impl.NameIdentifierCanonicalization.ActivationCondition
-
- All Implemented Interfaces:
Predicate<ProfileRequestContext>
- Enclosing class:
- NameIdentifierCanonicalization
public static class NameIdentifierCanonicalization.ActivationCondition extends Object implements Predicate<ProfileRequestContext>
A predicate that determines if this action can run or not.
-
-
Field Summary
Fields Modifier and Type Field Description private org.slf4j.LoggerlogClass logger.
-
Constructor Summary
Constructors Constructor Description ActivationCondition()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanapply(ProfileRequestContext profileRequestContext, SubjectCanonicalizationContext c14nContext, boolean duringAction)Helper method that runs either as part of thePredicateor directly from theNameIdentifierCanonicalization.doPreExecute(ProfileRequestContext, SubjectCanonicalizationContext)method above.protected booleanformatMatches(String format, SubjectCanonicalizationContext c14nContext)Check the format against the format list.booleantest(ProfileRequestContext input)
-
-
-
Method Detail
-
test
public boolean test(@Nullable ProfileRequestContext input)- Specified by:
testin interfacePredicate<ProfileRequestContext>
-
formatMatches
protected boolean formatMatches(@Nonnull @NotEmpty String format, @Nonnull SubjectCanonicalizationContext c14nContext)
Check the format against the format list. If we are in the action then we log the error into the C14N context and add the appropriate event to the profile request context.- Parameters:
format- the format to checkc14nContext- the current c14n context- Returns:
- true if the format matches
-
apply
public boolean apply(@Nonnull ProfileRequestContext profileRequestContext, @Nonnull SubjectCanonicalizationContext c14nContext, boolean duringAction)Helper method that runs either as part of thePredicateor directly from theNameIdentifierCanonicalization.doPreExecute(ProfileRequestContext, SubjectCanonicalizationContext)method above.- Parameters:
profileRequestContext- the current profile request contextc14nContext- the current c14n contextduringAction- true iff the method is run from the action above- Returns:
- true iff the action can operate successfully on the candidate contexts
-
-