|
dxFeed Graal CXX API v9.0.0
|
The client of the Order Reconstruction Service (ORCS): the price levels (Order events) and the quotes (Quote events) of a symbol for a period of time. More...
#include <PriceLevelService.hpp>
Public Types | |
| using | Ptr = std::shared_ptr<PriceLevelService> |
| The alias to a type of shared pointer to the PriceLevelService object. | |
| Public Types inherited from SharedEntity | |
| using | Ptr = std::shared_ptr<SharedEntity> |
| The alias to a type of shared pointer to the SharedEntity object. | |
Public Member Functions | |
| ~PriceLevelService () noexcept override | |
| Closes the service if it is not closed yet. | |
| std::vector< std::shared_ptr< Order > > | getOrders (const CandleSymbol &candleSymbol, const OrderSource &orderSource, std::int64_t from, std::int64_t to, StringParam caller) const |
| Returns the price levels of the given CandleSymbol and OrderSource within the given from and to times, sorted by time. | |
| std::vector< std::shared_ptr< Order > > | getOrders (const CandleSymbol &candleSymbol, const OrderSource &orderSource, std::int64_t from, std::int64_t to) const |
| Returns the price levels of the given CandleSymbol and OrderSource within the given from and to times, sorted by time. | |
| std::vector< std::shared_ptr< Quote > > | getQuotes (const CandleSymbol &candleSymbol, std::int64_t from, std::int64_t to, StringParam caller) const |
| Returns the quotes of the given CandleSymbol within the given from and to times, sorted by time. | |
| std::vector< std::shared_ptr< Quote > > | getQuotes (const CandleSymbol &candleSymbol, std::int64_t from, std::int64_t to) const |
| Returns the quotes of the given CandleSymbol within the given from and to times, sorted by time. | |
| std::shared_ptr< AuthOrderSource > | getAuthOrderSource () const |
| Returns the order sources and the symbols of each order source available to the client, filtered according to the client permissions. | |
| void | close () |
| Closes (disconnects) the service. | |
| Public Member Functions inherited from SharedEntity | |
| template<typename T> | |
| bool | is () const noexcept |
| Checks that the object is of type T: its dynamic type is T or derived from T. | |
| template<typename T> | |
| std::shared_ptr< T > | sharedAs () noexcept |
| Returns a pointer to the current object wrapped in a smart pointer to type T or std::shared_ptr<T>{nullptr} if the object is not managed by std::shared_ptr. | |
| template<typename T> | |
| std::shared_ptr< T > | sharedAs () const noexcept |
| Returns a pointer to the current object wrapped in a smart pointer to type T or std::shared_ptr<T>{nullptr} if the object is not managed by std::shared_ptr. | |
| virtual std::string | toString () const |
| Returns a string representation of the current object. | |
| Public Member Functions inherited from Entity | |
| virtual | ~Entity () noexcept |
| The default virtual d-tor. | |
Static Public Member Functions | |
| static std::shared_ptr< PriceLevelService > | create (StringParam address) |
| Creates a new service and connects it to the RMI endpoint at the given address. | |
| Static Public Member Functions inherited from RequireMakeShared< PriceLevelService > | |
| static auto | createShared (Args &&...args) |
| Creates a smart pointer to an object. | |
Static Public Attributes | |
| static constexpr std::string_view | GRANULARITY_ATTRIBUTE_KEY = "gr" |
| The key of the custom CandleSymbol attribute that specifies the granularity of the price level updates in the response, in seconds (AAPL{=d,gr=s} or AAPL{=d,gr=10}). | |
The client of the Order Reconstruction Service (ORCS): the price levels (Order events) and the quotes (Quote events) of a symbol for a period of time.
| void PriceLevelService::close | ( | ) |
Closes (disconnects) the service.
The next calls of close() do nothing.
Referenced by ~PriceLevelService().
|
static |
Creates a new service and connects it to the RMI endpoint at the given address.
| address | The address of the RMI endpoint of the service. To pass an authorization token, add [login=entitle:<token>] to the address. |
| std::shared_ptr< AuthOrderSource > PriceLevelService::getAuthOrderSource | ( | ) | const |
Returns the order sources and the symbols of each order source available to the client, filtered according to the client permissions.
It contains only the existing data as of now (no delisted symbols, for example).
| std::vector< std::shared_ptr< Order > > PriceLevelService::getOrders | ( | const CandleSymbol & | candleSymbol, |
| const OrderSource & | orderSource, | ||
| std::int64_t | from, | ||
| std::int64_t | to ) const |
Returns the price levels of the given CandleSymbol and OrderSource within the given from and to times, sorted by time.
The caller identifier is the default one of the Graal SDK ("dxfg").
| candleSymbol | The candle symbol to request. |
| orderSource | The order source to request. |
| from | The time in UTC (milliseconds since the Unix epoch) to request from. |
| to | The time in UTC (milliseconds since the Unix epoch) to request to. |
| std::vector< std::shared_ptr< Order > > PriceLevelService::getOrders | ( | const CandleSymbol & | candleSymbol, |
| const OrderSource & | orderSource, | ||
| std::int64_t | from, | ||
| std::int64_t | to, | ||
| StringParam | caller ) const |
Returns the price levels of the given CandleSymbol and OrderSource within the given from and to times, sorted by time.
The candle symbol shall contain a supported CandlePeriod and the custom attribute PriceLevelService::GRANULARITY_ATTRIBUTE_KEY ("gr") with the granularity in seconds (the minimal value is 1 second). If the period or the granularity is not supported by the service, the list is empty.
| candleSymbol | The candle symbol to request. |
| orderSource | The order source to request. |
| from | The time in UTC (milliseconds since the Unix epoch) to request from. |
| to | The time in UTC (milliseconds since the Unix epoch) to request to. |
| caller | The caller identifier. |
| std::vector< std::shared_ptr< Quote > > PriceLevelService::getQuotes | ( | const CandleSymbol & | candleSymbol, |
| std::int64_t | from, | ||
| std::int64_t | to ) const |
Returns the quotes of the given CandleSymbol within the given from and to times, sorted by time.
The caller identifier is the default one of the Graal SDK ("dxfg").
| candleSymbol | The candle symbol to request. |
| from | The time in UTC (milliseconds since the Unix epoch) to request from. |
| to | The time in UTC (milliseconds since the Unix epoch) to request to. |
| std::vector< std::shared_ptr< Quote > > PriceLevelService::getQuotes | ( | const CandleSymbol & | candleSymbol, |
| std::int64_t | from, | ||
| std::int64_t | to, | ||
| StringParam | caller ) const |
Returns the quotes of the given CandleSymbol within the given from and to times, sorted by time.
| candleSymbol | The candle symbol to request. |
| from | The time in UTC (milliseconds since the Unix epoch) to request from. |
| to | The time in UTC (milliseconds since the Unix epoch) to request to. |
| caller | The caller identifier. |