dxFeed Graal Native SDK 3.16.0-rc1
Loading...
Searching...
No Matches
IndexedEventTxModel

Data Structures

struct  dxfg_indexed_event_tx_model_t
struct  dxfg_indexed_event_tx_model_builder_t
struct  dxfg_indexed_event_tx_model_listener_t

Typedefs

typedef struct dxfg_indexed_event_tx_model_t dxfg_indexed_event_tx_model_t
typedef struct dxfg_indexed_event_tx_model_builder_t dxfg_indexed_event_tx_model_builder_t
typedef struct dxfg_indexed_event_tx_model_listener_t dxfg_indexed_event_tx_model_listener_t
typedef void(*) dxfg_IndexedEventTxModel_Listener_eventsReceived_f(graal_isolatethread_t *thread, dxfg_event_type_list *events, int32_t isSnapshot, void *userData)

Functions

int32_t dxfg_IndexedEventTxModel_newBuilder (graal_isolatethread_t *thread, dxfg_event_clazz_t eventType, DXFG_OUT dxfg_indexed_event_tx_model_builder_t **builder)
int32_t dxfg_IndexedEventTxModel_getIndexedEventSubscriptionSymbol (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_t *model, DXFG_OUT dxfg_symbol_t **symbol)
int32_t dxfg_IndexedEventTxModel_getSymbol (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_t *model, DXFG_OUT const char **symbol)
int32_t dxfg_IndexedEventTxModel_getSource (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_t *model, DXFG_OUT dxfg_indexed_event_source_t **source)
int32_t dxfg_IndexedEventTxModel_getSubscriptionController (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_t *model, DXFG_OUT dxfg_subscription_controller_t **subscriptionController)
int32_t dxfg_IndexedEventTxModel_isClosed (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_t *model, DXFG_OUT int32_t *isClosed)
int32_t dxfg_IndexedEventTxModel_close (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_t *model)
int32_t dxfg_IndexedEventTxModel_Builder_new (graal_isolatethread_t *thread, dxfg_event_clazz_t eventType, DXFG_OUT dxfg_indexed_event_tx_model_builder_t **builder)
int32_t dxfg_IndexedEventTxModel_Builder_withFeed (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, dxfg_feed_t *feed)
int32_t dxfg_IndexedEventTxModel_Builder_withSymbol (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, dxfg_symbol_t *symbol)
int32_t dxfg_IndexedEventTxModel_Builder_withSymbol2 (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, const char *symbol)
int32_t dxfg_IndexedEventTxModel_Builder_withSource (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, dxfg_indexed_event_source_t *source)
int32_t dxfg_IndexedEventTxModel_Listener_new (graal_isolatethread_t *thread, dxfg_IndexedEventTxModel_Listener_eventsReceived_f eventsReceived, void *userData, DXFG_OUT dxfg_indexed_event_tx_model_listener_t **listener)
int32_t dxfg_IndexedEventTxModel_Builder_withListener (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, dxfg_indexed_event_tx_model_listener_t *listener)
int32_t dxfg_IndexedEventTxModel_Builder_withEventsBatchLimit (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, int32_t eventsBatchLimit)
int32_t dxfg_IndexedEventTxModel_Builder_withAggregationPeriod (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, dxfg_time_period_t *aggregationPeriod)
int32_t dxfg_IndexedEventTxModel_Builder_withAggregationPeriodMillis (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, int64_t aggregationPeriod)
int32_t dxfg_IndexedEventTxModel_Builder_withExecutor (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, dxfg_executor_t *executor)
int32_t dxfg_IndexedEventTxModel_Builder_build (graal_isolatethread_t *thread, dxfg_indexed_event_tx_model_builder_t *builder, DXFG_OUT dxfg_indexed_event_tx_model_t **model)

Detailed Description

Typedef Documentation

◆ dxfg_indexed_event_tx_model_builder_t

typedef struct dxfg_indexed_event_tx_model_builder_t dxfg_indexed_event_tx_model_builder_t

The IndexedEventTxModel.Builder instance's handle.

Javadoc

◆ dxfg_indexed_event_tx_model_listener_t

typedef struct dxfg_indexed_event_tx_model_listener_t dxfg_indexed_event_tx_model_listener_t

The IndexedEventTxModel.Listener instance's handle.

Javadoc

◆ dxfg_indexed_event_tx_model_t

typedef struct dxfg_indexed_event_tx_model_t dxfg_indexed_event_tx_model_t

The IndexedEventTxModel instance's handle.

Javadoc

◆ dxfg_IndexedEventTxModel_Listener_eventsReceived_f

typedef void(*) dxfg_IndexedEventTxModel_Listener_eventsReceived_f(graal_isolatethread_t *thread, dxfg_event_type_list *events, int32_t isSnapshot, void *userData)

Invoked when a complete transaction (one or more) is received.

Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]eventsThe list of received events representing one or more completed transactions.
[in]isSnapshottrue (1) if the events form a snapshot; false (0) otherwise.
[in]userDataPassed to the created listener user data.

Function Documentation

◆ dxfg_IndexedEventTxModel_Builder_build()

int32_t dxfg_IndexedEventTxModel_Builder_build ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
DXFG_OUT dxfg_indexed_event_tx_model_t ** model )

Builds a new instance of dxfg_indexed_event_tx_model_t with the provided configuration.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_build() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[out]modelThe created model.
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. Use dxfg_JavaObjectHandler_release() to free the model handle.

◆ dxfg_IndexedEventTxModel_Builder_new()

int32_t dxfg_IndexedEventTxModel_Builder_new ( graal_isolatethread_t * thread,
dxfg_event_clazz_t eventType,
DXFG_OUT dxfg_indexed_event_tx_model_builder_t ** builder )

Constructs a new builder for the specified event type.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_new() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]eventTypeThe type of indexed events processed by the model.
[out]builderA new builder instance handle.
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. Use dxfg_JavaObjectHandler_release() to free the builder handle.

◆ dxfg_IndexedEventTxModel_Builder_withAggregationPeriod()

int32_t dxfg_IndexedEventTxModel_Builder_withAggregationPeriod ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
dxfg_time_period_t * aggregationPeriod )

Sets the aggregation period for data that limits the rate of data notifications. For example, setting the value to 0.1s limits notification to once every 100ms (at most 10 per second). This value can be changed later, after the model has been built using the subscription controller.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withAggregationPeriod() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]aggregationPeriodThe aggregation period for data.
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.

◆ dxfg_IndexedEventTxModel_Builder_withAggregationPeriodMillis()

int32_t dxfg_IndexedEventTxModel_Builder_withAggregationPeriodMillis ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
int64_t aggregationPeriod )

Sets the aggregation period for data that limits the rate of data notifications. For example, setting the value to 100 limits notification to once every 100ms (at most 10 per second). This value can be changed later, after the model has been built using the subscription controller.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withAggregationPeriodMillis() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]aggregationPeriodThe aggregation period for data.
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.

◆ dxfg_IndexedEventTxModel_Builder_withEventsBatchLimit()

int32_t dxfg_IndexedEventTxModel_Builder_withEventsBatchLimit ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
int32_t eventsBatchLimit )

Sets the maximum number of events in the single notification of dxfg_IndexedEventTxModel_Listener_eventsReceived_f. This value can be exceeded if the size of the received transaction exceeds the set limit. This value can be changed later, after the model has been built using the subscription controller.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withEventsBatchLimit() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]eventsBatchLimitThe notification events limit.
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.

◆ dxfg_IndexedEventTxModel_Builder_withExecutor()

int32_t dxfg_IndexedEventTxModel_Builder_withExecutor ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
dxfg_executor_t * executor )

Sets the executor for processing listener notifications. The default executor for all models is the endpoint's one (see dxfg_DXEndpoint_Builder_withExecutor()). This executor can be changed later, after the model has been built using the subscription controller.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withExecutor() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]executorThe executor instance.
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.

◆ dxfg_IndexedEventTxModel_Builder_withFeed()

int32_t dxfg_IndexedEventTxModel_Builder_withFeed ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
dxfg_feed_t * feed )

Sets the feed for the model being created.

The feed can also be attached later, after the model has been built using the subscription controller.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withFeed() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]feedThe feed.
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.

◆ dxfg_IndexedEventTxModel_Builder_withListener()

int32_t dxfg_IndexedEventTxModel_Builder_withListener ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
dxfg_indexed_event_tx_model_listener_t * listener )

Sets the listener for transaction notifications. The notification is invoked from a separate thread via the executor. The listener cannot be added or changed after the model has been built.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withListener() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]listenerThe model listener.
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.

◆ dxfg_IndexedEventTxModel_Builder_withSource()

int32_t dxfg_IndexedEventTxModel_Builder_withSource ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
dxfg_indexed_event_source_t * source )

Sets the source to subscribe to.

The source cannot be added or changed after the model has been built.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withSource() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]sourceThe specified source.
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.

◆ dxfg_IndexedEventTxModel_Builder_withSymbol()

int32_t dxfg_IndexedEventTxModel_Builder_withSymbol ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
dxfg_symbol_t * symbol )

Sets the subscription symbol and its source (dxfg_indexed_event_subscription_symbol_t) for the model being created.

This symbol and source cannot be added or changed after the model has been built.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withSymbol() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]symbolThe subscription symbol (dxfg_indexed_event_subscription_symbol_t).
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.

◆ dxfg_IndexedEventTxModel_Builder_withSymbol2()

int32_t dxfg_IndexedEventTxModel_Builder_withSymbol2 ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_builder_t * builder,
const char * symbol )

Sets the subscription symbol for the model being created.

The symbol cannot be added or changed after the model has been built.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Builder_withStringSymbol() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]builderThe current builder.
[in]symbolThe subscription symbol.
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.

◆ dxfg_IndexedEventTxModel_close()

int32_t dxfg_IndexedEventTxModel_close ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_t * model )

Closes this model: it is detached from the feed for good and stops the notifications.

Deprecated
Use dxfg_v4_IndexedEventTxModel_close() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]modelThe current model.
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.

◆ dxfg_IndexedEventTxModel_getIndexedEventSubscriptionSymbol()

int32_t dxfg_IndexedEventTxModel_getIndexedEventSubscriptionSymbol ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_t * model,
DXFG_OUT dxfg_symbol_t ** symbol )

Returns the indexed event subscription symbol associated with this model.

Deprecated
Use dxfg_v4_IndexedEventTxModel_getIndexedEventSubscriptionSymbol() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]modelThe current model.
[out]symbolThe indexed event subscription symbol associated with this model.
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. Use dxfg_Symbol_release() to free the symbol.

◆ dxfg_IndexedEventTxModel_getSource()

int32_t dxfg_IndexedEventTxModel_getSource ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_t * model,
DXFG_OUT dxfg_indexed_event_source_t ** source )

Returns the source associated with this model.

Deprecated
Use dxfg_v4_IndexedEventTxModel_getSource() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]modelThe current model.
[out]sourceThe source associated with this model.
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. Use dxfg_IndexedEventSource_release() to free the source.

◆ dxfg_IndexedEventTxModel_getSubscriptionController()

int32_t dxfg_IndexedEventTxModel_getSubscriptionController ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_t * model,
DXFG_OUT dxfg_subscription_controller_t ** subscriptionController )

Returns the subscription controller for the underlying subscription.

Deprecated
Use dxfg_v4_IndexedEventTxModel_getSubscriptionController() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]modelThe current model.
[out]subscriptionControllerThe subscription controller for the underlying subscription.
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. Use dxfg_JavaObjectHandler_release() to free the SubscriptionController handle.

◆ dxfg_IndexedEventTxModel_getSymbol()

int32_t dxfg_IndexedEventTxModel_getSymbol ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_t * model,
DXFG_OUT const char ** symbol )

Returns the symbol associated with this model.

Deprecated
Use dxfg_v4_IndexedEventTxModel_getSymbol() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]modelThe current model.
[out]symbolThe symbol associated with this model.
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. Use dxfg_String_release() to free the symbol.

◆ dxfg_IndexedEventTxModel_isClosed()

int32_t dxfg_IndexedEventTxModel_isClosed ( graal_isolatethread_t * thread,
dxfg_indexed_event_tx_model_t * model,
DXFG_OUT int32_t * isClosed )

Returns whether this model is closed.

Deprecated
Use dxfg_v4_IndexedEventTxModel_isClosed() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]modelThe current model.
[out]isClosedtrue (1) if this model is closed; false (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.

◆ dxfg_IndexedEventTxModel_Listener_new()

int32_t dxfg_IndexedEventTxModel_Listener_new ( graal_isolatethread_t * thread,
dxfg_IndexedEventTxModel_Listener_eventsReceived_f eventsReceived,
void * userData,
DXFG_OUT dxfg_indexed_event_tx_model_listener_t ** listener )

Creates a new listener for the model.

Deprecated
Use dxfg_v4_IndexedEventTxModel_Listener_new() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]eventsReceivedThe callback function pointer.
[in]userDataThe user data which will be passed to callback.
[out]listenerThe new listener handle.
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. Use dxfg_JavaObjectHandler_release() to free the listener handle.

◆ dxfg_IndexedEventTxModel_newBuilder()

int32_t dxfg_IndexedEventTxModel_newBuilder ( graal_isolatethread_t * thread,
dxfg_event_clazz_t eventType,
DXFG_OUT dxfg_indexed_event_tx_model_builder_t ** builder )

Factory method to create a new builder for this model.

Deprecated
Use dxfg_v4_IndexedEventTxModel_newBuilder() (experimental).
Parameters
[in]threadThe current GraalVM Isolate's thread.
[in]eventTypeThe type of indexed events processed by the model.
[out]builderA new builder instance handle.
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. Use dxfg_JavaObjectHandler_release() to free the builder handle.