EMA C++ Edition
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
DataDictionary.h
Go to the documentation of this file.
1 /*|-----------------------------------------------------------------------------
2  *| and is provided AS IS with no warranty or guarantee of fit for purpose. --
3  *| See the project's LICENSE.md for details. --
4  *| Copyright (C) 2019 Refinitiv. All rights reserved. --
5  *|-----------------------------------------------------------------------------
6  */
7 
8 #ifndef __thomsonreuters_ema_rdm_DataDictionary_h
9 #define __thomsonreuters_ema_rdm_DataDictionary_h
10 
31 #include "Access/Include/Common.h"
33 #include "Access/Include/Series.h"
34 
35 namespace thomsonreuters {
36 
37 namespace ema {
38 
39 namespace access {
40 
41 class FieldListDecoder;
42 
43 }
44 
45 namespace rdm {
46 
47 class DataDictionaryImpl;
48 class DictionaryEntry;
49 class EnumType;
50 class EnumTypeTable;
51 
53 {
54 
55 public:
56 
58 
59 
62 
67 
69 
70 
72  virtual ~DataDictionary();
74 
76 
77 
82  thomsonreuters::ema::access::Int32 getMinFid() const;
83 
89  thomsonreuters::ema::access::Int32 getMaxFid() const;
90 
97 
103  const thomsonreuters::ema::access::EmaVector<EnumTypeTable>& getEnumTables() const;
104 
110  thomsonreuters::ema::access::Int32 getDictionaryId() const;
111 
117  const thomsonreuters::ema::access::EmaString& getFieldVersion() const;
118 
124  const thomsonreuters::ema::access::EmaString& getEnumRecordTemplateVersion() const;
125 
131  const thomsonreuters::ema::access::EmaString& getEnumDisplayTemplateVersion() const;
132 
138  const thomsonreuters::ema::access::EmaString& getFieldFilename() const;
139 
145  const thomsonreuters::ema::access::EmaString& getFieldDescription() const;
146 
152  const thomsonreuters::ema::access::EmaString& getFieldBuild() const;
153 
159  const thomsonreuters::ema::access::EmaString& getFieldDate() const;
160 
166  const thomsonreuters::ema::access::EmaString& getEnumFilename() const;
167 
173  const thomsonreuters::ema::access::EmaString& getEnumDescription() const;
174 
180  const thomsonreuters::ema::access::EmaString& getEnumDate() const;
181 
189  bool hasEntry(thomsonreuters::ema::access::Int16 fieldId) const;
190 
200  void getEntry(thomsonreuters::ema::access::Int16 fieldId, DictionaryEntry& entry) const;
201 
211  const DictionaryEntry& getEntry(thomsonreuters::ema::access::Int16 fieldId) const;
212 
220  bool hasEntry(const thomsonreuters::ema::access::EmaString& fieldName) const;
221 
231  void getEntry(const thomsonreuters::ema::access::EmaString& fieldName, DictionaryEntry& entry) const;
232 
242  const DictionaryEntry& getEntry(const thomsonreuters::ema::access::EmaString& fieldName) const;
243 
252  bool hasEnumType(thomsonreuters::ema::access::Int16 fieldId, thomsonreuters::ema::access::UInt16 value) const;
253 
267 
269 
270 
275  void clear();
276 
289  void loadFieldDictionary(const thomsonreuters::ema::access::EmaString& filename);
290 
303  void loadEnumTypeDictionary(const thomsonreuters::ema::access::EmaString& filename);
304 
319  void encodeFieldDictionary(thomsonreuters::ema::access::Series& series, thomsonreuters::ema::access::UInt32 verbosity);
320 
340  bool encodeFieldDictionary(thomsonreuters::ema::access::Series& series,
342  thomsonreuters::ema::access::UInt32 fragmentationSize);
343 
358  void decodeFieldDictionary(const thomsonreuters::ema::access::Series& series, thomsonreuters::ema::access::UInt32 verbosity);
359 
372  void encodeEnumTypeDictionary(thomsonreuters::ema::access::Series& series, thomsonreuters::ema::access::UInt32 verbosity);
373 
393  bool encodeEnumTypeDictionary(thomsonreuters::ema::access::Series& series, thomsonreuters::ema::access::Int32& enumTableCount,
395 
409  void decodeEnumTypeDictionary(const thomsonreuters::ema::access::Series& series, thomsonreuters::ema::access::UInt32 verbosity);
410 
424 
429  const thomsonreuters::ema::access::EmaString& toString() const;
430 
434  operator const char* () const;
436 
437 private:
438 
439  friend class thomsonreuters::ema::access::FieldListDecoder;
440 
441  DataDictionary(bool);
442 
443  DataDictionary& operator=(const DataDictionary&);
444 
445  DataDictionaryImpl* _pImpl;
446 };
447 
448 }
449 
450 }
451 
452 }
453 
454 #endif // __thomsonreuters_ema_rdm_DataDictionary_h
455 
456 
457 
unsigned short UInt16
represents 16-bit unsigned integer
Definition: Common.h:44
EmaVector class provides template vector implementation.
Definition: EmaVector.h:29
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
#define EMA_ACCESS_API
Definition: Common.h:95
int Int32
represents 32-bit signed integer
Definition: Common.h:62
Common.h file provides definitions of common variable types used in EMA.
Series is a homogeneous container of complex data type entries.
Definition: Series.h:128
short Int16
represents 16-bit signed integer
Definition: Common.h:50