Interface IScenarioHistory
An append-only sequence of IScenario snapshots. Provides
pull-based lookup (Scenario(ITimeStamp)) and a push-based observable
(NewScenarios) for late subscribers — the latter is a hot
Subject<IScenario> with no replay buffer.
public interface IScenarioHistory : IEnumerable<IScenario>, IEnumerable
- Inherited Members
Remarks
The hot, no-replay choice means consumers that subscribe after history has
been appended will not receive past scenarios — they only see future
emissions, matching the semantics of the existing
NatsObservable in Virtufin.Data.
Properties
Iter
Iterate scenarios in insertion order.
IEnumerable<IScenario> Iter { get; }
Property Value
LastScenario
The most recently appended scenario.
IScenario LastScenario { get; }
Property Value
NewScenarios
Hot observable of newly-appended scenarios. Late subscribers see no
history. Use the existing Subject<T> Unsubscribe pattern
for proper disposal (see AGENTS.md).
IObservable<IScenario> NewScenarios { get; }
Property Value
Methods
Scenario(ITimeStamp)
Look up the first scenario matching timeStamp.
Returns null if no scenario matches.
IScenario? Scenario(ITimeStamp timeStamp)
Parameters
timeStampITimeStampTime-point to search for.