question

Upvotes
Accepted
2 1 1 4

ETA: com.thomsonreuters.upa.codec.Date month method

We are upgrading our application to use ETA API. To read date FIDs, we use this class com.thomsonreuters.upa.codec.Date. It has a method named month() to return the month in integer values. My question is that does it always return 1 to 12 to represent the months? Are there scenarios where the month will return 0 to 11 instead, similar to Java Calendar class convention?


We are currently using upa-8.0.0.L1.all.rrg version

eta-apidate
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
Upvotes
Accepted
32.2k 41 11 20

Hello @hermes.tanhueco ,

ETA is part of RTSDK is an open source API: https://github.com/Refinitiv/Real-Time-SDK/ so you can look up the implementation of the library.

In OmmDate.h I find:

/** Returns Month. Range is 0 - 12 where 0 indicates blank.
@return value of month
*/
UInt8 getMonth() const;

Hope that this information helps

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

But this one is for OMM CPP. Do you know where I can find the implementation of

com.thomsonreuters.upa.codec.Date?

Hello @hermes.tanhueco ,

UPA was the predecessor API of ETA. ETA was created based on UPA.

UPA was never open-sourced, so you will not be able to find the implementation of UPA, however, I think with a good probability the implementation of this aspect has stayed consistent between the two, this is why I think the insight that you will find in ETA C++ open-sourced code base is relevant to your question.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.