Class Action
- java.lang.Object
-
- org.forgerock.openam.auth.node.api.Action
-
@SupportedAll public final class Action extends Object
Immutable container for the result of processing a node.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Action.ActionBuilder
Builder for theAction
.
-
Field Summary
Fields Modifier and Type Field Description List<Callback>
callbacks
Callbacks requested by the node when the outcome is null.static String
DESCRIPTION
Key for the description return property.String
errorMessage
The error message to present to the caller when the FAILURE node is reached.static String
HEADER
Key for the header return property.Optional<org.forgerock.openam.auth.node.api.IdentifiedIdentity>
identifiedIdentity
Optionally the identity confirmed to exist as part of this action.String
lockoutMessage
The error message to present to the caller when the user is locked out.String
outcome
Result of the node.Map<String,Object>
returnProperties
Properties to return to the client.List<JsonValue>
sessionHooks
List of classes implementingTreeHook
that run after successful login.Map<String,String>
sessionProperties
Properties that will be included in the user's session if/when it is created.JsonValue
sharedState
The output state of the node.static String
STAGE
Key for the stage return property.SuspensionHandler
suspensionHandler
TheSuspensionHandler
to call when the authentication process is suspended by the authentication framework.JsonValue
transientState
The transient state of the node.Optional<String>
universalId
Deprecated.useidentifiedIdentity
instead.List<String>
webhooks
List of webhooks that run after logout.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static Action.ActionBuilder
goTo(String outcome)
Move on to the next node in the tree that is connected to the given outcome.static Action.ActionBuilder
send(List<? extends Callback> callbacks)
Send the given callbacks to the user for them to interact with.static Action.ActionBuilder
send(Callback... callbacks)
Send the given callbacks to the user for them to interact with.boolean
sendingCallbacks()
Returns true if the action is a request for input.static Action.ActionBuilder
suspend(SuspensionHandler suspensionHandler)
Suspend the current authentication request, and allow the end-user to resume it later by clicking on a link for example.
-
-
-
Field Detail
-
HEADER
public static final String HEADER
Key for the header return property.- See Also:
- Constant Field Values
-
DESCRIPTION
public static final String DESCRIPTION
Key for the description return property.- See Also:
- Constant Field Values
-
STAGE
public static final String STAGE
Key for the stage return property.- See Also:
- Constant Field Values
-
sharedState
public final JsonValue sharedState
The output state of the node.
-
transientState
public final JsonValue transientState
The transient state of the node.
-
outcome
public final String outcome
Result of the node. May be null.
-
returnProperties
public final Map<String,Object> returnProperties
Properties to return to the client.
-
errorMessage
public final String errorMessage
The error message to present to the caller when the FAILURE node is reached.
-
lockoutMessage
public final String lockoutMessage
The error message to present to the caller when the user is locked out.
-
callbacks
public final List<Callback> callbacks
Callbacks requested by the node when the outcome is null. May be null.
-
sessionProperties
public final Map<String,String> sessionProperties
Properties that will be included in the user's session if/when it is created.
-
sessionHooks
public final List<JsonValue> sessionHooks
List of classes implementingTreeHook
that run after successful login.
-
suspensionHandler
public final SuspensionHandler suspensionHandler
TheSuspensionHandler
to call when the authentication process is suspended by the authentication framework.
-
universalId
@Deprecated public final Optional<String> universalId
Deprecated.useidentifiedIdentity
instead.The universal id of the identity object.
-
identifiedIdentity
public final Optional<org.forgerock.openam.auth.node.api.IdentifiedIdentity> identifiedIdentity
Optionally the identity confirmed to exist as part of this action.
-
-
Method Detail
-
goTo
public static Action.ActionBuilder goTo(String outcome)
Move on to the next node in the tree that is connected to the given outcome.- Parameters:
outcome
- the outcome.- Returns:
- an action builder to provide additional details.
-
send
public static Action.ActionBuilder send(List<? extends Callback> callbacks)
Send the given callbacks to the user for them to interact with.- Parameters:
callbacks
- a non-empty list of callbacks.- Returns:
- an action builder to provide additional details.
-
send
public static Action.ActionBuilder send(Callback... callbacks)
Send the given callbacks to the user for them to interact with.- Parameters:
callbacks
- a non-empty list of callbacks.- Returns:
- an action builder to provide additional details.
-
suspend
public static Action.ActionBuilder suspend(SuspensionHandler suspensionHandler)
Suspend the current authentication request, and allow the end-user to resume it later by clicking on a link for example.- Parameters:
suspensionHandler
- TheSuspensionHandler
to use for sending the suspension ID to the end-users.- Returns:
- An action builder that suspends the current authentication flow.
-
sendingCallbacks
public boolean sendingCallbacks()
Returns true if the action is a request for input.- Returns:
- true if the action need to request for input, false otherwise.
-
-