farnulfo / Example.EMA.Java.ValueAddObjectsForEMA

Value-add objects for EMA

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ValueAddObjectsForEMA

Table of Content

Overview

This project is one of the many learning materials published by Refinitiv to help developers learning Refinitiv APIs. It contains an example library of value add objects, logics and algorithms shared among the Enterprise Message API (EMA) example applications built by Refinitiv Developer Advocates for the Developer Community. The rationales that lead to the development of these value add objects are detailed in the Simplifying Content Access in EMA article available on the Refinitiv Developer Community portal. The ValueAddObjectsForEMA example library is based on the Java edition of the Enterprise Message API that is one of the APIs of the Refinitiv Real-Time SDK. Please consult this Refinitiv Real-Time SDK page for more learning materials and documentation about this API.

For any question related to this project please use the Developer Community Q&A Forum.

Note: To be able to ask questions and to benefit from the full content available on the Refinitiv Developer Community portal we recommend you to register here.

Disclaimer

The ValueAddObjectsForEMA example library has been written by Refinitiv for the only purpose of illustrating a series of articles published on the Refinitiv Developer Community. The ValueAddObjectsForEMA example library has not been tested for a usage in production environments. Refinitiv cannot be held responsible for any issues that may happen if this project or the related source code is used in production or any other client environment.

Prerequisites

Required software components:

  • Enterprise Message API (2.0 or greater) - Refinitiv interface to the Refinitiv Real-Time Market Data environment
  • JDK 8 - Java Development Kit - version 8

Implemented Features

ValueAddObjectsForEMA is an example of a complementary library to be used alongside EMA in order to provide a higher level of abstraction. It provides objects and helpers that complement EMA and that simplify the coding of EMA applications. ValueAddObjectsForEMA is implemented incrementally, in parallel with the EMA example applications built by Refinitiv Developer Advocates. It currently provides the following features:

  • Helpers to dispatch event and wait for conditions
  • A synchronous and asynchronous subscribing modes.
  • MarketPrice objects with a caching facility, a random access to field values and a full dictionary description associated to each field.
  • Chain objects with a caching facility and a random access to chain constituents.

These features are implemented in the following packages:

  • com.refinitiv.platformservices.rt.objects.common
    This package contains common interfaces and classes used by other modules of the library. It also provides general helper classes used by example applications (e.g. Dispatcher).
  • com.refinitiv.platformservices.rt.objects.data
    This package contains in-memory implementations of OMM Data that are required by other modules for caching received data in-memory.
  • com.refinitiv.platformservices.rt.objects.marketprice
    This package contains the interface and implementation class of MarketPrice objects that provides higher level features like: in-memory data caching, a random access to field values, full field description, synchronous/asynchronous subscription, completion status...
    Note: For more details about the logic implemented by the MarketPrice objects, please refer to the A simple MarketPrice object for EMA article.
  • com.refinitiv.platformservices.rt.objects.chain
    This package contains the interface and implementation class of Chain objects that allow to automaticaly open chains and provides to their constituents.
    Note: For more details about the logic implemented by the FlatChain and RecursiveChain objects, please refer to the Simple Chain objects for EMA article.
  • com.refinitiv.platformservices.rt.objects.examples.marketprice
    This package contains an example application that demonstrates the MarketPrice objects capabilities and how to use them. The application starts by creating an EMA OmmConsumer and uses it in with MarketPrice objects in several individual steps that demonstrate the implemented features. Before each step, explanatory text is displayed and you are prompted to press to start the step.
  • com.refinitiv.platformservices.rt.objects.examples.chain
    This package contains an example application that demonstrates the FlatChain and RecursiveChain objects capabilities and how to use them. The application starts by creating an EMA OmmConsumer and uses it in with Chain objects in several individual steps that demonstrate the implemented features. Before each step, explanatory text is displayed and you are prompted to press to start the step.

The ValueAddObjectsForEMA example library also comes with a Javadoc that fully describes the exposed APIs.

Note: If you do not know yet about the Enterprise Message API (EMA) and how to program and EMA consumer application I recommend you to follow this EMA Quick Start and these EMA Tutorials.

Building the ValueAddObjectsForEMA library

Change the service name and DACS user name if need be

The MarketPriceStepByStepExample.java file and ChainStepByStepExample.java file contain two hardcoded values that you may want to change depending on the TREP or Elektron Real-Time platform you use. These values indicate:

  • The service name used to subscribe: The hardcoded value is "ELEKTRON_DD". This value can be changed to that of the available service in the current environment.

Solution Code

The ValueAddObjectsForEMA example library was developed using the Refinitiv Real-Time SDK Java API that is available for download here.

Built With

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Authors

  • Olivier Davant - Release 1.0. Initial version

License

This project is licensed under the MIT License - see the LICENSE.md file for details

About

Value-add objects for EMA

License:MIT License


Languages

Language:Java 98.8%Language:Batchfile 1.2%