summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Network/DomainNameResolver.h')
-rw-r--r--Swiften/Network/DomainNameResolver.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/Swiften/Network/DomainNameResolver.h b/Swiften/Network/DomainNameResolver.h
new file mode 100644
index 0000000..c7736b1
--- /dev/null
+++ b/Swiften/Network/DomainNameResolver.h
@@ -0,0 +1,27 @@
+#ifndef SWIFTEN_DOMAINNAMERESOLVER_H
+#define SWIFTEN_DOMAINNAMERESOLVER_H
+
+#include <string>
+
+#include "Swiften/Base/String.h"
+#include "Swiften/Network/HostAddress.h"
+#include "Swiften/Network/HostAddressPort.h"
+
+namespace Swift {
+ class String;
+
+ class DomainNameResolver {
+ public:
+ DomainNameResolver();
+ virtual ~DomainNameResolver();
+
+ HostAddressPort resolve(const String& domain);
+
+ private:
+ virtual HostAddressPort resolveDomain(const std::string& domain);
+ HostAddressPort resolveXMPPService(const std::string& domain);
+ HostAddress resolveHostName(const std::string& hostName);
+ };
+}
+
+#endif