summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2012-06-17 08:16:04 (GMT)
committerRemko Tronçon <git@el-tramo.be>2012-06-17 08:16:04 (GMT)
commit2b020adbee0be770c52f31699db793413d051bb3 (patch)
treee0beed93ef6e5714d28248abc3b6b9328a846ac1 /Swiften
parentd46097d2c30a0eafde1f1c9d98cb3b20896c4682 (diff)
downloadswift-2b020adbee0be770c52f31699db793413d051bb3.zip
swift-2b020adbee0be770c52f31699db793413d051bb3.tar.bz2
CachingNameOnlyDomainNameResolver -> CachingDomainNameResolver.
Diffstat (limited to 'Swiften')
-rw-r--r--Swiften/Network/BOSHConnectionPool.cpp4
-rw-r--r--Swiften/Network/BOSHConnectionPool.h4
-rw-r--r--Swiften/Network/CachingDomainNameResolver.cpp30
-rw-r--r--Swiften/Network/CachingDomainNameResolver.h (renamed from Swiften/Network/CachingNameOnlyDomainNameResolver.h)6
-rw-r--r--Swiften/Network/CachingNameOnlyDomainNameResolver.cpp30
-rw-r--r--Swiften/Network/SConscript2
6 files changed, 38 insertions, 38 deletions
diff --git a/Swiften/Network/BOSHConnectionPool.cpp b/Swiften/Network/BOSHConnectionPool.cpp
index 293bc1a..d0aa622 100644
--- a/Swiften/Network/BOSHConnectionPool.cpp
+++ b/Swiften/Network/BOSHConnectionPool.cpp
@@ -14,7 +14,7 @@
#include <Swiften/Base/SafeString.h>
#include <Swiften/Network/TLSConnectionFactory.h>
#include <Swiften/Network/HTTPConnectProxiedConnectionFactory.h>
-#include <Swiften/Network/CachingNameOnlyDomainNameResolver.h>
+#include <Swiften/Network/CachingDomainNameResolver.h>
namespace Swift {
BOSHConnectionPool::BOSHConnectionPool(const URL& boshURL, DomainNameResolver* realResolver, ConnectionFactory* connectionFactoryParameter, XMLParserFactory* parserFactory, TLSContextFactory* tlsFactory, TimerFactory* timerFactory, EventLoop* eventLoop, const std::string& to, unsigned long long initialRID, const URL& boshHTTPConnectProxyURL, const SafeString& boshHTTPConnectProxyAuthID, const SafeString& boshHTTPConnectProxyAuthPassword) :
@@ -40,7 +40,7 @@ BOSHConnectionPool::BOSHConnectionPool(const URL& boshURL, DomainNameResolver* r
connectionFactory = new TLSConnectionFactory(tlsFactory, connectionFactory);
myConnectionFactories.push_back(connectionFactory);
}
- resolver = new CachingNameOnlyDomainNameResolver(realResolver, eventLoop);
+ resolver = new CachingDomainNameResolver(realResolver, eventLoop);
createConnection();
}
diff --git a/Swiften/Network/BOSHConnectionPool.h b/Swiften/Network/BOSHConnectionPool.h
index 00c1e65..028a1f3 100644
--- a/Swiften/Network/BOSHConnectionPool.h
+++ b/Swiften/Network/BOSHConnectionPool.h
@@ -15,7 +15,7 @@
namespace Swift {
class HTTPConnectProxiedConnectionFactory;
class TLSConnectionFactory;
- class CachingNameOnlyDomainNameResolver;
+ class CachingDomainNameResolver;
class EventLoop;
class BOSHConnectionPool : public boost::bsignals::trackable {
@@ -64,6 +64,6 @@ namespace Swift {
int restartCount;
bool pendingRestart;
std::vector<ConnectionFactory*> myConnectionFactories;
- CachingNameOnlyDomainNameResolver* resolver;
+ CachingDomainNameResolver* resolver;
};
}
diff --git a/Swiften/Network/CachingDomainNameResolver.cpp b/Swiften/Network/CachingDomainNameResolver.cpp
new file mode 100644
index 0000000..4cf8286
--- /dev/null
+++ b/Swiften/Network/CachingDomainNameResolver.cpp
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2012 Kevin Smith
+ * Licensed under the GNU General Public License v3.
+ * See Documentation/Licenses/GPLv3.txt for more information.
+ */
+
+#include <Swiften/Network/CachingDomainNameResolver.h>
+
+#include <boost/smart_ptr/make_shared.hpp>
+
+namespace Swift {
+
+CachingDomainNameResolver::CachingDomainNameResolver(DomainNameResolver* realResolver, EventLoop*) : realResolver(realResolver) {
+}
+
+CachingDomainNameResolver::~CachingDomainNameResolver() {
+
+}
+
+DomainNameServiceQuery::ref CachingDomainNameResolver::createServiceQuery(const std::string& name) {
+ //TODO: Cache
+ return realResolver->createServiceQuery(name);
+}
+
+DomainNameAddressQuery::ref CachingDomainNameResolver::createAddressQuery(const std::string& name) {
+ //TODO: Cache
+ return realResolver->createAddressQuery(name);
+}
+
+}
diff --git a/Swiften/Network/CachingNameOnlyDomainNameResolver.h b/Swiften/Network/CachingDomainNameResolver.h
index 2919271..66b4d68 100644
--- a/Swiften/Network/CachingNameOnlyDomainNameResolver.h
+++ b/Swiften/Network/CachingDomainNameResolver.h
@@ -17,10 +17,10 @@
namespace Swift {
class EventLoop;
- class CachingNameOnlyDomainNameResolver : public DomainNameResolver {
+ class CachingDomainNameResolver : public DomainNameResolver {
public:
- CachingNameOnlyDomainNameResolver(DomainNameResolver* realResolver, EventLoop* eventLoop);
- ~CachingNameOnlyDomainNameResolver();
+ CachingDomainNameResolver(DomainNameResolver* realResolver, EventLoop* eventLoop);
+ ~CachingDomainNameResolver();
virtual DomainNameServiceQuery::ref createServiceQuery(const std::string& name);
virtual DomainNameAddressQuery::ref createAddressQuery(const std::string& name);
diff --git a/Swiften/Network/CachingNameOnlyDomainNameResolver.cpp b/Swiften/Network/CachingNameOnlyDomainNameResolver.cpp
deleted file mode 100644
index 8a2936a..0000000
--- a/Swiften/Network/CachingNameOnlyDomainNameResolver.cpp
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Copyright (c) 2012 Kevin Smith
- * Licensed under the GNU General Public License v3.
- * See Documentation/Licenses/GPLv3.txt for more information.
- */
-
-#include <Swiften/Network/CachingNameOnlyDomainNameResolver.h>
-
-#include <boost/smart_ptr/make_shared.hpp>
-
-namespace Swift {
-
-CachingNameOnlyDomainNameResolver::CachingNameOnlyDomainNameResolver(DomainNameResolver* realResolver, EventLoop*) : realResolver(realResolver) {
-}
-
-CachingNameOnlyDomainNameResolver::~CachingNameOnlyDomainNameResolver() {
-
-}
-
-DomainNameServiceQuery::ref CachingNameOnlyDomainNameResolver::createServiceQuery(const std::string& name) {
- //FIXME: Cache
- return realResolver->createServiceQuery(name);
-}
-
-DomainNameAddressQuery::ref CachingNameOnlyDomainNameResolver::createAddressQuery(const std::string& name) {
- //FIXME: Cache
- return realResolver->createAddressQuery(name);
-}
-
-}
diff --git a/Swiften/Network/SConscript b/Swiften/Network/SConscript
index ea45149..b742bfe 100644
--- a/Swiften/Network/SConscript
+++ b/Swiften/Network/SConscript
@@ -15,7 +15,7 @@ sourceList = [
"BoostIOServiceThread.cpp",
"BOSHConnection.cpp",
"BOSHConnectionPool.cpp",
- "CachingNameOnlyDomainNameResolver.cpp",
+ "CachingDomainNameResolver.cpp",
"ConnectionFactory.cpp",
"ConnectionServer.cpp",
"ConnectionServerFactory.cpp",