Attributes | Name and Description |
---|---|
|
caplin.trading.statemachine.Transition(caplin.trading.statemachine.State oTarget, String sEvent, String sSource)
Constructs a caplin.trading.statemachine.Transition |
Attributes | Name and Description |
---|---|
|
void
addValidator(caplin.trading.validation.Validator oValidator)
Adds a validator that must pass for this transition to be allowed. |
|
String
getEvent()
Gets the name of the event that triggers this transition. |
|
String
getSource()
Returns the source of the event. |
|
caplin.trading.statemachine.State
getTarget()
Gets the target |
|
caplin.trading.validation.ValidationResult
validate(Object oContext)
Tests to see if all of the validators for this Transition pass. |
►
caplin.trading.statemachine.Transition(caplin.trading.statemachine.State oTarget, String sEvent, String sSource)
Constructs a caplin.trading.statemachine.Transition
caplin.trading.statemachine.State | oTarget | The state that this transition goes to. This may not be null. |
String | sEvent | The name of the event that triggers this transition. May not be null. |
String | sSource | The source of the event, either server or client. |
caplin.trading.statemachine.State
or if the event name is not a String
.
►
void
addValidator(caplin.trading.validation.Validator oValidator)
Adds a validator that must pass for this transition to be allowed.
caplin.trading.validation.Validator | oValidator | A validator that must pass to allow this transition. |
►
String
getEvent()
Gets the name of the event that triggers this transition.
►
String
getSource()
Returns the source of the event.
►
caplin.trading.statemachine.State
getTarget()
Gets the target State
.
►
caplin.trading.validation.ValidationResult
validate(Object oContext)
Tests to see if all of the validators for this Transition pass. A caplin.trading.statemachine.StateMachine should not change state if this method does not return a successful caplin.trading.validation.ValidationResult.
Object | oContext | The data for the validators to check. It is not optional and may not be null. |