swap.hpp
Go to the documentation of this file.
1 
2 /*
3  Copyright (C) 2005 Eric Ehlers
4  Copyright (C) 2006, 2007, 2010, 2011 Ferdinando Ametrano
5  Copyright (C) 2005 Aurelien Chanudet
6  Copyright (C) 2005, 2008 Plamen Neykov
7  Copyright (C) 2006 Katiuscia Manzoni
8 
9  This file is part of QuantLib, a free-software/open-source library
10  for financial quantitative analysts and developers - http://quantlib.org/
11 
12  QuantLib is free software: you can redistribute it and/or modify it
13  under the terms of the QuantLib license. You should have received a
14  copy of the license along with this program; if not, please email
15  <quantlib-dev@lists.sf.net>. The license is also available online at
16  <http://quantlib.org/license.shtml>.
17 
18  This program is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
20  FOR A PARTICULAR PURPOSE. See the license for more details.
21 */
22 
23 #ifndef qla_swap_hpp
24 #define qla_swap_hpp
25 
26 #include <qlo/baseinstruments.hpp>
27 #include <qlo/couponvectors.hpp>
28 
29 namespace QuantLib {
30  class CmsCouponPricer;
31 }
32 
33 namespace QuantLibAddin {
34 
35  class Swap : public Instrument {
36  public:
37  // obsolete constructor to be removed
38  Swap(const boost::shared_ptr<ObjectHandler::ValueObject>& properties,
39  const std::vector<boost::shared_ptr<Leg> >& legPtrs,
40  const std::vector<bool>& payer,
41  bool permanent);
42  // new constructor
43  Swap(const boost::shared_ptr<ObjectHandler::ValueObject>& properties,
44  const std::vector<QuantLib::Leg>& legs,
45  const std::vector<bool>& payer,
46  bool permanent);
47  // MakeCms
48  Swap(const boost::shared_ptr<ObjectHandler::ValueObject>& properties,
49  const QuantLib::Period& swapTenor,
50  const boost::shared_ptr<QuantLib::SwapIndex>& swapIndex,
51  const boost::shared_ptr<QuantLib::IborIndex>& iborIndex,
52  QuantLib::Spread iborSpread,
53  const QuantLib::Period& forwardStart,
54  const boost::shared_ptr<QuantLib::CmsCouponPricer>& pricer,
55  bool permanent);
56 
57  std::vector<std::vector<ObjectHandler::property_t> > legAnalysis(
58  QuantLib::Size i,
59  const QuantLib::Date& d);
60 
61  protected:
63  };
64 
65 }
66 
67 #endif
OH_OBJ_CTOR(Swap, Instrument)
Definition: baseinstruments.hpp:34
Definition: abcd.hpp:38
Definition: abcd.hpp:30
std::vector< std::vector< ObjectHandler::property_t > > legAnalysis(QuantLib::Size i, const QuantLib::Date &d)
Definition: swap.hpp:35
Swap(const boost::shared_ptr< ObjectHandler::ValueObject > &properties, const std::vector< boost::shared_ptr< Leg > > &legPtrs, const std::vector< bool > &payer, bool permanent)