21#include <ql/exercise.hpp>
22#include <ql/shared_ptr.hpp>
27 Settlement::Type delivery, Settlement::Method settlementMethod)
28 : Option(ext::shared_ptr<
Payoff>(), exercise), swap_(swap), settlementType_(delivery),
29 settlementMethod_(settlementMethod) {
31 swap_->alwaysForwardNotifications();
37 swap_->setupArguments(args);
38 Option::setupArguments(args);
42 QL_REQUIRE(
arguments != 0,
"wrong argument type");
51 Option::fetchResults(r);
53 QL_ENSURE(
results != 0,
"wrong results type");
58 Option::results::reset();
63 Swap::arguments::validate();
64 QL_REQUIRE(swap,
"underlying swap not set");
65 QL_REQUIRE(exercise,
"exercise not set");
Arguments for swaption calculation
ext::shared_ptr< QuantLib::Swap > swap
QuantLib::Settlement::Type settlementType
QuantLib::Settlement::Method settlementMethod
void validate() const override
Results from CDS-option calculation
ext::shared_ptr< QuantLib::Swap > swap_
QuantLib::Settlement::Type settlementType_
void setupArguments(PricingEngine::arguments *) const override
Settlement::Type settlementType() const
bool isExpired() const override
QuantLib::Settlement::Method settlementMethod_
GenericSwaption(const ext::shared_ptr< QuantLib::Swap > &swap, const ext::shared_ptr< Exercise > &exercise, QuantLib::Settlement::Type delivery=QuantLib::Settlement::Physical, QuantLib::Settlement::Method settlementMethod=QuantLib::Settlement::PhysicalOTC)
void fetchResults(const PricingEngine::results *) const override
Settlement::Method settlementMethod() const