diff options
Diffstat (limited to 'Swiften/Parser/PayloadParsers/MAMResultParser.h')
-rw-r--r-- | Swiften/Parser/PayloadParsers/MAMResultParser.h | 49 |
1 files changed, 24 insertions, 25 deletions
diff --git a/Swiften/Parser/PayloadParsers/MAMResultParser.h b/Swiften/Parser/PayloadParsers/MAMResultParser.h index f0c9ee5..e68e365 100644 --- a/Swiften/Parser/PayloadParsers/MAMResultParser.h +++ b/Swiften/Parser/PayloadParsers/MAMResultParser.h @@ -1,40 +1,39 @@ /* - * Copyright (c) 2014 Isode Limited. + * Copyright (c) 2014-2016 Isode Limited. * All rights reserved. * See the COPYING file for more information. */ #pragma once +#include <memory> #include <string> -#include <boost/shared_ptr.hpp> - -#include <Swiften/Base/Override.h> #include <Swiften/Base/API.h> +#include <Swiften/Base/Override.h> #include <Swiften/Elements/MAMResult.h> #include <Swiften/Parser/GenericPayloadParser.h> namespace Swift { - class PayloadParserFactoryCollection; - class ForwardedParser; - - class SWIFTEN_API MAMResultParser : public GenericPayloadParser<MAMResult> { - public: - MAMResultParser(PayloadParserFactoryCollection* factories); - - virtual void handleStartElement(const std::string& element, const std::string& ns, const AttributeMap& attributes) SWIFTEN_OVERRIDE; - virtual void handleEndElement(const std::string& element, const std::string&) SWIFTEN_OVERRIDE; - virtual void handleCharacterData(const std::string& data) SWIFTEN_OVERRIDE; - - enum Level { - TopLevel = 0, - PayloadLevel = 1 - }; - - private: - boost::shared_ptr<ForwardedParser> payloadParser_; - PayloadParserFactoryCollection* factories_; - int level_; - }; + class PayloadParserFactoryCollection; + class ForwardedParser; + + class SWIFTEN_API MAMResultParser : public GenericPayloadParser<MAMResult> { + public: + MAMResultParser(PayloadParserFactoryCollection* factories); + + virtual void handleStartElement(const std::string& element, const std::string& ns, const AttributeMap& attributes) SWIFTEN_OVERRIDE; + virtual void handleEndElement(const std::string& element, const std::string&) SWIFTEN_OVERRIDE; + virtual void handleCharacterData(const std::string& data) SWIFTEN_OVERRIDE; + + enum Level { + TopLevel = 0, + PayloadLevel = 1 + }; + + private: + std::shared_ptr<ForwardedParser> payloadParser_; + PayloadParserFactoryCollection* factories_; + int level_; + }; } |