State
Constructor
Signature
constructor (
name,
exitGuarded,
enterGuarded,
transitions,
guardLogic
)
Parameters
Name | Description | Type |
name | name of state. begin with letter, no spaces, a-z, A-Z, 0-9, and _ | string |
exitGuarded | is there an exit guard? | boolean |
enterGuarded | is there an enter guard? | boolean |
transitions | all of the valid Transitions from this state | FismoTypes.Transition[] |
guardLogic | address of guard logic contract | string |
Static Members
Methods
🦠fromObject
Get a new State
instance from an object representation.
Signature
Parameters
Name | Description | Type |
o | the plain object | object |
Returns
Description | Type |
the instance | State |
🦠fromStruct
Get a new State
instance from a struct representation.
Signature
Parameters
Name | Description | Type |
struct | the struct | Array |
Returns
Description | Type |
the instance | State |
Instance Members
Properties
- name
- id
- enterGuarded
- exitGuarded
- transitions
- guardLogic
Methods
🦠toObject
Get a plain object representation of this State
instance.
Signature
Returns
Description | Type |
the plain object | object |
🦠toString
Get a string representation of this State
instance.
Signature
Returns
Description | Type |
the JSON representation | string |
🦠toStruct
Get a struct representation of this State
instance.
Signature
Returns
Description | Type |
the struct | Array |
🦠clone
Clone this State
instance.
Signature
Returns
Description | Type |
the cloned instance | State |
🦠isValid
Is this State
instance valid?
Signature
Returns
Description | Type |
true if the instance is valid | boolean |