C++ Client-Side SDK
LaunchDarkly SDK
|
#include <config_builder.hpp>
Public Types | |
using | Result = Config< SDK > |
using | EndpointsBuilder = launchdarkly::config::shared::builders::EndpointsBuilder< SDK > |
using | EventsBuilder = launchdarkly::config::shared::builders::EventsBuilder< SDK > |
using | DataSourceBuilder = launchdarkly::config::shared::builders::DataSourceBuilder< SDK > |
using | HttpPropertiesBuilder = launchdarkly::config::shared::builders::HttpPropertiesBuilder< SDK > |
using | PersistenceBuilder = launchdarkly::config::shared::builders::PersistenceBuilder< SDK > |
using | LoggingBuilder = launchdarkly::config::shared::builders::LoggingBuilder |
Public Member Functions | |
ConfigBuilder (std::string sdk_key) | |
EndpointsBuilder & | ServiceEndpoints () |
AppInfoBuilder & | AppInfo () |
ConfigBuilder & | Offline (bool offline) |
EventsBuilder & | Events () |
DataSourceBuilder & | DataSource () |
HttpPropertiesBuilder & | HttpProperties () |
LoggingBuilder & | Logging () |
PersistenceBuilder & | Persistence () |
tl::expected< Result, Error > | Build () const |
ConfigBuilder allows for creation of a Configuration object for use in a Client.
SDK | Type of SDK. |
|
explicit |
A minimal configuration consists of a LaunchDarkly SDK Key.
sdk_key | SDK Key. |
AppInfoBuilder & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::AppInfo |
To include metadata about the application that is utilizing the SDK, pass in an AppInfoBuilder.
builder | An AppInfoBuilder. |
tl::expected< typename ConfigBuilder< SDK >::Result, Error > launchdarkly::config::shared::builders::ConfigBuilder< SDK >::Build |
Builds a Configuration, suitable for passing into an instance of Client.
ConfigBuilder< SDK >::DataSourceBuilder & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::DataSource |
Sets the configuration of the component that receives feature flag data from LaunchDarkly.
builder | A DataSourceConfig builder. |
ConfigBuilder< SDK >::EventsBuilder & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::Events |
To tune settings related to event generation and delivery, pass an EventsBuilder.
builder | An EventsBuilder. |
ConfigBuilder< SDK >::HttpPropertiesBuilder & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::HttpProperties |
Sets the SDK's networking configuration, using an HttpPropertiesBuilder. The builder has methods for setting individual HTTP-related properties.
builder | A HttpPropertiesBuilder builder. |
LoggingBuilder & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::Logging |
Sets the logging configuration for the SDK.
builder | A Logging builder. |
ConfigBuilder< SDK > & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::Offline | ( | bool | offline | ) |
Enables or disables "Offline" mode. True means Offline mode is enabled.
offline | True if the SDK should operate in Offline mode. |
PersistenceBuilder< SDK > & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::Persistence |
Sets the persistence configuration for the SDK.
builder | A persistence builder. |
ConfigBuilder< SDK >::EndpointsBuilder & launchdarkly::config::shared::builders::ConfigBuilder< SDK >::ServiceEndpoints |
To customize the ServiceEndpoints the SDK uses for streaming, polling, and events, pass in an EndpointsBuilder.
builder | An EndpointsBuilder. |