EMA C++ Edition
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
OmmDate.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_OmmDate_h
10 #define __thomsonreuters_ema_access_OmmDate_h
11 
59 #include "Access/Include/Data.h"
60 
61 namespace thomsonreuters {
62 
63 namespace ema {
64 
65 namespace access {
66 
67 class OmmDateDecoder;
68 
69 class EMA_ACCESS_API OmmDate : public Data
70 {
71 public :
72 
74 
75 
78  DataType::DataTypeEnum getDataType() const;
79 
83  Data::DataCode getCode() const;
84 
88  const EmaBuffer& getAsHex() const;
89 
93  const EmaString& toString() const;
94 
98  UInt16 getYear() const;
99 
103  UInt8 getMonth() const;
104 
108  UInt8 getDay() const;
110 
111 private :
112 
113  friend class Decoder;
114  friend class StaticDecoder;
115  friend class DateTimeStringFormat;
116 
117  Decoder& getDecoder();
118  bool hasDecoder() const;
119 
120  const EmaString& toString( UInt64 indent ) const;
121 
122  const Encoder& getEncoder() const;
123  bool hasEncoder() const;
124 
125  OmmDate();
126  virtual ~OmmDate();
127  OmmDate( const OmmDate& );
128  OmmDate& operator=( const OmmDate& );
129 
130  OmmDateDecoder* _pDecoder;
131  UInt64 _space[12];
132 };
133 
134 }
135 
136 }
137 
138 }
139 
140 #endif // __thomsonreuters_ema_access_OmmDate_h
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
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
DateTimeStringFormat is an interface to string conversion methods for OmmDate, OmmTime & OmmDateTime...
#define EMA_ACCESS_API
Definition: Common.h:95
OmmDate represents Date info in Omm.
Definition: OmmDate.h:69
Data class is a parent abstract class defining common interfaces for all Data type classes...
Definition: Data.h:38
unsigned char UInt8
represents 8-bit unsigned integer
Definition: Common.h:32