OnixS C++ CME MDP Streamlined Market Data Handler 1.2.0
API Documentation
Loading...
Searching...
No Matches
HandlerListener.h
Go to the documentation of this file.
1// Copyright Onix Solutions Limited [OnixS]. All rights reserved.
2//
3// This software owned by Onix Solutions Limited [OnixS] and is
4// protected by copyright law and international copyright treaties.
5//
6// Access to and use of the software is governed by the terms of the applicable
7// OnixS Software Services Agreement (the Agreement) and Customer end user license
8// agreements granting a non-assignable, non-transferable and non-exclusive license
9// to use the software for it's own data processing purposes under the terms defined
10// in the Agreement.
11//
12// Except as otherwise granted within the terms of the Agreement, copying or
13// reproduction of any part of this source code or associated reference material
14// to any other location for further reproduction or redistribution, and any
15// amendments to this copyright notice, are expressly prohibited.
16//
17// Any reproduction or redistribution for sale or hiring of the Software not in
18// accordance with the terms of the Agreement is a violation of copyright law.
19//
20
21#pragma once
22
23#include <string>
24
26
28
48
51{
52public:
57
61 const std::string& message = std::string())
62 : status_(status), message_(message)
63 {
64 }
65
68 {
69 return status_;
70 }
71
73 void
76 {
77 status_ = status;
78 }
79
82 const std::string& details() const
83 {
84 return message_;
85 }
86
89 void
91 const std::string& message)
92 {
93 message_ = message;
94 }
95
96private:
98 std::string message_;
99};
100
142
146IssueArgs
147{
148 Issue::Enum id_;
149 const std::string& source_;
150 const std::string& description_;
151
152 IssueArgs(const IssueArgs&);
153 IssueArgs& operator =(const IssueArgs&);
154
155public:
158 Issue::Enum id,
159 const std::string& source,
160 const std::string& description)
161 : id_(id)
162 , source_(source)
163 , description_(description)
164 {
165 }
166
169 {
170 return id_;
171 }
172
174 const std::string& source() const
175 {
176 return source_;
177 }
178
180 const std::string& description() const
181 {
182 return description_;
183 }
184};
185
187typedef
188IssueArgs
190
192typedef
195
197
201{
203 virtual
204 void
206 {
207 }
208
210 virtual
211 void
213 {
214 }
215
217 virtual
218 void
220 {
221 }
222
224 virtual
225 void
227 Handler&,
229 {
230 }
231
234 virtual
235 void
239
242 virtual
243 void
247
253 virtual
254 void
256 Handler&,
257 const WarningArgs&)
258 {
259 }
260
267 virtual
268 void
270 Handler&,
271 const ErrorArgs&)
272 {
273 }
274};
275
#define ONIXS_CMESTREAMLINEDMDH_EXPORTED_STRUCT
Definition Bootstrap.h:67
#define ONIXS_CMESTREAMLINEDMDH_EXPORTED_CLASS_DECL(typeName)
Definition Bootstrap.h:55
#define ONIXS_CMESTREAMLINEDMDH_NAMESPACE_BEGIN
Definition Bootstrap.h:169
#define ONIXS_CMESTREAMLINEDMDH_LTWT_STRUCT
Definition Bootstrap.h:115
#define ONIXS_CMESTREAMLINEDMDH_NAMESPACE_END
Definition Bootstrap.h:173
#define ONIXS_CMESTREAMLINEDMDH_LTWT_CLASS
Definition Bootstrap.h:111
Encapsulates all the machinery related with market data processing from CME Market Data Platform.
Definition Handler.h:51
Gathers information about the issue Handler may experience while processing market data.
Issue::Enum id() const
Issue identifier.
IssueArgs(Issue::Enum id, const std::string &source, const std::string &description)
Initializes issue with provided attributes.
const std::string & source() const
Source of the issue.
const std::string & description() const
Human readable description of the issue.
Gathers information about the recovery completion.
RecoveryCompletionArgs(RecoveryCompletionStatus::Enum status, const std::string &message=std::string())
Initializes with given details.
const std::string & details() const
Human readable description of recovery completion.
void details(const std::string &message)
Associates human readable message with recover completion event.
RecoveryCompletionArgs()
Initializes as blank instance.
void status(RecoveryCompletionStatus::Enum status)
Assigns completion status of the recovery.
RecoveryCompletionStatus::Enum status() const
Indicates completion status of the recovery.
IssueArgs ErrorArgs
Error arguments.
IssueArgs WarningArgs
Warning arguments.
Events raised by Handler while processing market data.
virtual void onStopped(Handler &)
Invoked when Handler has stopped market data processing.
virtual void onStarted(Handler &)
Handler is has started to process market data.
virtual void onError(Handler &, const ErrorArgs &)
Error occurred while Handler is processing market data.
virtual void onTcpRecovery(Handler &)
Handler spawned recovery of lost packets over TCP feed.
virtual void onEndOfTcpRecovery(Handler &, const RecoveryCompletionArgs &)
Handler accomplished recovery of lost packets over TCP feed.
virtual void onEndOfRealtimeProcessing(Handler &)
Handler suspended real-time processing of market data received over incremental feeds.
virtual void onWarning(Handler &, const WarningArgs &)
Non-critical issue occurred while Handler is processing market data.
virtual void onRealtimeProcessing(Handler &)
Handler resumed real-time processing of market data received over incremental feeds.
Collection of issues Handler may report during market data processing.
@ ConnectionFailure
Identifies network connection failure.
@ ProcessingFailure
Indicates data processing failure.
@ ReceiveTimeout
Indicates data receive timeout.
@ ReducedCapacity
Source reported this issue will function in reduced capacity.
@ QueueOverflow
Indicates internal queue overflow.
@ OperationFailure
Operation performed by the Handler failed.
@ ReplayFailure
Market data replay failed.
@ ReceiveFailure
Indicates data reception failure.
@ SequenceError
Indicates error in data sequence.
Collection of statuses of recovery completion.
@ Failed
Recovery failed and no further attempts to recover will be made.
@ Succeeded
Recovery accomplished successfully.