Package org.jivesoftware.smackx.receipts
Class DeliveryReceipt
- java.lang.Object
-
- org.jivesoftware.smackx.receipts.DeliveryReceipt
-
- All Implemented Interfaces:
Element
,ExtensionElement
,FullyQualifiedElement
,NamedElement
,XmlLangElement
public class DeliveryReceipt extends Object implements ExtensionElement
Represents a message delivery receipt entry as specified by Message Delivery Receipts.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
DeliveryReceipt.Provider
This Provider parses and returns DeliveryReceipt packets.
-
Constructor Summary
Constructors Constructor Description DeliveryReceipt(String id)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static DeliveryReceipt
from(Message message)
Get theDeliveryReceipt
extension of the message, if any.String
getElementName()
Returns the root element name.static DeliveryReceipt
getFrom(Message p)
Deprecated.usefrom(Message)
insteadString
getId()
Get the id of the message that has been delivered.String
getNamespace()
Returns the root element XML namespace.XmlStringBuilder
toXML(XmlEnvironment enclosingNamespace)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jivesoftware.smack.packet.FullyQualifiedElement
getLanguage, getQName
-
-
-
-
Field Detail
-
NAMESPACE
public static final String NAMESPACE
- See Also:
- Constant Field Values
-
ELEMENT
public static final String ELEMENT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
DeliveryReceipt
public DeliveryReceipt(String id)
-
-
Method Detail
-
getId
public String getId()
Get the id of the message that has been delivered.- Returns:
- id of the delivered message or
null
.
-
getElementName
public String getElementName()
Description copied from interface:NamedElement
Returns the root element name.- Specified by:
getElementName
in interfaceNamedElement
- Returns:
- the element name.
-
getNamespace
public String getNamespace()
Description copied from interface:FullyQualifiedElement
Returns the root element XML namespace.- Specified by:
getNamespace
in interfaceFullyQualifiedElement
- Returns:
- the namespace.
-
toXML
public XmlStringBuilder toXML(XmlEnvironment enclosingNamespace)
-
getFrom
@Deprecated public static DeliveryReceipt getFrom(Message p)
Deprecated.usefrom(Message)
insteadGet theDeliveryReceipt
extension of the packet, if any.- Parameters:
p
- the packet- Returns:
- the
DeliveryReceipt
extension ornull
-
from
public static DeliveryReceipt from(Message message)
Get theDeliveryReceipt
extension of the message, if any.- Parameters:
message
- the message.- Returns:
- the
DeliveryReceipt
extension ornull
-
-