dxFeed Graal Native SDK 3.9.0
Loading...
Searching...
No Matches
PriceLevelChecker' functions

Functions

int32_t dxfg_PriceLevelChecker_validate (graal_isolatethread_t *thread, dxfg_event_type_list *orders, int64_t timeGapBound, int32_t printQuotes, DXFG_OUT int32_t *isValid)

Detailed Description

Function Documentation

◆ dxfg_PriceLevelChecker_validate()

int32_t dxfg_PriceLevelChecker_validate ( graal_isolatethread_t * thread,
dxfg_event_type_list * orders,
int64_t timeGapBound,
int32_t printQuotes,
DXFG_OUT int32_t * isValid )

Validates the order list.

PriceLevelChecker: utility class to check the consistency of an Order list in terms that in each time bid price is lower than ask price. There is additional information may be gathered during the check:

  • Gap detection for subsequent events. In other words, if there was a pause between orders greater than timeGapBound.
  • Last bid and ask change with the minimal period of 1 second.
  • Spike in quotes.

Frees the list of map entries (OrderSource, [Symbol, ...]).

Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]ordersThe list of orders.
[in]timeGapBoundThe gap bound to check.
[in]printQuotesEnable a quotes logging during the check.
[out]isValidSet to 1 if orders are valid, 0 otherwise.
Returns
DXFG_EXECUTE_SUCCESSFULLY (0) on successful function execution or DXFG_EXECUTE_FAIL (-1) on error. Use dxfg_get_and_clear_thread_exception_t() to determine if an exception was thrown.