26#ifndef quantlib_swap_hpp
27#define quantlib_swap_hpp
61 const Leg& secondLeg);
64 const std::vector<bool>&
payer);
79 const std::vector<Leg>&
legs()
const;
155 void reset()
override;
Base class for cash flows.
template base class for option pricing engines
Abstract instrument class.
void calculate() const override
template class providing a null value for a given type.
void validate() const override
std::vector< Real > payer
std::vector< Real > legBPS
DiscountFactor npvDateDiscount
std::vector< DiscountFactor > endDiscounts
std::vector< DiscountFactor > startDiscounts
std::vector< Real > legNPV
DiscountFactor endDiscounts(Size j) const
DiscountFactor npvDateDiscount_
const std::vector< Leg > & legs() const
void setupArguments(PricingEngine::arguments *) const override
Size numberOfLegs() const
bool isExpired() const override
returns whether the instrument might have value greater than zero.
Real legBPS(Size j) const
void deepUpdate() override
virtual Date startDate() const
std::vector< Real > legNPV_
const Leg & leg(Size j) const
DiscountFactor npvDateDiscount() const
std::vector< Real > legBPS_
virtual Date maturityDate() const
std::vector< DiscountFactor > startDiscounts_
Real legNPV(Size j) const
void setupExpired() const override
DiscountFactor startDiscounts(Size j) const
void fetchResults(const PricingEngine::results *) const override
std::vector< DiscountFactor > endDiscounts_
std::vector< Real > payer_
#define QL_REQUIRE(condition, message)
throw an error if the given pre-condition is not verified
Real DiscountFactor
discount factor between dates
std::size_t Size
size of a container
Abstract instrument class.
std::ostream & operator<<(std::ostream &out, GFunctionFactory::YieldCurveModel type)
std::vector< ext::shared_ptr< CashFlow > > Leg
Sequence of cash-flows.