Package org.opensaml.security.x509.impl

# Class StaticPKIXValidationInformationResolver

java.lang.Object
org.opensaml.security.x509.impl.StaticPKIXValidationInformationResolver

All Implemented Interfaces:
  `Resolver<PKIXValidationInformation,CriteriaSet>`, `PKIXValidationInformationResolver`

public class StaticPKIXValidationInformationResolver extends Object implements PKIXValidationInformationResolver
An implementation of `PKIXValidationInformationResolver` which always returns a static, fixed set of information.

## Field Summary

Fields
Modifier and Type
Field
Description
`private final List<PKIXValidationInformation>`
`pkixInfo`
The PKIX validation information to return.
`private boolean`
`supportDynamicTrustedNames`
Flag indicating whether dynamic trusted names should be extracted from criteria set.
`private final Set<String>`
`trustedNames`
The set of trusted names to return.

## Constructor Summary

Constructors
Constructor
Description
`StaticPKIXValidationInformationResolver(List<PKIXValidationInformation> info, Set<String> names)`
Constructor.
`StaticPKIXValidationInformationResolver(List<PKIXValidationInformation> info, Set<String> names, boolean supportDynamicNames)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`Iterable<PKIXValidationInformation>`
`resolve(CriteriaSet criteria)`
`PKIXValidationInformation`
`resolveSingle(CriteriaSet criteria)`
`Set<String>`
`resolveTrustedNames(CriteriaSet criteriaSet)`
Resolve a set of trusted names associated with the entity indicated by the criteria.
`boolean`
`supportsTrustedNameResolution()`
Check whether resolution of trusted names is supported.

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

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

## Field Details

### pkixInfo

@Nonnull private final List<PKIXValidationInformation> pkixInfo
The PKIX validation information to return.

### trustedNames

@Nonnull private final Set<String> trustedNames
The set of trusted names to return.

### supportDynamicTrustedNames

private boolean supportDynamicTrustedNames
Flag indicating whether dynamic trusted names should be extracted from criteria set.

## Constructor Details

### StaticPKIXValidationInformationResolver

public StaticPKIXValidationInformationResolver(@Nullable @ParameterName(name="info") List<PKIXValidationInformation> info, @Nullable @ParameterName(name="names") Set<String> names)
Constructor.

Dynamic trusted names will not be supported.

Parameters:
  `info` - list of PKIX validation information to return
  `names` - set of trusted names to return

### StaticPKIXValidationInformationResolver

public StaticPKIXValidationInformationResolver(@Nullable @ParameterName(name="info") List<PKIXValidationInformation> info, @Nullable @ParameterName(name="names") Set<String> names, @ParameterName(name="supportDynamicNames") boolean supportDynamicNames)
Constructor.

Parameters:
  `info` - list of PKIX validation information to return
  `names` - set of trusted names to return
  `supportDynamicNames` - whether resolver should support dynamic extraction of trusted names from an instance of `TrustedNamesCriterion` in the criteria set

## Method Details

### resolveTrustedNames

@Nonnull public Set<String> resolveTrustedNames(@Nullable CriteriaSet criteriaSet) throws ResolverException
Resolve a set of trusted names associated with the entity indicated by the criteria. This method is optional to implement.

Specified by:
  `resolveTrustedNames` in interface `PKIXValidationInformationResolver`
Parameters:
  `criteriaSet` - set of criteria used to determine or resolve the trusted names
Returns:
  the set of certificate names trusted for an entity
Throws:
  `ResolverException` - thrown if there is an error resolving the trusted names

### supportsTrustedNameResolution

public boolean supportsTrustedNameResolution()
Check whether resolution of trusted names is supported.

Specified by:
  `supportsTrustedNameResolution` in interface `PKIXValidationInformationResolver`
Returns:
  true if the implementation supports resolution of trusted names, otherwise false

### resolve

@Nonnull public Iterable<PKIXValidationInformation> resolve(@Nullable CriteriaSet criteria) throws ResolverException

Specified by:
  `resolve` in interface `Resolver<PKIXValidationInformation,CriteriaSet>`
Throws:
  `ResolverException`

### resolveSingle

@Nullable public PKIXValidationInformation resolveSingle(@Nullable CriteriaSet criteria) throws ResolverException

Specified by:
  `resolveSingle` in interface `Resolver<PKIXValidationInformation,CriteriaSet>`
Throws:
  `ResolverException`