Class SecurityAnswerDefinitionStage
java.lang.Object
org.forgerock.selfservice.stages.kba.AbstractKbaStage<SecurityAnswerDefinitionConfig>
org.forgerock.selfservice.stages.kba.SecurityAnswerDefinitionStage
- All Implemented Interfaces:
ProgressStage<SecurityAnswerDefinitionConfig>
public final class SecurityAnswerDefinitionStage
extends AbstractKbaStage<SecurityAnswerDefinitionConfig>
Stage is responsible for supplying the KBA questions to the user and capturing the answers provided by the user.
- Since:
- 0.2.0
-
Field Summary
Fields inherited from class org.forgerock.selfservice.stages.kba.AbstractKbaStage
connectionFactory, cryptoService, REQUIREMENT_PROPERTY_ID, REQUIREMENT_PROPERTY_QUESTION, REQUIREMENT_PROPERTY_SYSTEM_QUESTION, REQUIREMENT_PROPERTY_USER_QUESTION -
Constructor Summary
ConstructorsConstructorDescriptionSecurityAnswerDefinitionStage(ConnectionFactory connectionFactory, SecurityAnswer securityAnswer) Constructs a new security answer definition stage. -
Method Summary
Modifier and TypeMethodDescriptionadvance(ProcessContext context, SecurityAnswerDefinitionConfig config) Advance the progress stage.gatherInitialRequirements(ProcessContext context, SecurityAnswerDefinitionConfig config) Response for defining any initial requirements the stage may have.
-
Constructor Details
-
SecurityAnswerDefinitionStage
@Inject public SecurityAnswerDefinitionStage(ConnectionFactory connectionFactory, SecurityAnswer securityAnswer) Constructs a new security answer definition stage.- Parameters:
connectionFactory- the CREST connection factorysecurityAnswer- the helper class for security answers
-
-
Method Details
-
gatherInitialRequirements
public JsonValue gatherInitialRequirements(ProcessContext context, SecurityAnswerDefinitionConfig config) throws ResourceException Description copied from interface:ProgressStageResponse for defining any initial requirements the stage may have.An empty json object implies no initial requirements.
- Parameters:
context- the current process contextconfig- the stage configuration- Returns:
- json value representing the requirements or empty json object for no requirements
- Throws:
ResourceException- if some expected state is invalid
-
advance
public StageResponse advance(ProcessContext context, SecurityAnswerDefinitionConfig config) throws ResourceException Description copied from interface:ProgressStageAdvance the progress stage.- Parameters:
context- the current process contextconfig- the stage configuration- Returns:
- the result of invoking this stage
- Throws:
ResourceException- if some expected state or input is invalid
-