+//! Stores all editable information about a network (as opposed to runtime state).
+struct NetworkInfo {
+ // set some default values, note that this does not initialize e.g. name and id
+ NetworkInfo();
+
+ NetworkId networkId;
+ QString networkName;
+ IdentityId identity;
+
+ bool useCustomEncodings; // not used!
+ QByteArray codecForServer;
+ QByteArray codecForEncoding;
+ QByteArray codecForDecoding;
+
+ Network::ServerList serverList;
+ bool useRandomServer;
+
+ QStringList perform;
+
+ bool useAutoIdentify;
+ QString autoIdentifyService;
+ QString autoIdentifyPassword;
+
+ bool useSasl;
+ QString saslAccount;
+ QString saslPassword;
+
+ bool useAutoReconnect;
+ quint32 autoReconnectInterval;
+ quint16 autoReconnectRetries;
+ bool unlimitedReconnectRetries;
+ bool rejoinChannels;
+
+ bool operator==(const NetworkInfo &other) const;
+ bool operator!=(const NetworkInfo &other) const;
+};
+
+QDataStream &operator<<(QDataStream &out, const NetworkInfo &info);
+QDataStream &operator>>(QDataStream &in, NetworkInfo &info);
+QDebug operator<<(QDebug dbg, const NetworkInfo &i);
+Q_DECLARE_METATYPE(NetworkInfo)
+
+QDataStream &operator<<(QDataStream &out, const Network::Server &server);
+QDataStream &operator>>(QDataStream &in, Network::Server &server);
+QDebug operator<<(QDebug dbg, const Network::Server &server);
+Q_DECLARE_METATYPE(Network::Server)
+