Annotation Type FlowScoped
-
@NormalScope(passivating=true) @Inherited @Documented @Target(TYPE) @Retention(RUNTIME) public @interface FlowScoped
FlowScoped is a CDI scope that causes the runtime to consider classes with this annotation to be in the scope of the specified
Flow
. The implementation must provide an implementation ofjakarta.enterprise.inject.spi.Extension
that implements the semantics such that beans with this annotation are created lazily, when referenced, after the user enters into the specifiedFlow
, and made available for garbage collection when the user exits the specifiedFlow
. SeeFlowHandler.transition(jakarta.faces.context.FacesContext, jakarta.faces.flow.Flow, jakarta.faces.flow.Flow, jakarta.faces.flow.FlowCallNode, java.lang.String)
for the specification of flow entry and exit.When replacing (rather than decorating) the flow implementation with a custom
FlowHandler
implementation, it is necessary to also replace the CDI extension that implements the specified behavior regardingFlowScoped
beans.- Since:
- 2.2
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description String
value
Must be equivalent to theFlow.getId()
of a defined flow for this application.
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description String
definingDocumentId
-
-
-
Element Detail
-
value
String value
Must be equivalent to the
Flow.getId()
of a defined flow for this application.- Returns:
- the id of this flow
- Since:
- 2.2
-
-
-
definingDocumentId
String definingDocumentId
If not empty, declare the defining document id within which the
Flow
referenced byvalue()
is unique. If empty the, the runtime assumes that all flow ids are unique within the scope of the application.- Returns:
- the defining document id of this flow
- Since:
- 2.2
- Default:
- ""
-
-