summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Component/Component.cpp')
-rw-r--r--Swiften/Component/Component.cpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/Swiften/Component/Component.cpp b/Swiften/Component/Component.cpp
new file mode 100644
index 0000000..af3802d
--- /dev/null
+++ b/Swiften/Component/Component.cpp
@@ -0,0 +1,27 @@
+/*
+ * Copyright (c) 2010 Remko Tronçon
+ * Licensed under the GNU General Public License v3.
+ * See Documentation/Licenses/GPLv3.txt for more information.
+ */
+
+#include "Swiften/Component/Component.h"
+
+#include "Swiften/Queries/Responders/SoftwareVersionResponder.h"
+
+namespace Swift {
+
+Component::Component(const JID& jid, const String& secret) : CoreComponent(jid, secret) {
+ softwareVersionResponder = new SoftwareVersionResponder(getIQRouter());
+ softwareVersionResponder->start();
+}
+
+Component::~Component() {
+ softwareVersionResponder->stop();
+ delete softwareVersionResponder;
+}
+
+void Component::setSoftwareVersion(const String& name, const String& version) {
+ softwareVersionResponder->setVersion(name, version);
+}
+
+}