C++ Client-Side SDK
LaunchDarkly SDK
data_source_config.hpp
1 #pragma once
2 
3 #include <launchdarkly/config/shared/sdks.hpp>
4 
5 #include <chrono>
6 #include <optional>
7 #include <string>
8 #include <variant>
9 
10 namespace launchdarkly::config::shared::built {
11 
12 template <typename SDK>
14 
15 template <>
17  std::chrono::milliseconds initial_reconnect_delay;
18  std::string streaming_path;
19 };
20 
21 template <>
23  std::chrono::milliseconds initial_reconnect_delay;
24  std::string streaming_path;
25  std::optional<std::string> filter_key;
26 };
27 
28 inline bool operator==(StreamingConfig<ServerSDK> const& lhs,
29  StreamingConfig<ServerSDK> const& rhs) {
30  return lhs.initial_reconnect_delay == rhs.initial_reconnect_delay &&
31  lhs.streaming_path == rhs.streaming_path &&
32  lhs.filter_key == rhs.filter_key;
33 }
34 
35 template <typename SDK>
37 
38 template <>
40  std::chrono::seconds poll_interval;
41  std::string polling_get_path;
42  std::string polling_report_path;
43  std::chrono::seconds min_polling_interval;
44 };
45 
46 template <>
48  std::chrono::seconds poll_interval;
49  std::string polling_get_path;
50  std::chrono::seconds min_polling_interval;
51  std::optional<std::string> filter_key;
52 };
53 
54 template <typename SDK>
56 
57 template <>
59  std::variant<StreamingConfig<ClientSDK>, PollingConfig<ClientSDK>> method;
60 
61  bool with_reasons;
62  bool use_report;
63 };
64 
65 template <>
67 } // namespace launchdarkly::config::shared::built
Definition: data_source_config.hpp:55
Definition: data_source_config.hpp:36
Definition: data_source_config.hpp:13