@proto-kit/sequencer β€’ Docs


Documentation / @proto-kit/sequencer / UntypedStateTransition

Class: UntypedStateTransition

Generic state transition that constraints the current method circuit to external state, by providing a state anchor.

Constructors

new UntypedStateTransition()

new UntypedStateTransition(path, fromValue, toValue): UntypedStateTransition

Parameters

β€’ path: Field

β€’ fromValue: UntypedOption

β€’ toValue: UntypedOption

Returns

UntypedStateTransition

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:35

Properties

fromValue

fromValue: UntypedOption

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:37


path

path: Field

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:36


toValue

toValue: UntypedOption

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:38

Accessors

from

Get Signature

get from(): UntypedOption

Returns

UntypedOption

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:41


to

Get Signature

get to(): UntypedOption

Returns

UntypedOption

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:47

Methods

toJSON()

toJSON(): object

Returns

object

from

from: object

from.isForcedSome

from.isForcedSome: boolean

from.isSome

from.isSome: boolean

from.value

from.value: string[]

path

path: string

to

to: object

to.isForcedSome

to.isForcedSome: boolean

to.isSome

to.isSome: boolean

to.value

to.value: string[]

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:63


toProvable()

toProvable(): ProvableStateTransition

Converts a StateTransition to a ProvableStateTransition, while enforcing the β€˜from’ property to be β€˜Some’ in all cases.

Returns

ProvableStateTransition

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:55


fromJSON()

static fromJSON(__namedParameters): UntypedStateTransition

Parameters

β€’ __namedParameters

β€’ __namedParameters.from

β€’ __namedParameters.from.isForcedSome: boolean

β€’ __namedParameters.from.isSome: boolean

β€’ __namedParameters.from.value: string[]

β€’ __namedParameters.path: string

β€’ __namedParameters.to

β€’ __namedParameters.to.isForcedSome: boolean

β€’ __namedParameters.to.isSome: boolean

β€’ __namedParameters.to.value: string[]

Returns

UntypedStateTransition

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:19


fromStateTransition()

static fromStateTransition<Value>(st): UntypedStateTransition

Type Parameters

β€’ Value

Parameters

β€’ st: StateTransition<Value>

Returns

UntypedStateTransition

Defined in

packages/sequencer/src/protocol/production/helpers/UntypedStateTransition.ts:11