/** * Set the next flow to run directly, instead of using a strategy map. * * <p>The transition rule is implicitly based on a "proceed" event occurring, * and assumes no custom transitions for any other events.</p> * @param flowId fully-qualified flow ID to run */ public void setNextFlow(@Nullable @NotEmpty final String flowId) { setNextFlowStrategyMap(Collections.<String,Object>singletonMap("proceed", flowId)); }
final MultiFactorAuthenticationTransition transition = mfaContext.getTransitionMap().get(prevFlowId); if (transition != null) { flowId = transition.getNextFlowStrategy(previousEvent).apply(profileRequestContext); if (flowId == null) { flowId = transition.getNextFlowStrategy("*").apply(profileRequestContext);
/** * Set a function to run directly instead of using a strategy map. * * <p>The transition rule is implicitly based on a "proceed" event occurring, * and assumes no custom transitions for any other events.</p> * @param strategy function to run */ public void setNextFlowStrategy(@Nonnull final Function<ProfileRequestContext,String> strategy) { Constraint.isNotNull(strategy, "Flow strategy function cannot be null"); setNextFlowStrategyMap(Collections.<String,Object>singletonMap("proceed", strategy)); }