public class Forwarded extends java.lang.Object implements PacketExtension
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ELEMENT_NAME |
static java.lang.String |
NAMESPACE |
Constructor and Description |
---|
Forwarded(DelayInfo delay,
Packet fwdPacket)
Creates a new Forwarded packet extension.
|
Forwarded(Packet fwdPacket)
Creates a new Forwarded packet extension.
|
Modifier and Type | Method and Description |
---|---|
DelayInfo |
getDelayInfo()
get the timestamp of the forwarded packet.
|
java.lang.String |
getElementName()
Returns the root element name.
|
Packet |
getForwardedPacket()
get the packet forwarded by this stanza.
|
java.lang.String |
getNamespace()
Returns the root element XML namespace.
|
java.lang.String |
toXML()
Returns the XML representation of the PacketExtension.
|
public static final java.lang.String NAMESPACE
public static final java.lang.String ELEMENT_NAME
public Forwarded(DelayInfo delay, Packet fwdPacket)
delay
- an optional DelayInfo
timestamp of the packet.fwdPacket
- the packet that is forwarded (required).public Forwarded(Packet fwdPacket)
fwdPacket
- the packet that is forwarded (required).public java.lang.String getElementName()
PacketExtension
getElementName
in interface PacketExtension
public java.lang.String getNamespace()
PacketExtension
getNamespace
in interface PacketExtension
public java.lang.String toXML()
PacketExtension
toXML
in interface PacketExtension
public Packet getForwardedPacket()
Packet
instance (typically a message) that was forwarded.