Class PersistentFSM.State<TS, TD, TE>
Inherited Members
Namespace: Akka.Persistence.Fsm
Assembly: Akka.Persistence.dll
Syntax
public class PersistentFSM.State<TS, TD, TE>
Type Parameters
| Name | Description |
|---|---|
| TS | |
| TD | |
| TE |
Constructors
| Edit this page View SourceState(TS, TD, TimeSpan?, Reason, IReadOnlyList<object>, IReadOnlyList<TE>, Action<TD>, bool)
Initializes a new instance of the PersistentFSM.State<TS, TD, TE>
Declaration
public State(TS stateName, TD stateData, TimeSpan? timeout = null, FSMBase.Reason stopReason = null, IReadOnlyList<object> replies = null, IReadOnlyList<TE> domainEvents = null, Action<TD> afterTransitionDo = null, bool notifies = true)
Parameters
| Type | Name | Description |
|---|---|---|
| TS | stateName | TBD |
| TD | stateData | TBD |
| TimeSpan? | timeout | TBD |
| FSMBase.Reason | stopReason | TBD |
| IReadOnlyList<object> | replies | TBD |
| IReadOnlyList<TE> | domainEvents | TBD |
| Action<TD> | afterTransitionDo | |
| bool | notifies | TBD |
Properties
| Edit this page View SourceAfterTransitionDo
TBD
Declaration
public Action<TD> AfterTransitionDo { get; }
Property Value
| Type | Description |
|---|---|
| Action<TD> |
DomainEvents
TBD
Declaration
public IReadOnlyList<TE> DomainEvents { get; }
Property Value
| Type | Description |
|---|---|
| IReadOnlyList<TE> |
Replies
TBD
Declaration
public IReadOnlyList<object> Replies { get; protected set; }
Property Value
| Type | Description |
|---|---|
| IReadOnlyList<object> |
StateData
TBD
Declaration
public TD StateData { get; }
Property Value
| Type | Description |
|---|---|
| TD |
StateName
TBD
Declaration
public TS StateName { get; }
Property Value
| Type | Description |
|---|---|
| TS |
StopReason
TBD
Declaration
public FSMBase.Reason StopReason { get; }
Property Value
| Type | Description |
|---|---|
| FSMBase.Reason |
Timeout
TBD
Declaration
public TimeSpan? Timeout { get; }
Property Value
| Type | Description |
|---|---|
| TimeSpan? |
Methods
| Edit this page View SourceAndThen(Action<TD>)
Register a handler to be triggered after the state has been persisted successfully
Declaration
public PersistentFSM.State<TS, TD, TE> AndThen(Action<TD> handler)
Parameters
| Type | Name | Description |
|---|---|---|
| Action<TD> | handler | TBD |
Returns
| Type | Description |
|---|---|
| PersistentFSM.State<TS, TD, TE> | TBD |
Applying(params TE[])
Specify domain events to be applied when transitioning to the new state.
Declaration
public PersistentFSM.State<TS, TD, TE> Applying(params TE[] events)
Parameters
| Type | Name | Description |
|---|---|---|
| TE[] | events | TBD |
Returns
| Type | Description |
|---|---|
| PersistentFSM.State<TS, TD, TE> | TBD |
ForMax(TimeSpan)
Modify the state transition descriptor to include a state timeout for the
next state. This timeout overrides any default timeout set for the next state.
Declaration
public PersistentFSM.State<TS, TD, TE> ForMax(TimeSpan timeout)
Parameters
| Type | Name | Description |
|---|---|---|
| TimeSpan | timeout | TBD |
Returns
| Type | Description |
|---|---|
| PersistentFSM.State<TS, TD, TE> | TBD |
Replying(object)
Send reply to sender of the current message, if available.
Declaration
public PersistentFSM.State<TS, TD, TE> Replying(object replyValue)
Parameters
| Type | Name | Description |
|---|---|---|
| object | replyValue | TBD |
Returns
| Type | Description |
|---|---|
| PersistentFSM.State<TS, TD, TE> | TBD |
ToString()
TBD
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string | TBD |
Overrides
| Edit this page View SourceUsing(TD)
Modify state transition descriptor with new state data. The data will be set when transitioning to the new state.
Declaration
[Obsolete("Internal API easily to be confused with regular FSM's using. Use regular events (`Applying`). Internally, `copy` can be used instead.")]
public PersistentFSM.State<TS, TD, TE> Using(TD nextStateData)
Parameters
| Type | Name | Description |
|---|---|---|
| TD | nextStateData | TBD |
Returns
| Type | Description |
|---|---|
| PersistentFSM.State<TS, TD, TE> | TBD |
Edit this page