public static class StreamInitiation.File extends java.lang.Object implements PacketExtension
| Constructor and Description |
|---|
StreamInitiation.File(java.lang.String name,
long size)
Constructor providing the name of the file and its size.
|
| Modifier and Type | Method and Description |
|---|---|
java.util.Date |
getDate()
Returns the date that the file was last modified.
|
java.lang.String |
getDesc()
Returns the description of the file.
|
java.lang.String |
getElementName()
Returns the root element name.
|
java.lang.String |
getHash()
Returns the MD5 sum of the file's contents
|
java.lang.String |
getName()
Returns the file's name.
|
java.lang.String |
getNamespace()
Returns the root element XML namespace.
|
long |
getSize()
Returns the file's size.
|
boolean |
isRanged()
Returns whether or not the initiator can support a range for the file
tranfer.
|
void |
setDate(java.util.Date date)
Sets the date that the file was last modified.
|
void |
setDesc(java.lang.String desc)
Sets the description of the file.
|
void |
setHash(java.lang.String hash)
Sets the MD5 sum of the file's contents
|
void |
setRanged(boolean isRanged)
True if a range can be provided and false if it cannot.
|
java.lang.String |
toXML()
Returns the XML representation of the PacketExtension.
|
public StreamInitiation.File(java.lang.String name,
long size)
name - The name of the file.size - The size of the file in bytes.public java.lang.String getName()
public long getSize()
public void setHash(java.lang.String hash)
hash - The MD5 sum of the file's contents.public java.lang.String getHash()
public void setDate(java.util.Date date)
date - The date that the file was last modified.public java.util.Date getDate()
public void setDesc(java.lang.String desc)
desc - The description of the file so that the file reciever can
know what file it is.public java.lang.String getDesc()
public void setRanged(boolean isRanged)
isRanged - True if a range can be provided and false if it cannot.public boolean isRanged()
public java.lang.String getElementName()
PacketExtensiongetElementName in interface PacketExtensionpublic java.lang.String getNamespace()
PacketExtensiongetNamespace in interface PacketExtensionpublic java.lang.String toXML()
PacketExtensiontoXML in interface PacketExtension