public class TransitionFieldChoiceDefinition<E extends FieldChoiceDefinition<E>> extends FieldChoiceDefinition<E>
Constructor and Description |
---|
TransitionFieldChoiceDefinition(int storagesize,
boolean allowalltransitions)
creates a new TransitionFieldChoiceDefinition
|
Modifier and Type | Method and Description |
---|---|
protected void |
defineFinalTransitionChoice(ChoiceValue<E> finalchoice)
defines what is the final choice
|
protected void |
DefineTransition(ChoiceValue<E> startvalue,
ChoiceValue<E> endvalue)
Defines a valid transition
|
protected void |
finalizeTransitions()
copies the transitions authorized in each ChoiceValue
|
ChoiceValue<E> |
getDefaultFinalChoice() |
ChoiceValue<E> |
getDefaultWorkingChoice() |
boolean |
isChoiceFinal(ChoiceValue<E> choice) |
boolean |
IsFinalTransitionDefined() |
boolean |
isTransitionValid(ChoiceValue<E> startvalue,
ChoiceValue<E> endvalue)
allows to check if a transition is valid or not
|
ChoiceValue<E> |
parseValueFromStorageCode(java.lang.String valueasstored) |
void |
setDefaultFinalChoice(ChoiceValue<E> choicevalue) |
void |
setDefaultWorkingChoice(ChoiceValue<E> choicevalue) |
addChoiceValue, addChoiceValueasDefault, decode, getChoiceValue, getDefaultChoice, getStorageSize, lookUpByDisplayValue, parseChoiceValue, parseMultipleChoiceElt, setDefaultAsNull, setDefaultChoice, showDisplay, toString
public TransitionFieldChoiceDefinition(int storagesize, boolean allowalltransitions)
storagesize
- persistence storage size for the code of one valueallowalltransitions
- true if all transitions are allowed, false if
transitions will be specifiedprotected void finalizeTransitions()
protected void defineFinalTransitionChoice(ChoiceValue<E> finalchoice)
finalchoice
- the choice to be defined as finalpublic ChoiceValue<E> getDefaultWorkingChoice()
public ChoiceValue<E> getDefaultFinalChoice()
public void setDefaultWorkingChoice(ChoiceValue<E> choicevalue)
choicevalue
- defines the default working choice. This is used in simple
workflows when someone agreed to work on the itempublic void setDefaultFinalChoice(ChoiceValue<E> choicevalue)
choicevalue
- defines the final choicepublic boolean IsFinalTransitionDefined()
public boolean isChoiceFinal(ChoiceValue<E> choice)
choice
- a choice that is part of this fieldchoicedefinitionprotected void DefineTransition(ChoiceValue<E> startvalue, ChoiceValue<E> endvalue)
startvalue
- the start value of the authorized transitionendvalue
- the end value of the authorized transitionpublic boolean isTransitionValid(ChoiceValue<E> startvalue, ChoiceValue<E> endvalue)
startvalue
- start valueendvalue
- end valuepublic ChoiceValue<E> parseValueFromStorageCode(java.lang.String valueasstored)
valueasstored
-