public class DelayInformation extends java.lang.Object implements PacketExtension
For more information see JEP-91.
| Modifier and Type | Field and Description |
|---|---|
static java.text.SimpleDateFormat |
NEW_UTC_FORMAT
New date format based on JEP-82 that some clients may use when sending delayed dates.
|
static java.text.SimpleDateFormat |
UTC_FORMAT |
| Constructor and Description |
|---|
DelayInformation(java.util.Date stamp)
Creates a new instance with the specified timestamp.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getElementName()
Returns the root element name.
|
java.lang.String |
getFrom()
Returns the JID of the entity that originally sent the packet or that delayed the
delivery of the packet or null if this information is not available.
|
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 timstamp when the packet was originally sent.
|
void |
setFrom(java.lang.String from)
Sets the JID of the entity that originally sent the packet or that delayed the
delivery of the packet or null if this information is not available.
|
void |
setReason(java.lang.String reason)
Sets a natural-language description of the reason for the delay or null if
this information is not available.
|
java.lang.String |
toXML()
Returns the XML reppresentation of the PacketExtension.
|
public static java.text.SimpleDateFormat UTC_FORMAT
public static java.text.SimpleDateFormat NEW_UTC_FORMAT
public DelayInformation(java.util.Date stamp)
public java.lang.String getFrom()
public void setFrom(java.lang.String from)
from - the JID of the entity that originally sent the packet.public java.util.Date getStamp()
public java.lang.String getReason()
public void setReason(java.lang.String reason)
reason - a natural-language description of the reason for the delay or null.public java.lang.String getElementName()
PacketExtensiongetElementName in interface PacketExtensionpublic java.lang.String getNamespace()
PacketExtensiongetNamespace in interface PacketExtensionpublic java.lang.String toXML()
PacketExtensiontoXML in interface PacketExtensionCopyright © 2003 Jive Software.