gloox
1.0
|
00001 /* 00002 Copyright (c) 2006-2009 by Jakob Schroeter <js@camaya.net> 00003 This file is part of the gloox library. http://camaya.net/gloox 00004 00005 This software is distributed under a license. The full license 00006 agreement can be found in the file LICENSE in this distribution. 00007 This software may not be copied, modified, sold or distributed 00008 other than expressed in the named license agreement. 00009 00010 This software is distributed without any warranty. 00011 */ 00012 00013 00014 #ifndef OOB_H__ 00015 #define OOB_H__ 00016 00017 #include "gloox.h" 00018 #include "stanzaextension.h" 00019 00020 #include <string> 00021 00022 namespace gloox 00023 { 00024 00025 class Tag; 00026 00035 class GLOOX_API OOB : public StanzaExtension 00036 { 00037 public: 00045 OOB( const std::string& url, const std::string& description, bool iqext ); 00046 00053 OOB( const Tag* tag ); 00054 00058 virtual ~OOB(); 00059 00064 const std::string& url() const { return m_url; } 00065 00070 const std::string& desc() const { return m_desc; } 00071 00072 // reimplemented from StanzaExtension 00073 virtual const std::string& filterString() const; 00074 00075 // reimplemented from StanzaExtension 00076 virtual StanzaExtension* newInstance( const Tag* tag ) const 00077 { 00078 return new OOB( tag ); 00079 } 00080 00081 // reimplemented from StanzaExtension 00082 Tag* tag() const; 00083 00084 // reimplemented from StanzaExtension 00085 virtual StanzaExtension* clone() const 00086 { 00087 return new OOB( *this ); 00088 } 00089 00090 private: 00091 std::string m_xmlns; 00092 std::string m_url; 00093 std::string m_desc; 00094 bool m_iqext; 00095 bool m_valid; 00096 00097 }; 00098 00099 } 00100 00101 #endif // OOB_H__