public static final class ChoiceState.Builder extends Object implements State.Builder, InputOutputPathBuilder<ChoiceState.Builder>
ChoiceState
.Buildable.Utils
Modifier and Type | Method and Description |
---|---|
ChoiceState |
build() |
ChoiceState.Builder |
choice(Choice.Builder choiceBuilder)
REQUIRED.
|
ChoiceState.Builder |
choices(Choice.Builder... choiceBuilders)
REQUIRED.
|
ChoiceState.Builder |
comment(String comment)
OPTIONAL.
|
ChoiceState.Builder |
defaultStateName(String defaultStateName)
OPTIONAL.
|
ChoiceState.Builder |
inputPath(String inputPath)
OPTIONAL.
|
ChoiceState.Builder |
outputPath(String outputPath)
OPTIONAL.
|
public ChoiceState.Builder comment(String comment)
comment
- New comment.public ChoiceState.Builder defaultStateName(String defaultStateName)
Choice
rules match. If a default state is not provided and no
choices match then a ErrorCodes.NO_CHOICE_MATCHED
error is thrown.defaultStateName
- Name of default state.public ChoiceState.Builder choice(Choice.Builder choiceBuilder)
Choice
rule to the ChoiceState
. A ChoiceState
must contain at least one
choice rule.choiceBuilder
- Instance of Choice.Builder
. Note that
the Choice
object is not built until the ChoiceState
is built so any modifications on the
state builder will be reflected in this object.public ChoiceState.Builder choices(Choice.Builder... choiceBuilders)
Choice
rules to the ChoiceState
. A ChoiceState
must contain at least one
choice rule.choiceBuilders
- Instances of Choice.Builder
. Note
that the Choice
object is not built until the ChoiceState
is built so any modifications on the
state builder will be reflected in this object.public ChoiceState.Builder inputPath(String inputPath)
InputOutputPathBuilder
inputPath
in interface InputOutputPathBuilder<ChoiceState.Builder>
inputPath
- New path value.public ChoiceState.Builder outputPath(String outputPath)
InputOutputPathBuilder
outputPath
in interface InputOutputPathBuilder<ChoiceState.Builder>
outputPath
- New path value.public ChoiceState build()
build
in interface Buildable<State>
ChoiceState
object.