60 Stanza(
const std::string& name,
const std::string& cdata =
"",
61 const std::string& xmllang =
"default",
bool incoming =
false );
78 virtual const JID&
from()
const {
return m_from; }
84 virtual const JID&
to()
const {
return m_to; }
90 virtual const std::string&
id()
const {
return m_id; }
96 virtual const std::string&
xmlns()
const {
return m_xmlns; }
111 virtual int priority()
const {
return m_priority; }
122 virtual const std::string status(
const std::string& lang =
"default" )
const
123 {
return findLang( m_status, lang ); }
134 virtual const std::string body(
const std::string& lang =
"default" )
const
135 {
return findLang( m_body, lang ); }
146 virtual const std::string subject(
const std::string& lang =
"default" )
const
147 {
return findLang( m_subject, lang ); }
158 virtual const std::string errorText(
const std::string& lang =
"default" )
const
159 {
return findLang( m_errorText, lang ); }
178 virtual const std::string&
thread()
const {
return m_thread; }
185 void setThread(
const std::string& thread ) { m_thread = thread; }
191 const std::string&
xmlLang()
const {
return m_xmllang; }
228 static Stanza* createIqStanza(
const JID& to,
const std::string&
id,
230 const std::string& xmlns =
"",
Tag* tag = 0 );
242 static Stanza* createPresenceStanza(
const JID& to,
const std::string& msg =
"",
244 const std::string& xmllang =
"" );
256 static Stanza* createMessageStanza(
const JID& to,
const std::string& body,
258 const std::string& subject =
"",
const std::string& thread =
"",
259 const std::string& xmllang =
"" );
269 static Stanza* createSubscriptionStanza(
const JID& to,
const std::string& msg =
"",
271 const std::string& xmllang =
"" );
281 Tag *m_stanzaErrorAppCondition;
290 std::string m_thread;
291 std::string m_xmllang;
294 static const std::string findLang(
const StringMap& map,
const std::string& lang );