Package org.jivesoftware.openfire.http
Class HttpBindBody
java.lang.Object
org.jivesoftware.openfire.http.HttpBindBody
Representation of the 'body' element of an HTTP-Bind defined request.
- Author:
- Guus der Kinderen, guus.der.kinderen@gmail.com
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionasXML()static HttpBindBodygetAck()Returns the 'ack' attribute value from this request body, representing the highest 'rid' of a request for which the client has received a response.org.dom4j.Documentorg.xmpp.packet.JIDgetFrom()Returns the value of the 'from' attribute of the body element, which a client can use to identify the entity that it intends to authenticate as (XEP-0124 § 7.1).intgetHold()protected static intgetIntAttribute(String value, int defaultValue) protected static longgetLongAttribute(String value, long defaultValue) intintgetPause()getRid()getSid()List<org.dom4j.Element>getType()getWait()booleanisEmpty()booleanisPoll()booleantoString()
-
Constructor Details
-
HttpBindBody
protected HttpBindBody(String content) throws org.dom4j.DocumentException, org.xmlpull.v1.XmlPullParserException, IOException - Throws:
org.dom4j.DocumentExceptionorg.xmlpull.v1.XmlPullParserExceptionIOException
-
-
Method Details
-
from
public static HttpBindBody from(String content) throws org.dom4j.DocumentException, org.xmlpull.v1.XmlPullParserException, IOException - Throws:
org.dom4j.DocumentExceptionorg.xmlpull.v1.XmlPullParserExceptionIOException
-
getRid
-
getSid
-
isEmpty
public boolean isEmpty() -
isPoll
public boolean isPoll() -
getLanguage
-
getWait
-
getHold
public int getHold() -
getPause
-
getVersion
-
getMajorVersion
public int getMajorVersion() -
getMinorVersion
public int getMinorVersion() -
getAck
Returns the 'ack' attribute value from this request body, representing the highest 'rid' of a request for which the client has received a response. Returns null if no 'ack' attribute is present.- Returns:
- the acknowledged request ID, or null if absent
- See Also:
-
getFrom
@Nullable public org.xmpp.packet.JID getFrom()Returns the value of the 'from' attribute of the body element, which a client can use to identify the entity that it intends to authenticate as (XEP-0124 § 7.1). This is an unverified claim made by the client. It must never be used for authentication or authorization. Its intended use is limited to optimizations, such as determining which SASL mechanisms are worth advertising.- Returns:
- the claimed identity, or null when the attribute is absent or does not contain a valid JID.
-
getType
-
isRestart
public boolean isRestart() -
getStanzaElements
-
asXML
-
toString
-
getDocument
public org.dom4j.Document getDocument() -
getLongAttribute
-
getIntAttribute
-