|
C++ Server-Side SDK
LaunchDarkly SDK
|
C bindings for read-only track context passed to afterTrack hooks. More...
#include <launchdarkly/bindings/c/export.h>#include <launchdarkly/server_side/bindings/c/hook_context.h>#include <launchdarkly/bindings/c/value.h>#include <launchdarkly/bindings/c/context.h>#include <stdbool.h>
Go to the source code of this file.
Typedefs | |
| typedef struct p_LDServerSDKTrackSeriesContext * | LDServerSDKTrackSeriesContext |
Functions | |
| LDTrackSeriesContext_Key (LDServerSDKTrackSeriesContext track_context) | |
| Get the event key for the track call. More... | |
| LDTrackSeriesContext_Context (LDServerSDKTrackSeriesContext track_context) | |
| Get the context (user/organization) associated with the track call. More... | |
| LDTrackSeriesContext_Data (LDServerSDKTrackSeriesContext track_context, LDValue *out_data) | |
| Get the application-specified data for the track call, if any. More... | |
| LDTrackSeriesContext_MetricValue (LDServerSDKTrackSeriesContext track_context, double *out_metric_value) | |
| Get the metric value for the track call, if any. More... | |
| LDTrackSeriesContext_HookContext (LDServerSDKTrackSeriesContext track_context) | |
| Get the hook context provided by the caller. More... | |
| LDTrackSeriesContext_EnvironmentId (LDServerSDKTrackSeriesContext track_context) | |
| Get the environment ID, if available. More... | |
C bindings for read-only track context passed to afterTrack hooks.
TrackSeriesContext provides information about a track event to hook callbacks. Most data is read-only and valid only during the callback execution.
LIFETIME AND OWNERSHIP:
| LDTrackSeriesContext_Context | ( | LDServerSDKTrackSeriesContext | track_context | ) |
Get the context (user/organization) associated with the track call.
| track_context | Track context. Must not be NULL. |
| LDTrackSeriesContext_Data | ( | LDServerSDKTrackSeriesContext | track_context, |
| LDValue * | out_data | ||
| ) |
Get the application-specified data for the track call, if any.
LIFETIME: Returns a temporary value valid only during the callback. Do not call LDValue_Free() on the returned value.
USAGE:
| track_context | Track context. Must not be NULL. |
| out_data | Pointer to receive the data value. Must not be NULL. Set to a temporary LDValue (valid only during callback). Do not call LDValue_Free() on this value. Set to NULL if no data was provided. |
| LDTrackSeriesContext_EnvironmentId | ( | LDServerSDKTrackSeriesContext | track_context | ) |
Get the environment ID, if available.
The environment ID is only available after SDK initialization completes. Returns NULL if not yet available.
| track_context | Track context. Must not be NULL. |
| LDTrackSeriesContext_HookContext | ( | LDServerSDKTrackSeriesContext | track_context | ) |
Get the hook context provided by the caller.
This contains application-specific data passed to the track call, such as OpenTelemetry span parents.
| track_context | Track context. Must not be NULL. |
| LDTrackSeriesContext_Key | ( | LDServerSDKTrackSeriesContext | track_context | ) |
Get the event key for the track call.
| track_context | Track context. Must not be NULL. |
| LDTrackSeriesContext_MetricValue | ( | LDServerSDKTrackSeriesContext | track_context, |
| double * | out_metric_value | ||
| ) |
Get the metric value for the track call, if any.
| track_context | Track context. Must not be NULL. |
| out_metric_value | Pointer to receive the metric value. Must not be NULL. Only set if a metric value was provided. |