OnixS C++ Eurex T7 Market and Reference Data Interface (EMDI, RDI, EOBI) Handlers  7.2.2
API documentation
TopOfBookImplied.h
Go to the documentation of this file.
1 /*
2 * Copyright Onix Solutions Limited [OnixS]. All rights reserved.
3 *
4 * This software owned by Onix Solutions Limited [OnixS] and is protected by copyright law
5 * and international copyright treaties.
6 *
7 * Access to and use of the software is governed by the terms of the applicable OnixS Software
8 * Services Agreement (the Agreement) and Customer end user license agreements granting
9 * a non-assignable, non-transferable and non-exclusive license to use the software
10 * for it's own data processing purposes under the terms defined in the Agreement.
11 *
12 * Except as otherwise granted within the terms of the Agreement, copying or reproduction of any part
13 * of this source code or associated reference material to any other location for further reproduction
14 * or redistribution, and any amendments to this copyright notice, are expressly prohibited.
15 *
16 * Any reproduction or redistribution for sale or hiring of the Software not in accordance with
17 * the terms of the Agreement is a violation of copyright law.
18 */
19 
20 #pragma once
21 
27 
28 namespace OnixS
29 {
30  namespace Eurex
31  {
32  namespace MarketData
33  {
34  /// Market data snapshot entry.
35  class ONIXS_EUREX_EMDI_API TopOfBookImpliedEntry : GroupInstance
36  {
37  public:
38  /// Update action.
40  {
41  return getIntEnumFieldValue<MDUpdateAction> (*this, Tags::MDUpdateAction);
42  }
43 
44  /// Defines the entry type.
46  {
47  return getIntEnumFieldValue<MDEntryType> (*this, Tags::MDEntryType);
48  }
49 
50  /// Always Top of Book.
52  {
53  return getIntEnumFieldValue<BookType> (*this, Tags::MDBookType);
54  }
55 
56  /// Price / Quantity pairs.
58  {
59  return getIntEnumFieldValue<SubBookType> (*this, Tags::MDSubBookType);
60  }
61 
62  /// Instrument identifier.
64  {
65  return getInt64 (Tags::SecurityID);
66  }
67 
68  /// Price.
69  bool mdEntryPx (Decimal& price) const
70  {
71  return get (Tags::MDEntryPx).toNumber (price);
72  }
73 
74  /// Quantity.
75  bool mdEntrySize (Decimal& size) const
76  {
77  return get (Tags::MDEntrySize).toNumber (size);
78  }
79 
80  /// For bids and offers the official time of book entry, for trades official time of execution (all in nanoseconds).
81  bool mdEntryTime (UInt64& time) const
82  {
83  return get (Tags::MDEntryTime).toNumber (time);
84  }
85 
86  /// Quote Condition.
87  bool quoteCondition (UInt32& value) const
88  {
89  return get (Tags::QuoteCondition).toNumber (value);
90  }
91 
92  private:
94 
95  TopOfBookImpliedEntry (const GroupInstance& groupInstance)
96  : GroupInstance (groupInstance)
97  {
98  }
99  };
100 
101  class TopOfBookImpliedEntries : public TypedGroup<TopOfBookImpliedEntry>
102  {
103  private:
104  explicit
105  TopOfBookImpliedEntries (const Group& group)
107  {
108  }
109 
110  friend class TopOfBookImplied;
111  };
112 
113  /// Depth incremental
114  class ONIXS_EUREX_EMDI_API TopOfBookImplied : public Message
115  {
116  public:
117 
118  /// Product identifier.
120  {
121  return getUInt32 (Tags::MarketSegmentID);
122  }
123 
124  /// Entries.
126  {
127  return TopOfBookImpliedEntries ( getGroup (Tags::NoMDEntries) );
128  }
129 
130  private:
132 
133  TopOfBookImplied (const void* impl)
134  : Message (impl)
135  {
136  }
137  };
138  }
139  }
140 }
bool mdEntryTime(UInt64 &time) const
For bids and offers the official time of book entry, for trades official time of execution (all in na...
MarketSegmentId marketSegmentId() const
Product identifier.
SubBookType::Enum mdSubBookType() const
Price / Quantity pairs.
TopOfBookImpliedEntries mdEntries() const
Entries.
MDEntryType::Enum mdEntryType() const
Defines the entry type.
unsigned int UInt32
Definition: Numeric.h:41
Definition: Defines.h:30
Decimal type for better precision.
Definition: Numeric.h:63
bool mdEntrySize(Decimal &size) const
Quantity.
Int64 SecurityId
Alias for Security Id type.
Definition: Defines.h:51
bool quoteCondition(UInt32 &value) const
Quote Condition.
MDUpdateAction::Enum mdUpdateAction() const
Update action.
SecurityId securityId() const
Instrument identifier.
UInt32 MarketSegmentId
Alias for Market Segment ID type.
Definition: Defines.h:40
bool mdEntryPx(Decimal &price) const
Price.
BookType::Enum mdBookType() const
Always Top of Book.