EMA C++ Edition
FieldList.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, 2024 LSEG. All rights reserved. --
6 *|-----------------------------------------------------------------------------
7 */
8
9#ifndef __refinitiv_ema_access_FieldList_h
10#define __refinitiv_ema_access_FieldList_h
11
145#include "DataDictionary.h"
146
147namespace refinitiv {
148
149namespace ema {
150
151namespace rdm {
152
154
155}
156
157namespace access {
158
159class ReqMsg;
160class RefreshMsg;
161class StatusMsg;
162class UpdateMsg;
163class GenericMsg;
164class PostMsg;
165class AckMsg;
166class ElementList;
167class Map;
168class Vector;
169class Series;
170class FilterList;
171class OmmArray;
172class OmmOpaque;
173class OmmXml;
174class OmmAnsiPage;
175
176class FieldListDecoder;
177class FieldListEncoder;
178
180{
181public :
182
184
185
189
191
192
194 virtual ~FieldList();
196
198
199
203
208
212 const EmaBuffer& getAsHex() const;
213
217 const EmaString& toString() const;
218
223 const EmaString& toString( const refinitiv::ema::rdm::DataDictionary& dictionary ) const;
224
228 bool hasInfo() const;
229
235
241
246 bool forth() const;
247
253 bool forth( Int16 fieldId ) const;
254
260 bool forth( const EmaString& name ) const;
261
267 bool forth( const Data& data ) const;
268
273 const FieldEntry& getEntry() const;
274
277 void reset() const;
279
281
282
287
295 FieldList& info( Int16 dictionaryId, Int16 fieldListNum );
296
303 FieldList& addReqMsg( Int16 fieldId, const ReqMsg& value );
304
311 FieldList& addRefreshMsg( Int16 fieldId, const RefreshMsg& value );
312
319 FieldList& addStatusMsg( Int16 fieldId, const StatusMsg& value );
320
327 FieldList& addUpdateMsg( Int16 fieldId, const UpdateMsg& value );
328
335 FieldList& addPostMsg( Int16 fieldId, const PostMsg& value );
336
343 FieldList& addAckMsg( Int16 fieldId, const AckMsg& value );
344
351 FieldList& addGenericMsg( Int16 fieldId, const GenericMsg& value );
352
359 FieldList& addFieldList( Int16 fieldId, const FieldList& value );
360
367 FieldList& addElementList( Int16 fieldId, const ElementList& value );
368
375 FieldList& addMap( Int16 fieldId, const Map& value );
376
383 FieldList& addVector( Int16 fieldId, const Vector& value );
384
391 FieldList& addSeries( Int16 fieldId, const Series& value );
392
399 FieldList& addFilterList( Int16 fieldId, const FilterList& value );
400
407 FieldList& addOpaque( Int16 fieldId, const OmmOpaque& value );
408
415 FieldList& addXml( Int16 fieldId, const OmmXml& value );
416
423 FieldList& addAnsiPage( Int16 fieldId, const OmmAnsiPage& value );
424
431 FieldList& addInt( Int16 fieldId, Int64 value );
432
439 FieldList& addUInt( Int16 fieldId, UInt64 value );
440
448 FieldList& addReal( Int16 fieldId, Int64 mantissa, OmmReal::MagnitudeType magnitudeType );
449
457 FieldList& addRealFromDouble( Int16 fieldId, double value,
459
466 FieldList& addFloat( Int16 fieldId, float value );
467
474 FieldList& addDouble( Int16 fieldId, double value );
475
485 FieldList& addDate( Int16 fieldId, UInt16 year, UInt8 month, UInt8 day );
486
499 FieldList& addTime( Int16 fieldId, UInt8 hour = 0, UInt8 minute = 0, UInt8 second = 0,
500 UInt16 millisecond = 0, UInt16 microsecond = 0, UInt16 nanosecond = 0 );
501
517 FieldList& addDateTime( Int16 fieldId, UInt16 year, UInt8 month, UInt8 day,
518 UInt8 hour = 0, UInt8 minute = 0, UInt8 second = 0,
519 UInt16 millisecond = 0, UInt16 microsecond = 0, UInt16 nanosecond = 0 );
520
529
541 UInt8 statusCode = OmmState::NoneEnum,
542 const EmaString& statusText = EmaString() );
543
550 FieldList& addEnum( Int16 fieldId, UInt16 value );
551
558 FieldList& addBuffer( Int16 fieldId, const EmaBuffer& value );
559
566 FieldList& addAscii( Int16 fieldId, const EmaString& value );
567
574 FieldList& addUtf8( Int16 fieldId, const EmaBuffer& value );
575
582 FieldList& addRmtes( Int16 fieldId, const EmaBuffer& value );
583
590 FieldList& addArray( Int16 fieldId, const OmmArray& value );
591
597
603
609
615
621
627
633
639
645
651
657
662
668
674
679
686
687private :
688
690
691 void getInfoXmlStr( EmaString& ) const;
692
693 Decoder& getDecoder();
694 bool hasDecoder() const;
695
696 const Encoder& getEncoder() const;
697 bool hasEncoder() const;
698
699 const EmaString& toString( UInt64 indent ) const;
700
701 mutable EmaString _toString;
702 FieldEntry _entry;
703 mutable FieldListDecoder* _pDecoder;
704 mutable FieldListEncoder* _pEncoder;
705
706 FieldList( const FieldList& );
707 FieldList& operator=( const FieldList&);
708};
709
710}
711
712}
713
714}
715
716#endif // __refinitiv_ema_access_FieldList_h
#define EMA_ACCESS_API
Definition: Common.h:95
*|--------------------------------------------------------------------------—
Definition: AckMsg.h:62
short Int16
represents 16-bit signed integer
Definition: Common.h:50
unsigned int UInt32
represents 32-bit unsigned integer
Definition: Common.h:56
long long Int64
represents 64-bit signed integer
Definition: Common.h:74
unsigned char UInt8
represents 8-bit unsigned integer
Definition: Common.h:32
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
The access namespace contains all interfaces and definitions specified for use with the EMA Access pa...
The ema namespace contains all interfaces and definitions specified for use with EMA.
The rdm namespace contains all RDM definitions and constants.
AckMsg indicates success or failure of PostMsg.
Definition: AckMsg.h:69
ComplexType class is a parent class from whom all complex data types inherit.
Definition: ComplexType.h:34
Data class is a parent abstract class defining common interfaces for all Data type classes.
Definition: Data.h:39
ElementList is a heterogeneous container of complex and primitive data type entries.
Definition: ElementList.h:178
EmaBuffer represents a general use binary buffer.
Definition: EmaBuffer.h:33
EmaString class is a container of a null terminated Ascii character string.
Definition: EmaString.h:57
FieldEntry represents an entry of FieldList.
Definition: FieldEntry.h:99
FieldList is a heterogeneous container of complex and primitive data type entries.
Definition: FieldList.h:180
FieldList & addCodeState(Int16 fieldId)
FieldList & addAnsiPage(Int16 fieldId, const OmmAnsiPage &value)
DataType::DataTypeEnum getDataType() const
FieldList & addCodeReal(Int16 fieldId)
FieldList & addState(Int16 fieldId, OmmState::StreamState streamState=OmmState::OpenEnum, OmmState::DataState dataState=OmmState::OkEnum, UInt8 statusCode=OmmState::NoneEnum, const EmaString &statusText=EmaString())
FieldList & addUpdateMsg(Int16 fieldId, const UpdateMsg &value)
FieldList & addCodeInt(Int16 fieldId)
FieldList & addAscii(Int16 fieldId, const EmaString &value)
FieldList & addFloat(Int16 fieldId, float value)
FieldList & addElementList(Int16 fieldId, const ElementList &value)
FieldList & info(Int16 dictionaryId, Int16 fieldListNum)
FieldList & addUtf8(Int16 fieldId, const EmaBuffer &value)
FieldList & addTime(Int16 fieldId, UInt8 hour=0, UInt8 minute=0, UInt8 second=0, UInt16 millisecond=0, UInt16 microsecond=0, UInt16 nanosecond=0)
FieldList & addOpaque(Int16 fieldId, const OmmOpaque &value)
FieldList & addCodeAscii(Int16 fieldId)
FieldList & addDouble(Int16 fieldId, double value)
FieldList & addGenericMsg(Int16 fieldId, const GenericMsg &value)
FieldList & addArray(Int16 fieldId, const OmmArray &value)
FieldList & addDateTime(Int16 fieldId, UInt16 year, UInt8 month, UInt8 day, UInt8 hour=0, UInt8 minute=0, UInt8 second=0, UInt16 millisecond=0, UInt16 microsecond=0, UInt16 nanosecond=0)
FieldList & addCodeFloat(Int16 fieldId)
FieldList & addBuffer(Int16 fieldId, const EmaBuffer &value)
FieldList & addInt(Int16 fieldId, Int64 value)
FieldList & addCodeDate(Int16 fieldId)
FieldList & addPostMsg(Int16 fieldId, const PostMsg &value)
FieldList & addDate(Int16 fieldId, UInt16 year, UInt8 month, UInt8 day)
FieldList & addSeries(Int16 fieldId, const Series &value)
FieldList & addCodeEnum(Int16 fieldId)
FieldList & addCodeBuffer(Int16 fieldId)
const EmaString & toString(const refinitiv::ema::rdm::DataDictionary &dictionary) const
FieldList & addMap(Int16 fieldId, const Map &value)
FieldList & addCodeTime(Int16 fieldId)
FieldList & addCodeDouble(Int16 fieldId)
FieldList & addCodeRmtes(Int16 fieldId)
bool forth(Int16 fieldId) const
FieldList & addRmtes(Int16 fieldId, const EmaBuffer &value)
FieldList & addReal(Int16 fieldId, Int64 mantissa, OmmReal::MagnitudeType magnitudeType)
FieldList & addRefreshMsg(Int16 fieldId, const RefreshMsg &value)
bool forth(const EmaString &name) const
const EmaBuffer & getAsHex() const
FieldList & addCodeDateTime(Int16 fieldId)
FieldList & addUInt(Int16 fieldId, UInt64 value)
const FieldEntry & getEntry() const
FieldList & addEnum(Int16 fieldId, UInt16 value)
FieldList & addCodeUInt(Int16 fieldId)
FieldList & addCodeQos(Int16 fieldId)
FieldList & addStatusMsg(Int16 fieldId, const StatusMsg &value)
FieldList & addCodeUtf8(Int16 fieldId)
FieldList & addRealFromDouble(Int16 fieldId, double value, OmmReal::MagnitudeType magnitudeType=OmmReal::Exponent0Enum)
FieldList & addReqMsg(Int16 fieldId, const ReqMsg &value)
FieldList & addAckMsg(Int16 fieldId, const AckMsg &value)
FieldList & addFilterList(Int16 fieldId, const FilterList &value)
bool forth(const Data &data) const
FieldList & addVector(Int16 fieldId, const Vector &value)
FieldList & addFieldList(Int16 fieldId, const FieldList &value)
const EmaString & toString() const
FieldList & addQos(Int16 fieldId, UInt32 timeliness=OmmQos::RealTimeEnum, UInt32 rate=OmmQos::TickByTickEnum)
Data::DataCode getCode() const
FieldList & addXml(Int16 fieldId, const OmmXml &value)
FilterList is a heterogeneous container of complex data type entries.
Definition: FilterList.h:134
GenericMsg allows applications to bidirectionally send messages without any implied message semantics...
Definition: GenericMsg.h:88
Map is a homogeneous container of complex data type entries.
Definition: Map.h:126
OmmAnsiPage represents AnsiPage data format in Omm.
Definition: OmmAnsiPage.h:73
OmmArray is a homogeneous container of primitive data type entries.
Definition: OmmArray.h:87
OmmOpaque represents Opaque data format in Omm.
Definition: OmmOpaque.h:73
OmmXml represents XML data format in Omm.
Definition: OmmXml.h:73
PostMsg allows consumer applications to contribute content.
Definition: PostMsg.h:63
RefreshMsg conveys item image, state, permission and group information.
Definition: RefreshMsg.h:80
ReqMsg allows consumer application to express its interest in an item.
Definition: ReqMsg.h:60
Series is a homogeneous container of complex data type entries.
Definition: Series.h:130
StatusMsg conveys item state information.
Definition: StatusMsg.h:81
UpdateMsg conveys changes to item data.
Definition: UpdateMsg.h:73
Vector is a homogeneous container of complex data type entries.
Definition: Vector.h:123