Package net.shibboleth.idp.attribute.resolver.logic

# Class ResolutionLabelPredicate

java.lang.Object
net.shibboleth.shared.logic.StrategyIndirectedPredicate<ProfileRequestContext,String>
net.shibboleth.idp.attribute.resolver.logic.ResolutionLabelPredicate

All Implemented Interfaces:
  `Predicate<ProfileRequestContext>`

public class ResolutionLabelPredicate extends StrategyIndirectedPredicate<ProfileRequestContext,String>
Predicate that evaluates a `ProfileRequestContext` by looking for an attribute resolution label that matches one of a designated set or a generic predicate. The ID is obtained from a lookup function, by default from a `AttributeResolutionContext` child of the profile request context.

Since:
  4.1.0

## Constructor Summary

Constructors
Constructor
Description
`ResolutionLabelPredicate(Collection<String> candidates)`
Constructor.
`ResolutionLabelPredicate(Predicate<String> pred)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`(package private) static ResolutionLabelPredicate`
`byList(Collection<String> candidates)`
Factory Method to avoid type-coercion warnings from Spring.
`(package private) static ResolutionLabelPredicate`
`byPredicate(Predicate<String> pred)`
Factory Method to avoid type-coercion warnings fromSpring.

### Methods inherited from class net.shibboleth.shared.logic.StrategyIndirectedPredicate

`forCollection, forPredicate, test`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface java.util.function.Predicate

`and, negate, or`

## Constructor Details

### ResolutionLabelPredicate

public ResolutionLabelPredicate(@ParameterName(name="candidates") @Nonnull Collection<String> candidates)
Constructor.

Parameters:
  `candidates` - hardwired set of values to check against

### ResolutionLabelPredicate

public ResolutionLabelPredicate(@ParameterName(name="pred") @Nonnull Predicate<String> pred)
Constructor.

Parameters:
  `pred` - generalized predicate

## Method Details

### byList

static ResolutionLabelPredicate byList(@Nonnull Collection<String> candidates)
Factory Method to avoid type-coercion warnings from Spring.

Parameters:
  `candidates` - hardwired set of values to check against
Returns:
  the result of calling `ResolutionLabelPredicate(Collection)`

### byPredicate

static ResolutionLabelPredicate byPredicate(@Nonnull Predicate<String> pred)
Factory Method to avoid type-coercion warnings fromSpring.

Parameters:
  `pred` - generalized predicate
Returns:
  the result of calling `ResolutionLabelPredicate(Predicate)`