Struct NoCurve
pub struct NoCurve;Expand description
No projection curve at all — a leg of fixed coupons, or one whose every reset has already fixed.
Trait Implementations§
impl Copy for NoCurve
§impl<R: Scalar> CurveByIndex<R> for NoCurve
impl<R: Scalar> CurveByIndex<R> for NoCurve
§fn curve(&self, _index: &str) -> Option<&dyn YieldCurve<R>>
fn curve(&self, _index: &str) -> Option<&dyn YieldCurve<R>>
The curve a coupon naming
index projects off, or None where this
source holds no curve for it. Read more§fn curve_of(&self, index: Option<&str>) -> Option<&dyn YieldCurve<R>>
fn curve_of(&self, index: Option<&str>) -> Option<&dyn YieldCurve<R>>
curve for a coupon’s own index, which a fixed coupon
does not have.§fn distinguishes_indices(&self) -> bool
fn distinguishes_indices(&self) -> bool
Whether two different indices can be answered with two different
curves. A source holding one curve for every index cannot, and a stub
that interpolates between two tenors must not be valued through it:
it would blend one curve with itself.
§fn cms_rate(
&self,
_coupon: &CmsCoupon,
_as_of: NaiveDate,
) -> Option<Result<R, CashflowError>>
fn cms_rate( &self, _coupon: &CmsCoupon, _as_of: NaiveDate, ) -> Option<Result<R, CashflowError>>
What a CMS coupon still to fix pays as a rate — the CMS rate its
swap index fixes, convexity-adjusted off the swaption smile, geared,
spread and with its payoff — or
None where this source cannot
replicate it: a curve source holds no discount curve and no swaption
vols, and the coupon is then refused by name.§fn cap_vol(&self, _currency: Currency) -> Option<&RateSmileView<'_, R>>
fn cap_vol(&self, _currency: Currency) -> Option<&RateSmileView<'_, R>>
The cap vol surface a capped or floored coupon in
currency values
its options off, or None where this source holds none — a curve
source is not a vol source, and a coupon’s option still to fix is then
refused by name rather than valued at its forward.§fn yoy_vol(&self, _index: &str) -> Option<&InflationVolView<'_, R>>
fn yoy_vol(&self, _index: &str) -> Option<&InflationVolView<'_, R>>
The year-on-year optionlet vol surface a capped, floored or digital
YoY inflation coupon on
index values its options off, or None
where this source holds none — and the option still to fix is then
refused by name.§fn cpi_vol(&self, _index: &str) -> Option<&InflationVolView<'_, R>>
fn cpi_vol(&self, _index: &str) -> Option<&InflationVolView<'_, R>>
The zero-coupon CPI option vol surface a collared CPI notional on
index values its options off, or None where this source holds none
— and the option still to fix is then refused by name.§fn index_level(
&self,
_index: &str,
_lag_months: u32,
_date: NaiveDate,
) -> Result<Option<R>, CashflowError>
fn index_level( &self, _index: &str, _lag_months: u32, _date: NaiveDate, ) -> Result<Option<R>, CashflowError>
The level of price index
index a flow on date is scaled by, under
the index’s lag and interpolation, or None where this source holds no
inflation for it — a curve source is not an index source, and a CPI
coupon is then refused by name. Read moreAuto Trait Implementations§
impl Freeze for NoCurve
impl RefUnwindSafe for NoCurve
impl Send for NoCurve
impl Sync for NoCurve
impl Unpin for NoCurve
impl UnsafeUnpin for NoCurve
impl UnwindSafe for NoCurve
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more