C++ Server-Side SDK
LaunchDarkly SDK
Public Member Functions | List of all members
launchdarkly::config::shared::builders::PollingBuilder< SDK > Class Template Reference

#include <data_source_builder.hpp>

Public Member Functions

PollingBuilderPollInterval (std::chrono::seconds poll_interval)
 
template<typename T = SDK>
std::enable_if_t< is_server_sdk< T >::value, PollingBuilder & > Filter (std::string filter_key)
 
built::PollingConfig< SDK > Build () const
 

Detailed Description

template<typename SDK>
class launchdarkly::config::shared::builders::PollingBuilder< SDK >

Contains methods for configuring the polling data source.

Member Function Documentation

◆ Build()

Build the polling config. Used internal to the SDK.

Returns
The built config.

◆ Filter()

template<typename SDK >
template<typename T = SDK>
std::enable_if_t<is_server_sdk<T>::value, PollingBuilder&> launchdarkly::config::shared::builders::PollingBuilder< SDK >::Filter ( std::string  filter_key)
inline

Sets the filter key for the polling connection.

By default, the SDK is able to evaluate all flags in an environment.

If this is undesirable - for example, because the environment contains thousands of flags, but this application only needs to evaluate a smaller, known subset - then a filter may be setup in LaunchDarkly, and the filter's key specified here.

Evaluations for flags that aren't part of the filtered environment will return default values.

Parameters
filter_keyThe filter key. If the key is malformed or nonexistent, then a full LaunchDarkly environment will be fetched. In the case of a malformed key, the SDK will additionally log a runtime error.
Returns
Reference to this builder.

◆ PollInterval()

template<typename SDK >
PollingBuilder< SDK > & launchdarkly::config::shared::builders::PollingBuilder< SDK >::PollInterval ( std::chrono::seconds  poll_interval)

Sets the interval at which the SDK will poll for feature flag updates.

Parameters
poll_intervalThe polling interval.
Returns
Reference to this builder.

The documentation for this class was generated from the following files: