public static Set<Event> resolveEventViaMultivaluedAttribute(final Principal principal,
                                                                 final Object attributeValue,
                                                                 final RegisteredService service,
                                                                 final Optional<RequestContext> context,
                                                                 final MultifactorAuthenticationProvider provider,
                                                                 final Predicate<String> predicate) {
        val events = new HashSet<Event>();
        if (attributeValue instanceof Collection) {
            val values = (Collection<String>) attributeValue;
            values.forEach(value -> {
                try {
                    if (predicate.test(value)) {
                        val id = provider.getId();
                        val event = validateEventIdForMatchingTransitionInContext(id, context, buildEventAttributeMap(principal, Optional.of(service), provider));
                        events.add(event);
                    }
                } catch (final Exception e) {
                    LOGGER.debug("Ignoring [{}] since no matching transition could be found", value);
                }
            });
            return events;
        }

        return null;
    }
public static Set < Event > resolveEventViaMultivaluedAttribute ( final Principal principal , final Object attributeValue , final RegisteredService service , final Optional < RequestContext > context , final MultifactorAuthenticationProvider provider , final Predicate < String > predicate ) { val events = new HashSet < Event > ( ) ; if ( attributeValue instanceof Collection ) { val values = ( Collection < String > ) attributeValue ; values . forEach ( value -> { try { if ( predicate . test ( value ) ) { val id = provider . getId ( ) ; val event = validateEventIdForMatchingTransitionInContext ( id , context , buildEventAttributeMap ( principal , Optional . of ( service ) , provider ) ) ; events . add ( event ) ; } } catch ( final Exception e ) { LOGGER . debug ( "Ignoring [{}] since no matching transition could be found" , value ) ; } } ) ; return events ; } return null ; }
Resolve event via multivalued attribute set.

@param principal      the principal
@param attributeValue the attribute value
@param service        the service
@param context        the context
@param provider       the provider
@param predicate      the predicate
@return the set