OnixS ICE iMpact Multicast Price Feed Handler C++ library  8.18.0
API documentation
ExchangeListener.h
Go to the documentation of this file.
1 /**
2  * \file
3  * \brief Class `OnixS::ICE::iMpact::MarketData::ExchangeListener` (interface)
4  */
5 /*
6  * Copyright (c) Onix Solutions Limited. All rights reserved.
7  *
8  * This software owned by Onix Solutions Limited and is protected by copyright law
9  * and international copyright treaties.
10  *
11  * Access to and use of the software is governed by the terms of the applicable ONIXS Software
12  * Services Agreement (the Agreement) and Customer end user license agreements granting
13  * a non-assignable, non-transferable and non-exclusive license to use the software
14  * for it's own data processing purposes under the terms defined in the Agreement.
15  *
16  * Except as otherwise granted within the terms of the Agreement, copying or reproduction of any part
17  * of this source code or associated reference material to any other location for further reproduction
18  * or redistribution, and any amendments to this copyright notice, are expressly prohibited.
19  *
20  * Any reproduction or redistribution for sale or hiring of the Software not in accordance with
21  * the terms of the Agreement is a violation of copyright law.
22  */
23 
24 #pragma once
25 
26 #include "Export.h"
27 #include "MessageInfo.h"
28 #include "MessagesFwd.h"
29 
30 namespace OnixS { namespace ICE { namespace iMpact { namespace MarketData {
31 
32 /// \brief Defines an interface through which the Handler
33 /// notifies subscribers about all received messages.
34 class ONIXS_ICEMDH_EXPORT ExchangeListener
35 {
36 public:
37  virtual ~ExchangeListener() {}
38 
39  /// \name User callback's
40 
41  //@{
42 
43  /// \brief Implement this member to get notified about Add/Modify Order Message.
44  ///
45  /// Default implementation do nothing.
46  ///
47  /// \param msg is a \c AddModifyOrder message structure.
48  /// \param msgInfo information about this particular message.
49  virtual void onAddModifyOrder(const AddModifyOrder& msg, const MessageInfo& msgInfo);
50 
51  /// \brief Implement this member to get notified about Add Price Level Message.
52  ///
53  /// Default implementation do nothing.
54  ///
55  /// \param msg is a \c AddPriceLevel message structure.
56  /// \param msgInfo information about this particular message.
57  virtual void onAddPriceLevel(const AddPriceLevel& msg, const MessageInfo& msgInfo);
58 
59  /// \brief Implement this member to get notified about Message Bundle Marker.
60  ///
61  /// Default implementation do nothing.
62  ///
63  /// \param msg is a \c BundleMarker message structure.
64  /// \param msgInfo information about this particular message.
65  virtual void onBundleMarker(const BundleMarker& msg, const MessageInfo& msgInfo);
66 
67  /// \brief Implement this member to get notified about Cancelled Trade Message.
68  ///
69  /// Default implementation do nothing.
70  ///
71  /// \param msg is a \c CancelledTrade message structure.
72  /// \param msgInfo information about this particular message.
73  virtual void onCancelledTrade(const CancelledTrade& msg, const MessageInfo& msgInfo);
74 
75  /// \brief Implement this member to get notified about Change Price Level Message.
76  ///
77  /// Default implementation do nothing.
78  ///
79  /// \param msg is a \c ChangePriceLevel message structure.
80  /// \param msgInfo information about this particular message.
81  virtual void onChangePriceLevel(const ChangePriceLevel& msg, const MessageInfo& msgInfo);
82 
83  /// \brief Implement this member to get notified about Close Price Message.
84  ///
85  /// Default implementation do nothing.
86  ///
87  /// \param msg is a \c ClosePrice message structure.
88  /// \param msgInfo information about this particular message.
89  virtual void onClosePrice(const ClosePrice& msg, const MessageInfo& msgInfo);
90 
91  /// \brief Implement this member to get notified about Delete Order Message.
92  ///
93  /// Default implementation do nothing.
94  ///
95  /// \param msg is a \c DeleteOrder message structure.
96  /// \param msgInfo information about this particular message.
97  virtual void onDeleteOrder(const DeleteOrder& msg, const MessageInfo& msgInfo);
98 
99  /// \brief Implement this member to get notified about Delete Price Level Message.
100  ///
101  /// Default implementation do nothing.
102  ///
103  /// \param msg is a \c DeletePriceLevel message structure.
104  /// \param msgInfo information about this particular message.
105  virtual void onDeletePriceLevel(const DeletePriceLevel& msg, const MessageInfo& msgInfo);
106 
107  /// \brief Implement this member to get notified about End of Day Market Summary Message.
108  ///
109  /// Default implementation do nothing.
110  ///
111  /// \param msg is a \c EndOfDayMarketSummary message structure.
112  /// \param msgInfo information about this particular message.
113  virtual void onEndOfDayMarketSummary(const EndOfDayMarketSummary& msg, const MessageInfo& msgInfo);
114 
115  /// \brief Implement this member to get notified about Fixing Indicative Price Message.
116  ///
117  /// Default implementation do nothing.
118  ///
119  /// \param msg is a \c FixingIndicativePrice message structure.
120  /// \param msgInfo information about this particular message.
121  virtual void onFixingIndicativePrice(const FixingIndicativePrice& msg, const MessageInfo& msgInfo);
122 
123  /// \brief Implement this member to get notified about Fixing Lockdown Message.
124  ///
125  /// Default implementation do nothing.
126  ///
127  /// \param msg is a \c FixingLockdown message structure.
128  /// \param msgInfo information about this particular message.
129  virtual void onFixingLockdown(const FixingLockdown& msg, const MessageInfo& msgInfo);
130 
131  /// \brief Implement this member to get notified about Fixing Transition Message.
132  ///
133  /// Default implementation do nothing.
134  ///
135  /// \param msg is a \c FixingTransition message structure.
136  /// \param msgInfo information about this particular message.
137  virtual void onFixingTransition(const FixingTransition& msg, const MessageInfo& msgInfo);
138 
139  /// \brief Implement this member to get notified about Futures/OTC Product Definition Response Message.
140  ///
141  /// Default implementation do nothing.
142  ///
143  /// \param msg is a \c FuturesProductDefinition message structure.
144  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
145  /// \note By default all products marked as \e interested to user.
146  virtual void onFuturesProductDefinition(const FuturesProductDefinition& msg, bool& isInterested);
147 
148  /// \brief Implement this member to get notified about Futures Strategy Definition Response Message.
149  ///
150  /// Default implementation do nothing.
151  ///
152  /// \param msg is a \c FuturesStrategyDefinition message structure.
153  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
154  /// \note By default all products marked as \e interested to user.
155  virtual void onFuturesStrategyDefinition(const FuturesStrategyDefinition& msg, bool& isInterested);
156 
157  /// \brief Implement this member to get notified about Interval/Tiered Price Limit Notification Message.
158  ///
159  /// Default implementation do nothing.
160  ///
161  /// \param msg is a \c IntervalTieredPriceLimitNotification message structure.
162  /// \param msgInfo information about this particular message.
163  virtual void onIntervalTieredPriceLimitNotification(
165  const MessageInfo& msgInfo
166  );
167 
168  /// \brief Implement this member to get notified about Investigated Trade Message.
169  ///
170  /// Default implementation do nothing.
171  ///
172  /// \param msg is a \c InvestigatedTrade message structure.
173  /// \param msgInfo information about this particular message.
174  virtual void onInvestigatedTrade(const InvestigatedTrade& msg, const MessageInfo& msgInfo);
175 
176  /// \brief Implement this member to get notified about Login Response Message.
177  ///
178  /// Default implementation do nothing.
179  ///
180  /// \param msg is a \c LoginResponse message structure.
181  virtual void onLoginResponse(const LoginResponse& msg);
182 
183  /// \brief Implement this member to get notified about Marker/Index Prices Message.
184  ///
185  /// Default implementation do nothing.
186  ///
187  /// \param msg is a \c MarkerIndexPrices message structure.
188  /// \param msgInfo information about this particular message.
189  virtual void onMarkerIndexPrices(const MarkerIndexPrices& msg, const MessageInfo& msgInfo);
190 
191  /// \brief Implement this member to get notified about Market Event Message.
192  ///
193  /// Default implementation do nothing.
194  ///
195  /// \param msg is a \c MarketEvent message structure.
196  /// \param msgInfo information about this particular message.
197  virtual void onMarketEvent(const MarketEvent& msg, const MessageInfo& msgInfo);
198 
199  /// \brief Implement this member to get notified about Market Snapshot Message.
200  ///
201  /// Default implementation do nothing.
202  ///
203  /// \param msg is a \c MarketSnapshot message structure.
204  /// \param msgInfo information about this particular message.
205  virtual void onMarketSnapshot(const MarketSnapshot& msg, const MessageInfo& msgInfo);
206 
207  /// \brief Implement this member to get notified about Market Snapshot Order Message.
208  ///
209  /// Default implementation do nothing.
210  ///
211  /// \param msg is a \c MarketSnapshotOrder message structure.
212  /// \param msgInfo information about this particular message.
213  virtual void onMarketSnapshotOrder(const MarketSnapshotOrder& msg, const MessageInfo& msgInfo);
214 
215  /// \brief Implement this member to get notified about Market Snapshot Price Level Message.
216  ///
217  /// Default implementation do nothing.
218  ///
219  /// \param msg is a \c MarketSnapshotPriceLevel message structure.
220  /// \param msgInfo information about this particular message.
221  virtual void onMarketSnapshotPriceLevel(const MarketSnapshotPriceLevel& msg, const MessageInfo& msgInfo);
222 
223  /// \brief Implement this member to get notified about Market State Change Message.
224  ///
225  /// Default implementation do nothing.
226  ///
227  /// \param msg is a \c MarketStateChange message structure.
228  /// \param msgInfo information about this particular message.
229  virtual void onMarketStateChange(const MarketStateChange& msg, const MessageInfo& msgInfo);
230 
231  /// \brief Implement this member to get notified about Market Statistics Message.
232  ///
233  /// Default implementation do nothing.
234  ///
235  /// \param msg is a \c MarketStatistics message structure.
236  /// \param msgInfo information about this particular message.
237  virtual void onMarketStatistics(const MarketStatistics& msg, const MessageInfo& msgInfo);
238 
239  /// \brief Implement this member to get notified about New Expiry Message.
240  ///
241  /// Default implementation do nothing.
242  ///
243  /// \param msg is a \c NewExpiry message structure.
244  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
245  /// \note By default all products marked as \e interested to user.
246  /// \param msgInfo information about this particular message.
247  virtual void onNewExpiry(const NewExpiry& msg, bool& isInterested, const MessageInfo& msgInfo);
248 
249  /// \brief Implement this member to get notified about New Futures Strategy Definition Message.
250  ///
251  /// Default implementation do nothing.
252  ///
253  /// \param msg is a \c NewFuturesStrategyDefinition message structure.
254  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
255  /// \note By default all products marked as \e interested to user.
256  /// \param msgInfo information about this particular message.
257  virtual void onNewFuturesStrategyDefinition(
258  const NewFuturesStrategyDefinition& msg,
259  bool& isInterested,
260  const MessageInfo& msgInfo
261  );
262 
263  /// \brief Implement this member to get notified about New Options Market Definition Message.
264  ///
265  /// Default implementation do nothing.
266  ///
267  /// \param msg is a \c NewOptionsMarketDefinition message structure.
268  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
269  /// \note By default all products marked as \e interested to user.
270  /// \param msgInfo information about this particular message.
271  virtual void onNewOptionsMarketDefinition(
272  const NewOptionsMarketDefinition& msg,
273  bool& isInterested,
274  const MessageInfo& msgInfo
275  );
276 
277  /// \brief Implement this member to get notified about New Options Strategy Definition Message.
278  ///
279  /// Default implementation do nothing.
280  ///
281  /// \param msg is a \c NewOptionsStrategyDefinition message structure.
282  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
283  /// \note By default all products marked as \e interested to user.
284  /// \param msgInfo information about this particular message.
285  virtual void onNewOptionsStrategyDefinition(
286  const NewOptionsStrategyDefinition& msg,
287  bool& isInterested,
288  const MessageInfo& msgInfo
289  );
290 
291  /// \brief Implement this member to get notified about Old Style Options Trade and Market Stats Message.
292  ///
293  /// Default implementation do nothing.
294  ///
295  /// \param msg is a \c OldStyleOptionsTradeAndMarketStats message structure.
296  /// \param msgInfo information about this particular message.
297  virtual void onOldStyleOptionsTradeAndMarketStats(
299  const MessageInfo& msgInfo
300  );
301 
302  /// \brief Implement this member to get notified about Open Interest Message.
303  ///
304  /// Default implementation do nothing.
305  ///
306  /// \param msg is a \c OpenInterest message structure.
307  /// \param msgInfo information about this particular message.
308  virtual void onOpenInterest(const OpenInterest& msg, const MessageInfo& msgInfo);
309 
310  /// \brief Implement this member to get notified about Open Price Message.
311  ///
312  /// Default implementation do nothing.
313  ///
314  /// \param msg is a \c OpenPrice message structure.
315  /// \param msgInfo information about this particular message.
316  virtual void onOpenPrice(const OpenPrice& msg, const MessageInfo& msgInfo);
317 
318  /// \brief Implement this member to get notified about Option Open Interest Message.
319  ///
320  /// Default implementation do nothing.
321  ///
322  /// \param msg is a \c OptionOpenInterest message structure.
323  /// \param msgInfo information about this particular message.
324  virtual void onOptionOpenInterest(const OptionOpenInterest& msg, const MessageInfo& msgInfo);
325 
326  /// \brief Implement this member to get notified about Option Settlement Price Message.
327  ///
328  /// Default implementation do nothing.
329  ///
330  /// \param msg is a \c OptionSettlementPrice message structure.
331  /// \param msgInfo information about this particular message.
332  virtual void onOptionSettlementPrice(const OptionSettlementPrice& msg, const MessageInfo& msgInfo);
333 
334  /// \brief Implement this member to get notified about Options Product Definition Message.
335  ///
336  /// Default implementation do nothing.
337  ///
338  /// \param msg is a \c OptionsProductDefinition message structure.
339  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
340  /// \note By default all products marked as \e interested to user.
341  virtual void onOptionsProductDefinition(const OptionsProductDefinition& msg, bool& isInterested);
342 
343  /// \brief Implement this member to get notified about Options Strategy Definition Message.
344  ///
345  /// Default implementation do nothing.
346  ///
347  /// \param msg is a \c OptionsStrategyDefinition message structure.
348  /// \param isInterested is a flag allows the caller to specify that the product is interested to user.
349  /// \note By default all products marked as \e interested to user.
350  virtual void onOptionsStrategyDefinition(const OptionsStrategyDefinition& msg, bool& isInterested);
351 
352  /// \brief Implement this member to get notified about Pre-Open Price Indicator Message.
353  ///
354  /// Default implementation do nothing.
355  ///
356  /// \param msg is a \c PreOpenPriceIndicator message structure.
357  /// \param msgInfo information about this particular message.
358  virtual void onPreOpenPriceIndicator(const PreOpenPriceIndicator& msg, const MessageInfo& msgInfo);
359 
360  /// \brief Implement this member to get notified about RFQ Message.
361  ///
362  /// Default implementation do nothing.
363  ///
364  /// \param msg is a \c Rfq message structure.
365  /// \param msgInfo information about this particular message.
366  virtual void onRfq(const Rfq& msg, const MessageInfo& msgInfo);
367 
368  /// \brief Implement this member to get notified about Settlement Price Message.
369  ///
370  /// Default implementation do nothing.
371  ///
372  /// \param msg is a \c SettlementPrice message structure.
373  /// \param msgInfo information about this particular message.
374  virtual void onSettlementPrice(const SettlementPrice& msg, const MessageInfo& msgInfo);
375 
376  /// \brief Implement this member to get notified about Special Field Message.
377  ///
378  /// Default implementation do nothing.
379  ///
380  /// \param msg is a \c SpecialField message structure.
381  /// \param msgInfo information about this particular message.
382  virtual void onSpecialField(const SpecialField& msg, const MessageInfo& msgInfo);
383 
384  /// \brief Implement this member to get notified about Spot Market Trade Message.
385  ///
386  /// Default implementation do nothing.
387  ///
388  /// \param msg is a \c SpotMarketTrade message structure.
389  /// \param msgInfo information about this particular message.
390  virtual void onSpotMarketTrade(const SpotMarketTrade& msg, const MessageInfo& msgInfo);
391 
392  /// \brief Implement this member to get notified about Strip Info Message.
393  ///
394  /// Default implementation do nothing.
395  ///
396  /// \param msg is a \c StripInfo message structure.
397  virtual void onStripInfo(const StripInfo& msg);
398 
399  /// \brief Implement this member to get notified about System Text Message.
400  ///
401  /// Default implementation do nothing.
402  ///
403  /// \param msg is a \c SystemText message structure.
404  /// \param msgInfo information about this particular message.
405  virtual void onSystemText(const SystemText& msg, const MessageInfo& msgInfo);
406 
407  /// \brief Implement this member to get notified about Trade Message.
408  ///
409  /// Default implementation do nothing.
410  ///
411  /// \param msg is a \c Trade message structure.
412  /// \param msgInfo information about this particular message.
413  virtual void onTrade(const Trade& msg, const MessageInfo& msgInfo);
414 
415  //@}
416 };
417 
418 }}}} // namespace OnixS::ICE::iMpact::MarketData
Defines an interface through which the Handler notifies subscribers about all received messages...
This class represents the Add/Modify Order Message.
This class represents the Open Price Message.
Definition: OpenPrice.h:35
This class represents the Options Product Definition Message.
This class represents the Fixing Transition Message.
This class represents the Market Snapshot Message.
This class represents the Market Event Message.
Definition: MarketEvent.h:36
This class represents the System Text Message.
Definition: SystemText.h:35
This class represents the Market Snapshot Order Message.
This class represents the Delete Price Level Message.
This class represents the Trade Message.
Definition: Trade.h:36
This class represents the Delete Order Message.
Definition: DeleteOrder.h:35
This class represents the Change Price Level Message.
This class represents the Spot Market Trade Message.
This class represents the New Expiry Message.
Definition: NewExpiry.h:36
This class represents the Open Interest Message.
Definition: OpenInterest.h:35
This class represents the Interval/Tiered Price Limit Notification Message.
This class represents the Marker/Index Prices Message.
This class represents the Message Bundle Marker.
Definition: BundleMarker.h:36
This class represents the Market Statistics Message.
This class represents the Settlement Price Message.
This class represents the Pre-Open Price Indicator Message.
This class represents the Strip Info Message.
Definition: StripInfo.h:35
This class represents the Fixing Lockdown Message.
This class represents the Fixing Indicative Price Message.
This class represents the Market State Change Message.
This class represents the Futures/OTC Product Definition Response Message.
This class represents the Option Open Interest Message.
This class represents the Old Style Options Trade and Market Stats Message.
This class represents the New Options Market Definition Message.
This class represents the Options Strategy Definition Message.
This class represents the Add Price Level Message.
Definition: AddPriceLevel.h:36
This class represents the Futures Strategy Definition Response Message.
This class represents the New Options Strategy Definition Message.
This class represents the Close Price Message.
Definition: ClosePrice.h:35
This class represents the Login Response Message.
Definition: LoginResponse.h:36
This class represents the Special Field Message.
Definition: SpecialField.h:36
Forward declarations of all ICE iMpact messages.
This class represents the New Futures Strategy Definition Message.
This class represents the Cancelled Trade Message.
This class represents the Market Snapshot Price Level Message.
This class represents the End of Day Market Summary Message.
This class represents the Option Settlement Price Message.
This class represents the RFQ Message.
Definition: Rfq.h:36
This class represents the Investigated Trade Message.