EMA C++ Edition
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GenericMsg.h
Go to the documentation of this file.
1 /*|-----------------------------------------------------------------------------
2  *| This source code is provided under the Apache 2.0 license --
3  *| and is provided AS IS with no warranty or guarantee of fit for purpose. --
4  *| See the project's LICENSE.md for details. --
5  *| Copyright (C) 2019 Refinitiv. All rights reserved. --
6  *|-----------------------------------------------------------------------------
7  */
8 
9 #ifndef __thomsonreuters_ema_access_GenericMsg_h
10 #define __thomsonreuters_ema_access_GenericMsg_h
11 
78 #include "Access/Include/Msg.h"
79 
80 namespace thomsonreuters {
81 
82 namespace ema {
83 
84 namespace access {
85 
87 {
88 public :
89 
91 
92 
94  GenericMsg();
95 
100  GenericMsg( const GenericMsg& other );
102 
104 
105 
107  virtual ~GenericMsg();
109 
111 
112 
115  DataType::DataTypeEnum getDataType() const;
116 
120  Data::DataCode getCode() const;
121 
125  const EmaBuffer& getAsHex() const;
126 
130  const EmaString& toString() const;
131 
136  bool hasSeqNum() const;
137 
142  bool hasSecondarySeqNum() const;
143 
148  bool hasPartNum() const;
149 
154  bool hasPermissionData() const;
155 
160  UInt32 getSeqNum() const;
161 
166  UInt32 getSecondarySeqNum() const;
167 
172  UInt16 getPartNum() const;
173 
178  const EmaBuffer& getPermissionData() const;
179 
183  bool getComplete() const;
185 
187 
188 
192  GenericMsg& clear();
193 
198  GenericMsg& streamId( Int32 streamId );
199 
205  GenericMsg& domainType( UInt16 domainType = rdm::MMT_MARKET_PRICE );
206 
211  GenericMsg& name( const EmaString& name );
212 
217  GenericMsg& nameType( UInt8 nameType = rdm::INSTRUMENT_NAME_RIC );
218 
223  GenericMsg& serviceId( UInt32 serviceId );
224 
229  GenericMsg& id( Int32 id );
230 
235  GenericMsg& filter( UInt32 filter );
236 
241  GenericMsg& seqNum( UInt32 seqNum );
242 
247  GenericMsg& secondarySeqNum( UInt32 secondarySeqNum );
248 
253  GenericMsg& partNum( UInt16 partNum );
254 
259  GenericMsg& permissionData( const EmaBuffer& permissionData );
260 
265  GenericMsg& attrib( const ComplexType& data );
266 
271  GenericMsg& payload( const ComplexType& data );
272 
277  GenericMsg& extendedHeader( const EmaBuffer& buffer );
278 
283  GenericMsg& providerDriven(bool providerDriven = true);
284 
290  GenericMsg& complete( bool complete = true );
292 
293 private :
294 
295  friend class ItemCallbackClient;
296 
297  const EmaString& toString( UInt64 indent ) const;
298 
299  Decoder& getDecoder();
300 
301  GenericMsg& operator=( const GenericMsg& );
302 
303  mutable EmaString _toString;
304 };
305 
306 }
307 
308 }
309 
310 }
311 
312 #endif
unsigned short UInt16
represents 16-bit unsigned integer
Definition: Common.h:44
unsigned long long UInt64
represents 64-bit unsigned integer
Definition: Common.h:68
Msg class is a parent class for all message representing classes.
Definition: Msg.h:45
unsigned int UInt32
represents 32-bit unsigned integer
Definition: Common.h:56
EmaString class is a container of a null terminated Ascii character string.
Definition: EmaString.h:56
EmaBuffer represents a general use binary buffer.
Definition: EmaBuffer.h:32
#define EMA_ACCESS_API
Definition: Common.h:95
ComplexType class is a parent class from whom all complex data types inherit.
Definition: ComplexType.h:33
int Int32
represents 32-bit signed integer
Definition: Common.h:62
GenericMsg allows applications to bidirectionally send messages without any implied message semantics...
Definition: GenericMsg.h:86
static const thomsonreuters::ema::access::UInt8 INSTRUMENT_NAME_RIC
Definition: EmaRdm.h:197
static const thomsonreuters::ema::access::UInt8 MMT_MARKET_PRICE
Definition: EmaRdm.h:50
unsigned char UInt8
represents 8-bit unsigned integer
Definition: Common.h:32