QuantLib: a free/open-source library for quantitative finance
Fully annotated sources - version 1.32
Loading...
Searching...
No Matches
bermudanswaptionexercisevalue.hpp
1/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2
3/*
4 Copyright (C) 2006 Mark Joshi
5
6 This file is part of QuantLib, a free-software/open-source library
7 for financial quantitative analysts and developers - http://quantlib.org/
8
9 QuantLib is free software: you can redistribute it and/or modify it
10 under the terms of the QuantLib license. You should have received a
11 copy of the license along with this program; if not, please email
12 <quantlib-dev@lists.sf.net>. The license is also available online at
13 <http://quantlib.org/license.shtml>.
14
15 This program is distributed in the hope that it will be useful, but WITHOUT
16 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
17 FOR A PARTICULAR PURPOSE. See the license for more details.
18*/
19
20
21#ifndef quantlib_bermudan_swaption_exercise_value_hpp
22#define quantlib_bermudan_swaption_exercise_value_hpp
23
24#include <ql/models/marketmodels/callability/exercisevalue.hpp>
25#include <ql/models/marketmodels/evolutiondescription.hpp>
26#include <ql/shared_ptr.hpp>
27#include <valarray>
28
29namespace QuantLib {
30
31 class Payoff;
32
34 public:
35 BermudanSwaptionExerciseValue(const std::vector<Time>& rateTimes,
36 std::vector<ext::shared_ptr<Payoff> >);
37 Size numberOfExercises() const override;
38 // including any time at which state should be updated
39 const EvolutionDescription& evolution() const override;
40 std::vector<Time> possibleCashFlowTimes() const override;
41 void nextStep(const CurveState&) override;
42 void reset() override;
43 // whether or not evolution times are exercise times
44 std::valarray<bool> isExerciseTime() const override;
46 std::unique_ptr<MarketModelExerciseValue> clone() const override;
47 private:
49 std::vector<Time> rateTimes_;
50 std::vector<ext::shared_ptr<Payoff> > payoffs_;
52 // evolving
55 };
56
57}
58
59
60#endif
MarketModelMultiProduct::CashFlow value(const CurveState &) const override
std::valarray< bool > isExerciseTime() const override
std::vector< ext::shared_ptr< Payoff > > payoffs_
std::unique_ptr< MarketModelExerciseValue > clone() const override
std::vector< Time > possibleCashFlowTimes() const override
const EvolutionDescription & evolution() const override
Curve state for market-model simulations
Definition: curvestate.hpp:41
Market-model evolution description.
std::size_t Size
size of a container
Definition: types.hpp:58
Definition: any.hpp:35