Struct RunStateChange
A run-state transition, as OnRunStateChanged reports it.
public readonly struct RunStateChange : IEquatable<RunStateChange>
- Implements
- Inherited Members
Constructors
RunStateChange(RunState, RunState, long, ControlSource)
A run-state transition, as OnRunStateChanged reports it.
public RunStateChange(RunState Previous, RunState Current, long TickNumber, ControlSource Source)
Parameters
PreviousRunStateThe state before.
CurrentRunStateThe state after.
TickNumberlongThe number the next tick to run carries (CurrentTickNumber at the transition).
SourceControlSourceWho caused it.
Properties
Current
The state after.
public RunState Current { get; init; }
Property Value
Previous
The state before.
public RunState Previous { get; init; }
Property Value
Source
Who caused it.
public ControlSource Source { get; init; }
Property Value
TickNumber
The number the next tick to run carries (CurrentTickNumber at the transition).
public long TickNumber { get; init; }
Property Value
Methods
Deconstruct(out RunState, out RunState, out long, out ControlSource)
public void Deconstruct(out RunState Previous, out RunState Current, out long TickNumber, out ControlSource Source)
Parameters
PreviousRunStateCurrentRunStateTickNumberlongSourceControlSource
Equals(object)
public override bool Equals(object obj)
Parameters
objobject
Returns
Equals(RunStateChange)
public bool Equals(RunStateChange other)
Parameters
otherRunStateChange
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(RunStateChange, RunStateChange)
public static bool operator ==(RunStateChange left, RunStateChange right)
Parameters
leftRunStateChangerightRunStateChange
Returns
operator !=(RunStateChange, RunStateChange)
public static bool operator !=(RunStateChange left, RunStateChange right)
Parameters
leftRunStateChangerightRunStateChange