summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2010-12-04 12:43:57 (GMT)
committerRemko Tronçon <git@el-tramo.be>2010-12-04 13:24:48 (GMT)
commitbbf8a5fcb47d649bdcee1b2122eaa76f2c914ef7 (patch)
tree3cef6ffab06f263ad6f5dc3df5d7ba065223f84e /Swiften/Parser/PayloadParserFactory.h
parentebd2b8b8a2f1ad2812543c5350c0acf0a5b8c188 (diff)
downloadswift-bbf8a5fcb47d649bdcee1b2122eaa76f2c914ef7.zip
swift-bbf8a5fcb47d649bdcee1b2122eaa76f2c914ef7.tar.bz2
Added EchoPayload parserialement.
Diffstat (limited to 'Swiften/Parser/PayloadParserFactory.h')
-rw-r--r--Swiften/Parser/PayloadParserFactory.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/Swiften/Parser/PayloadParserFactory.h b/Swiften/Parser/PayloadParserFactory.h
index d97595b..3d647c6 100644
--- a/Swiften/Parser/PayloadParserFactory.h
+++ b/Swiften/Parser/PayloadParserFactory.h
@@ -4,8 +4,7 @@
* See Documentation/Licenses/GPLv3.txt for more information.
*/
-#ifndef SWIFTEN_PAYLOADPARSERFACTORY_H
-#define SWIFTEN_PAYLOADPARSERFACTORY_H
+#pragma once
#include "Swiften/Parser/AttributeMap.h"
@@ -13,13 +12,21 @@ namespace Swift {
class String;
class PayloadParser;
+ /**
+ * A factory for PayloadParsers.
+ */
class PayloadParserFactory {
public:
virtual ~PayloadParserFactory();
+ /**
+ * Checks whether this factory can parse the given top-level element in the given namespace (with the given attributes).
+ */
virtual bool canParse(const String& element, const String& ns, const AttributeMap& attributes) const = 0;
+
+ /**
+ * Creates a new payload parser.
+ */
virtual PayloadParser* createPayloadParser() = 0;
};
}
-
-#endif