1#ifndef _DITTO_TRANSPORT_CONFIG_
2#define _DITTO_TRANSPORT_CONFIG_
38 return !operator==(other);
111 return !operator==(other);
126 bool operator==(
const Listen &other)
const {
127 return tcp == other.tcp && http == other.http;
129 bool operator!=(
const Listen &other)
const {
return !operator==(other); }
131 NLOHMANN_DEFINE_TYPE_INTRUSIVE(
Listen, tcp, http)
149 return !operator==(other);
152 NLOHMANN_DEFINE_TYPE_INTRUSIVE(BluetoothLeConfig,
enabled)
156#pragma clang diagnostic push
157#pragma clang diagnostic ignored "-Wdeprecated-declarations"
167 bool mdns_enabled =
true;
168 bool multicast_enabled =
true;
170 bool operator==(
const LanConfig &other)
const;
171 bool operator!=(
const LanConfig &other)
const {
return !operator==(other); }
174void from_json(
const nlohmann::json &j, LanConfig &c);
175void to_json(nlohmann::json &j,
const LanConfig &c);
176#pragma clang diagnostic pop
191 bool operator==(
const AwdlConfig &other)
const {
194 bool operator!=(
const AwdlConfig &other)
const {
return !operator==(other); }
196 NLOHMANN_DEFINE_TYPE_INTRUSIVE(AwdlConfig,
enabled)
217 return !operator==(other);
220 NLOHMANN_DEFINE_TYPE_INTRUSIVE(WiFiAwareConfig,
enabled)
251 bool operator==(
const PeerToPeer &other)
const {
255 bool operator!=(
const PeerToPeer &other)
const {
return !operator==(other); }
281 bool operator==(
const Connect &other)
const {
286 bool operator!=(
const Connect &other)
const {
return !operator==(other); }
289void from_json(
const nlohmann::json &j,
Connect &c);
290void to_json(nlohmann::json &j,
const Connect &c);
292const uint32_t NO_PREFERRED_ROUTE_HINT = 0;
338 bool operator==(
const Global &other)
const {
341 bool operator!=(
const Global &other)
const {
return !operator==(other); }
411 bool operator!=(
const TransportConfig &other)
const {
412 return !operator==(other);
Part of the PeerToPeer config that relates to AWDL connections.
Definition TransportConfig.hpp:181
bool enabled
Definition TransportConfig.hpp:189
Part of the PeerToPeer config that relates to Bluetooth LE connections.
Definition TransportConfig.hpp:138
bool enabled
Definition TransportConfig.hpp:143
Part of the TransportConfig that relates to outgoing connections.
Definition TransportConfig.hpp:264
std::set< std::string > tcp_servers
Definition TransportConfig.hpp:269
std::chrono::duration< uint32_t, std::milli > retry_interval
Definition TransportConfig.hpp:279
std::set< std::string > websocket_urls
Definition TransportConfig.hpp:274
Definition TransportConfig.hpp:298
uint32_t sync_group
Definition TransportConfig.hpp:317
uint32_t routing_hint
Definition TransportConfig.hpp:336
Part of the Listen config that relates to incoming HTTP connections.
Definition TransportConfig.hpp:47
std::string tls_key_path
Definition TransportConfig.hpp:91
uint16_t port
Definition TransportConfig.hpp:62
std::string interface_ip
Definition TransportConfig.hpp:57
bool enabled
Definition TransportConfig.hpp:52
std::string tls_certificate_path
Definition TransportConfig.hpp:101
std::string static_content_path
Definition TransportConfig.hpp:81
bool websocket_sync
Definition TransportConfig.hpp:71
Part of the PeerToPeer config that relates to LAN connections.
Definition TransportConfig.hpp:161
bool enabled
Definition TransportConfig.hpp:166
Part of the TransportConfig that relates to incoming connections.
Definition TransportConfig.hpp:121
Part of the TransportConfig that relates to peer-to-peer connections.
Definition TransportConfig.hpp:227
LanConfig lan
Definition TransportConfig.hpp:238
BluetoothLeConfig bluetooth_le
Definition TransportConfig.hpp:233
AwdlConfig awdl
Definition TransportConfig.hpp:243
WiFiAwareConfig wifi_aware
Definition TransportConfig.hpp:249
Part of the Listen config that relates to incoming TCP connections.
Definition TransportConfig.hpp:16
uint16_t port
Definition TransportConfig.hpp:31
std::string interface_ip
Definition TransportConfig.hpp:26
bool enabled
Definition TransportConfig.hpp:21
A configuration object specifying which network transports Ditto should use to sync data.
Definition TransportConfig.hpp:374
PeerToPeer peer_to_peer
Definition TransportConfig.hpp:380
Connect connect
Definition TransportConfig.hpp:385
Global global
Definition TransportConfig.hpp:395
void enable_all_peer_to_peer()
Definition TransportConfig.hpp:400
Listen listen
Definition TransportConfig.hpp:390
Part of the PeerToPeer transport config that applies to WiFi Aware connections.
Definition TransportConfig.hpp:203
bool enabled
Definition TransportConfig.hpp:211