Class Index | Minimal

Classes


Class jabberwerx.IQ (MINIMAL)


Extends jabberwerx.Stanza.

Represents an <iq/> stanza.

Class Summary
Constructor Attributes Constructor Name and Description
 
jabberwerx.IQ(packet)

Creates a new IQ object.

Fields borrowed from class jabberwerx.Stanza:
timestamp
Method Summary
Method Attributes Method Name and Description
 

Retrieves the payload for this IQ.

 
reply(payload)

Generates a reply IQ from this IQ.

 
setQuery(payload)

Changes or removes the payload for this IQ.

Methods borrowed from class jabberwerx.Stanza:
clone, errorReply, getDoc, getErrorInfo, getFrom, getFromJID, getID, getNode, getTo, getToJID, getType, isError, pType, setFrom, setID, setTo, setType, swap, wasUnserialized, willBeSerialized, xml
Methods borrowed from class jabberwerx.JWModel:
applyEvent, event, shouldBeSavedWithGraph
Methods borrowed from class jabberwerx.JWBase:
destroy, getClassName, graphUnserialized, init, invocation, shouldBeSerializedInline, toString
Class Detail
jabberwerx.IQ(packet)

Creates a new IQ object.

Parameters:
{Element} packet Optional
The <iq/> element, or null for an empty IQ
Throws:
{TypeError}
If {packet} is not an <iq/> element
Method Detail
{Element} getQuery()

Retrieves the payload for this IQ.

Returns:
{Element} The payload for this IQ, or {null} if none

{jabberwerx.IQ} reply(payload)

Generates a reply IQ from this IQ. This method clones this IQ and sets the type to "result". If {payload} is specified, it is added, otherwise the IQ is empty.

Parameters:
{Element|String} payload
The payload for this IQ
Throws:
{TypeError}
If {payload} is not an XML Element
Returns:
{jabberwerx.IQ} The reply for this IQ

{Element} setQuery(payload)

Changes or removes the payload for this IQ.

Parameters:
payload
Throws:
{TypeError}
If {payload} is not an Element
Returns:
{Element} The payload for this IQ, or {null} if none

Documentation generated by JsDoc Toolkit 2.4.0 on Wed Apr 02 2014 13:23:42 GMT-0600 (MDT)