15#include "softwareversion.h"
23 const std::string&
os )
34 Tag* t =
tag->findChild(
"name" );
38 t =
tag->findChild(
"version" );
40 m_version = t->
cdata();
42 t =
tag->findChild(
"os" );
53 static const std::string filter =
"/iq/query[@xmlns='" +
XMLNS_VERSION +
"']";
59 Tag* t =
new Tag(
"query" );
63 new Tag( t,
"name", m_name );
65 if( !m_version.empty() )
66 new Tag( t,
"version", m_version );
69 new Tag( t,
"os", m_os );
virtual ~SoftwareVersion()
const std::string & name() const
const std::string & version() const
const std::string & os() const
virtual const std::string & filterString() const
SoftwareVersion(const std::string &name, const std::string &version, const std::string &os)
virtual Tag * tag() const
StanzaExtension(int type)
This is an abstraction of an XML element.
const std::string cdata() const
bool setXmlns(const std::string &xmlns, const std::string &prefix=EmptyString)
The namespace for the gloox library.
const std::string XMLNS_VERSION