OpenMAMA
MamdaOptionContractSet.h
Go to the documentation of this file.
1 /* $Id$
2  *
3  * OpenMAMA: The open middleware agnostic messaging API
4  * Copyright (C) 2011 NYSE Technologies, Inc.
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
19  * 02110-1301 USA
20  */
21 
22 #ifndef MamdaOptionContractSetH
23 #define MamdaOptionContractSetH
24 
26 #include <map>
27 #include <string.h>
28 
29 namespace Wombat
30 {
31 
32  class MamdaOptionContract;
33 
35  {
36  bool operator()(const char* str1, const char* str2) const
37  {
38  return strcmp(str1,str2) < 0;
39  }
40  };
41 
46  class MAMDAOPTExpDLL MamdaOptionContractSet
47  : public std::map <const char*, MamdaOptionContract*, char_str_less_than>
48  {
49  public:
50 
52 
54 
58  void setBboContract (MamdaOptionContract* contract);
59 
64  void setWombatBboContract (MamdaOptionContract* contract);
65 
69  void setExchangeContract (const char* exchange,
70  MamdaOptionContract* contract);
71 
75  MamdaOptionContract* getBboContract () const;
76 
81  MamdaOptionContract* getWombatBboContract () const;
82 
86  MamdaOptionContract* getExchangeContract (const char* exchange) const;
87 
88  private:
89  MamdaOptionContract* mBboContract;
90  MamdaOptionContract* mWombatBboContract;
91  };
92 
93 } // namespace
94 
95 #endif // MamdaOptionContractSetH
MamdaOrderImbalanceUpdate is an interface that provides access to order imbalance related fields...
Definition: MamdaAuctionFields.h:29
bool operator()(const char *str1, const char *str2) const
Definition: MamdaOptionContractSet.h:36
A class that represents a single option contract.
Definition: MamdaOptionContract.h:60
A class that represents a set of option contracts at a given strike price.
Definition: MamdaOptionContractSet.h:46
Definition: MamdaOptionContractSet.h:34


© 2012 Linux Foundation