public class DelayInformation extends java.lang.Object implements ExtensionElement
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ELEMENT |
static java.lang.String |
NAMESPACE |
| Constructor and Description |
|---|
DelayInformation(java.util.Date stamp) |
DelayInformation(java.util.Date stamp,
java.lang.String from,
java.lang.String reason)
Creates a new instance with the specified timestamp.
|
| Modifier and Type | Method and Description |
|---|---|
static DelayInformation |
from(Stanza packet)
Return delay information from the given stanza.
|
java.lang.String |
getElementName()
Returns the root element name.
|
java.lang.String |
getFrom()
Returns the JID of the entity that originally sent the stanza(/packet) or that delayed the
delivery of the stanza(/packet) or null if this information is not available.
|
static DelayInformation |
getFrom(Stanza packet)
Deprecated.
use
from(Stanza) instead |
java.lang.String |
getNamespace()
Returns the root element XML namespace.
|
java.lang.String |
getReason()
Returns a natural-language description of the reason for the delay or null if
this information is not available.
|
java.util.Date |
getStamp()
Returns the timestamp when the stanza(/packet) was originally sent.
|
XmlStringBuilder |
toXML()
Returns the XML representation of this Element.
|
public static final java.lang.String ELEMENT
public static final java.lang.String NAMESPACE
public DelayInformation(java.util.Date stamp, java.lang.String from, java.lang.String reason)
stamp - the timestampfrom - senderreason - reason of delay.public DelayInformation(java.util.Date stamp)
public java.lang.String getFrom()
public java.util.Date getStamp()
public java.lang.String getReason()
public java.lang.String getElementName()
NamedElementgetElementName in interface NamedElementpublic java.lang.String getNamespace()
ExtensionElementgetNamespace in interface ExtensionElementpublic XmlStringBuilder toXML()
Element@Deprecated public static DelayInformation getFrom(Stanza packet)
from(Stanza) insteadpacket - public static DelayInformation from(Stanza packet)
packet -