8 #include <boost/algorithm/string.hpp>
10 using namespace boost::asio::ip;
11 using namespace boost::property_tree;
15 ToAddr(
""), FromAddr(
""), NodeAddr(
""), logUVE(false), auth_enabled(false),
16 path_to_server_cert(
""), path_to_server_priv_key(
""), path_to_ca_cert(
""),
18 xmpp_hold_time(90), dscp_value(0), isClient_(isClient) {
40 XmppConfigData::XmppChannelConfigMap::const_iterator icurr =
42 XmppConfigData::XmppChannelConfigMap::const_iterator inext =
45 while (icurr != n_current.end() && inext != n_future.end()) {
46 if (icurr->first < inext->first) {
49 }
else if (icurr->first > inext->first) {
50 obs(
DF_ADD, NULL, inext->second);
53 int cmp = icurr->second->CompareTo(*inext->second);
55 obs(
DF_CHANGE, icurr->second, inext->second);
61 for (; icurr != n_current.end(); ++icurr) {
64 for (; inext != n_future.end(); ++inext) {
65 obs(
DF_ADD, NULL, inext->second);
boost::asio::ip::tcp::endpoint endpoint
void PeerConfigDiff(PeerDiffObserver obs) const
int CompareTo(const XmppChannelConfig &rhs) const
std::unique_ptr< const XmppConfigData > future_
std::unique_ptr< const XmppConfigData > current_
XmppChannelConfig(bool isClient=false)
boost::function< void(DiffType, const XmppChannelConfig *, const XmppChannelConfig *)> PeerDiffObserver
boost::ptr_map< boost::asio::ip::tcp::endpoint, XmppChannelConfig > XmppChannelConfigMap
void SetFuture(const XmppConfigData *future)