Class BondResults
- Namespace
- NanoQL.Instruments
- Assembly
- NanoQL.dll
The results an engine returns for a bond: the instrument's, and the settlement value.
public record BondResults : InstrumentResults, IEquatable<InstrumentResults>, IEquatable<BondResults>
- Inheritance
-
BondResults
- Implements
- Derived
- Inherited Members
Remarks
An extension point: the callable bond's results derive from it, as QuantLib's do. The clean and dirty prices and the theoretical yield, which QuantLib's bond computes on demand from the settlement value, are CleanPrice(BondResults, EvaluationContext), DirtyPrice(BondResults, EvaluationContext) and Yield(BondResults, DayCounter, Compounding, Frequency, EvaluationContext, double, int, double, BondPriceType).
Constructors
BondResults()
public BondResults()
BondResults(BondResults)
protected BondResults(BondResults original)
Parameters
originalBondResults
Properties
EqualityContract
protected override Type EqualityContract { get; }
Property Value
SettlementValue
Gets the value of the cash flows after the bond's settlement date, at that date; null where
QuantLib's engine leaves it unset and its settlementValue() throws "settlement value not provided".
public double? SettlementValue { get; init; }
Property Value
Methods
Equals(InstrumentResults?)
public override sealed bool Equals(InstrumentResults? other)
Parameters
otherInstrumentResults
Returns
Equals(BondResults?)
public virtual bool Equals(BondResults? other)
Parameters
otherBondResults
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
GetHashCode()
public override int GetHashCode()
Returns
PrintMembers(StringBuilder)
protected override bool PrintMembers(StringBuilder builder)
Parameters
builderStringBuilder
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(BondResults?, BondResults?)
public static bool operator ==(BondResults? left, BondResults? right)
Parameters
leftBondResultsrightBondResults
Returns
operator !=(BondResults?, BondResults?)
public static bool operator !=(BondResults? left, BondResults? right)
Parameters
leftBondResultsrightBondResults