Class MarketModelNodeDataProvider
The data a market-model callable product's exercise decision reads at each exercise: stepped along a path at its evolution's times, it fills the current exercise's values.
[WorkingType]
public abstract class MarketModelNodeDataProvider
- Inheritance
-
MarketModelNodeDataProvider
- Derived
- Inherited Members
Remarks
A working type and an extension point: Reset() and NextStep(CurveState) change it, and it isn't thread-safe. Values(CurveState, Span<double>) fills a span of the current exercise's count of data, which QuantLib's resizes its caller's vector to.
Constructors
MarketModelNodeDataProvider()
protected MarketModelNodeDataProvider()
Properties
Evolution
Gets the evolution: its rate times and the times it is stepped at, its exercise times included.
public abstract EvolutionDescription Evolution { get; }
Property Value
NumberOfExercises
Gets the number of exercises.
public abstract int NumberOfExercises { get; }
Property Value
Methods
IsExerciseTime()
Whether each evolution time is an exercise time.
public abstract ImmutableArray<bool> IsExerciseTime()
Returns
- ImmutableArray<bool>
One flag an evolution time.
NextStep(CurveState)
Moves to the next evolution time, in the given state.
public abstract void NextStep(CurveState currentState)
Parameters
currentStateCurveStateThe state.
NumberOfData()
The number of data at each exercise, possibly different for each.
public abstract ImmutableArray<int> NumberOfData()
Returns
- ImmutableArray<int>
One count an exercise.
Reset()
Puts the provider at the start of a path.
public abstract void Reset()
Values(CurveState, Span<double>)
Writes the current exercise's data in the given state.
public abstract void Values(CurveState currentState, Span<double> results)
Parameters
currentStateCurveStateThe state.
resultsSpan<double>The data written, the current exercise's count of them.