From 01017e2ca66be42fc2933ec4bc8d388b9d4a85f2 Mon Sep 17 00:00:00 2001 From: Manjeet Dahiya Date: Wed, 1 Sep 2010 12:40:55 +0000 Subject: no need of separate classes, nested into one main class --- src/QXmppServiceInfo.h | 37 ++++++++++++++++++------------------- 1 file changed, 18 insertions(+), 19 deletions(-) (limited to 'src/QXmppServiceInfo.h') diff --git a/src/QXmppServiceInfo.h b/src/QXmppServiceInfo.h index 51e71282..0b752371 100644 --- a/src/QXmppServiceInfo.h +++ b/src/QXmppServiceInfo.h @@ -27,39 +27,38 @@ #include #include -/// \brief The QXmppServiceRecord class represents a DNS SRV record. +/// \brief The QXmppServiceInfo class provides static methods for DNS SRV lookups. /// -class QXmppServiceRecord +class QXmppServiceInfo { public: - QXmppServiceRecord(); - - QString hostName() const; - void setHostName(const QString &hostName); + /// \brief Represents a DNS SRV record + /// + class SrvRecord + { + public: + SrvRecord(); - quint16 port() const; - void setPort(quint16 port); + QString hostName() const; + void setHostName(const QString &hostName); -private: - QString host_name; - quint16 host_port; -}; + quint16 port() const; + void setPort(quint16 port); -/// \brief The QXmppServiceInfo class provides static methods for DNS SRV lookups. -/// + private: + QString host_name; + quint16 host_port; + }; -class QXmppServiceInfo -{ -public: QString errorString() const; - QList records() const; + QList records() const; static QXmppServiceInfo fromName(const QString &dname); private: QString m_errorString; - QList m_records; + QList m_records; }; #endif -- cgit v1.2.3