Package net.shibboleth.idp.saml.saml1.profile.impl

# Class FilterByQueriedAttributeDesignators

java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
org.opensaml.profile.action.AbstractProfileAction
org.opensaml.profile.action.AbstractConditionalProfileAction
net.shibboleth.idp.profile.AbstractProfileAction
net.shibboleth.idp.saml.saml1.profile.impl.FilterByQueriedAttributeDesignators

All Implemented Interfaces:
  `Component`, `DestructableComponent`, `InitializableComponent`, `ProfileAction`, `Aware`, `MessageSource`, `MessageSourceAware`, `Action`

public class FilterByQueriedAttributeDesignators extends AbstractProfileAction
Action that filters a set of attributes against the `AttributeDesignator` objects in an `AttributeQuery`.

Event:
  `EventIds.PROCEED_EVENT_ID`

## Field Summary

Fields
Modifier and Type
Field
Description
`private AttributeContext`
`attributeContext`
AttributeContext to filter.
`private Function<ProfileRequestContext,AttributeContext>`
`attributeContextLookupStrategy`
Strategy used to locate the `AttributeContext` to filter.
`private final org.slf4j.Logger`
`log`
Class logger.
`private AttributeQuery`
`query`
Query to filter against.
`private Function<ProfileRequestContext,Request>`
`requestLookupStrategy`
Strategy used to locate the `Request` containing the query to filter against.
`private ReloadableService<AttributeTranscoderRegistry>`
`transcoderRegistry`
Transcoder registry service object.

## Constructor Summary

Constructors
Constructor
Description
`FilterByQueriedAttributeDesignators()`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`private void`
`decodeAttributeDesignator(AttributeTranscoderRegistry registry, ProfileRequestContext profileRequestContext, AttributeDesignator input, Collection<String> results)`
Access the registry of transcoding rules to decode the input `AttributeDesignator`.
`protected void`
`doExecute(ProfileRequestContext profileRequestContext)`
`protected void`
`doInitialize()`
`protected boolean`
`doPreExecute(ProfileRequestContext profileRequestContext)`
`void`
`setAttributeContextLookupStrategy(Function<ProfileRequestContext,AttributeContext> strategy)`
Set the strategy used to locate the `AttributeContext` associated with a given `ProfileRequestContext`.
`void`
`setRequestLookupStrategy(Function<ProfileRequestContext,Request> strategy)`
Set the strategy used to locate the `Request` associated with a given `ProfileRequestContext`.
`void`
`setTranscoderRegistry(ReloadableService<AttributeTranscoderRegistry> registry)`
Sets the registry of transcoding rules to apply to encode attributes.

### Methods inherited from class net.shibboleth.idp.profile.AbstractProfileAction

`doExecute, execute, getBean, getBean, getMessage, getMessage, getMessage, getParameter, getParameter, getProfileContextLookupStrategy, getRequestContext, getResult, setMessageSource, setProfileContextLookupStrategy`

### Methods inherited from class org.opensaml.profile.action.AbstractConditionalProfileAction

`getActivationCondition, setActivationCondition`

### Methods inherited from class org.opensaml.profile.action.AbstractProfileAction

`doPostExecute, doPostExecute, ensureHttpServletRequest, ensureHttpServletResponse, execute, getHttpServletRequest, getHttpServletRequestSupplier, getHttpServletResponse, getHttpServletResponseSupplier, getLogPrefix, isPreExecuteCalled, setHttpServletRequestSupplier, setHttpServletResponseSupplier`

### Methods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent

`checkComponentActive, checkSetterPreconditions, destroy, doDestroy, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, 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.shared.component.InitializableComponent

`initialize, isInitialized`

## Field Details

### log

@Nonnull private final org.slf4j.Logger log
Class logger.

### transcoderRegistry

@NonnullAfterInit private ReloadableService<AttributeTranscoderRegistry> transcoderRegistry
Transcoder registry service object.

### requestLookupStrategy

@Nonnull private Function<ProfileRequestContext,Request> requestLookupStrategy
Strategy used to locate the `Request` containing the query to filter against.

### attributeContextLookupStrategy

@Nonnull private Function<ProfileRequestContext,AttributeContext> attributeContextLookupStrategy
Strategy used to locate the `AttributeContext` to filter.

### query

@NonnullBeforeExec private AttributeQuery query
Query to filter against.

### attributeContext

@NonnullBeforeExec private AttributeContext attributeContext
AttributeContext to filter.

## Constructor Details

### FilterByQueriedAttributeDesignators

public FilterByQueriedAttributeDesignators()
Constructor.

## Method Details

### setTranscoderRegistry

public void setTranscoderRegistry(@Nonnull ReloadableService<AttributeTranscoderRegistry> registry)
Sets the registry of transcoding rules to apply to encode attributes.

Parameters:
  `registry` - registry service interface

### setRequestLookupStrategy

public void setRequestLookupStrategy(@Nonnull Function<ProfileRequestContext,Request> strategy)
Set the strategy used to locate the `Request` associated with a given `ProfileRequestContext`.

Parameters:
  `strategy` - lookup strategy

### setAttributeContextLookupStrategy

public void setAttributeContextLookupStrategy(@Nonnull Function<ProfileRequestContext,AttributeContext> strategy)
Set the strategy used to locate the `AttributeContext` associated with a given `ProfileRequestContext`.

Parameters:
  `strategy` - lookup strategy

### doInitialize

protected void doInitialize() throws ComponentInitializationException

Overrides:
  `doInitialize` in class `AbstractInitializableComponent`
Throws:
  `ComponentInitializationException`

### doPreExecute

protected boolean doPreExecute(@Nonnull ProfileRequestContext profileRequestContext)

Overrides:
  `doPreExecute` in class `AbstractConditionalProfileAction`

### doExecute

protected void doExecute(@Nonnull ProfileRequestContext profileRequestContext)

Overrides:
  `doExecute` in class `AbstractProfileAction`

### decodeAttributeDesignator

private void decodeAttributeDesignator(@Nonnull AttributeTranscoderRegistry registry, @Nonnull ProfileRequestContext profileRequestContext, @Nonnull AttributeDesignator input, @Nonnull @Live Collection<String> results) throws AttributeDecodingException
Access the registry of transcoding rules to decode the input `AttributeDesignator`.

Parameters:
  `registry` - registry of transcoding rules
  `profileRequestContext` - current profile request context
  `input` - input object
  `results` - collection to add attributeIDs to
Throws:
  `AttributeDecodingException` - if an error occurs or no results were obtained