Class PopulateAttributeReleaseContext

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

public class PopulateAttributeReleaseContext extends AbstractAttributeReleaseAction
Attribute consent action to populate the attribute consent context with the attributes for which consent should be obtained. A predicate is used to determine whether consent should be obtained for each IdP attribute in the attribute context.
Event:
EventIds.PROCEED_EVENT_ID
Postcondition:
See above.
  • Field Details

    • log

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

      @Nonnull private Predicate<IdPAttribute> attributePredicate
      Predicate to determine whether consent should be obtained for an attribute.
    • attributeIdComparator

      @Nullable private Comparator<String> attributeIdComparator
      Comparator used to sort attributes displayed to user.
  • Constructor Details

    • PopulateAttributeReleaseContext

      public PopulateAttributeReleaseContext()
  • Method Details

    • setAttributePredicate

      public void setAttributePredicate(@Nonnull Predicate<IdPAttribute> predicate)
      Set the predicate to determine whether consent should be obtained for an attribute.
      Parameters:
      predicate - predicate to determine whether consent should be obtained for an attribute
    • setAttributeIdComparator

      public void setAttributeIdComparator(@Nullable Comparator<String> comparator)
      Set the comparator used to sort attributes displayed to user.
      Parameters:
      comparator - comparator used to sort attributes displayed to user
    • doInitialize

      protected void doInitialize() throws ComponentInitializationException
      Overrides:
      doInitialize in class AbstractInitializableComponent
      Throws:
      ComponentInitializationException
    • doExecute

      protected void doExecute(@Nonnull ProfileRequestContext profileRequestContext, @Nonnull ProfileInterceptorContext interceptorContext)
      Performs this profile interceptor action. Default implementation does nothing.
      Overrides:
      doExecute in class AbstractProfileInterceptorAction
      Parameters:
      profileRequestContext - the current profile request context
      interceptorContext - the current profile interceptor context