net.sf.jqql.packets.out.disk
Class DownloadPacket
java.lang.Object
net.sf.jqql.packets.Packet
net.sf.jqql.packets.OutPacket
net.sf.jqql.packets.DiskOutPacket
net.sf.jqql.packets.out.disk.DownloadPacket
public class DownloadPacket
- extends DiskOutPacket
download file request packet
1. head
2. network disk owner, 4 byte
3. file id, 30 byte
4. download begin offset, 4 byte
5. download length, 4 byte
下载文件请求包
1. 头部
2. 网络硬盘拥有者,4å—节
3. 文件id,30å—节
4. 下载起始å移,4å—节
5. 下载长度,4å—节
- Author:
- luma
Fields inherited from class net.sf.jqql.packets.Packet |
bodyBuf, bodyDecrypted, command, crypter, ds, duplicated, header, log, sequence, source, user |
Methods inherited from class net.sf.jqql.packets.DiskOutPacket |
decryptBody, encryptBody, equals, getBodyBytes, getCryptographStart, getFamily, getHeadLength, getLength, getLocalIp, getTailLength, hashCode, parseHeader, parseTail, postFill, putHead, putTail, setLocalIp, validateHeader |
Methods inherited from class net.sf.jqql.packets.OutPacket |
dump, fill, getKey, getNextSeq, getSendCount, getTimeout, needAck, needResend, parseBody, setKey, setSendCount, setTimeout |
DownloadPacket
public DownloadPacket(ByteBuffer buf,
int length,
QQUser user)
throws PacketParseException
- Throws:
PacketParseException
DownloadPacket
public DownloadPacket(QQUser user)
getPacketName
public String getPacketName()
- Overrides:
getPacketName
in class OutPacket
- Returns:
- descriptive name of packet
包的æè¿°æ€§åç§°
putBody
protected void putBody(ByteBuffer buf)
- Description copied from class:
Packet
- initialize packet body
åˆå§‹åŒ–包体
- Specified by:
putBody
in class Packet
- Parameters:
buf
- ByteBuffer
getDiskOwner
public int getDiskOwner()
- Returns:
- the diskOwner
setDiskOwner
public void setDiskOwner(int diskOwner)
- Parameters:
diskOwner
- the diskOwner to set
getFileId
public String getFileId()
- Returns:
- the fileId
setFileId
public void setFileId(String fileId)
- Parameters:
fileId
- the fileId to set
getLength
public int getLength()
- Returns:
- the length
setLength
public void setLength(int length)
- Parameters:
length
- the length to set
getOffset
public int getOffset()
- Returns:
- the offset
setOffset
public void setOffset(int offset)
- Parameters:
offset
- the offset to set