|
JML | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.jqql.packets.Packet
net.sf.jqql.packets.InPacket
net.sf.jqql.packets.BasicInPacket
net.sf.jqql.packets.ErrorPacket
public class ErrorPacket
this packet is independent of protocol, it use to notify upper layer, some error happen, upper layer should checkout errorCode field to get more Specific info. 这个包和协议无关,它用来通知上层,有些错误发生了,上层应该检查errorCode字段 来获得更具体的信息
Field Summary | |
---|---|
String |
connectionId
|
static int |
ERROR_CONNECTION_BROKEN
long-distance already close connection /** 远端已经关闭连接 |
static int |
ERROR_NETWORK
网络错误 |
static int |
ERROR_PROXY
代理服务器错误 |
static int |
ERROR_TIMEOUT
操作超时 |
int |
errorCode
|
String |
errorMessage
|
static int |
RUNTIME_ERROR
运行时错误,调试用 |
OutPacket |
timeoutPacket
|
Fields inherited from class net.sf.jqql.packets.Packet |
---|
bodyBuf, bodyDecrypted, command, crypter, ds, duplicated, header, log, sequence, source, user |
Constructor Summary | |
---|---|
ErrorPacket(int errorCode,
QQUser user)
|
Method Summary | |
---|---|
int |
getFamily()
|
protected void |
parseBody(ByteBuffer buf)
parse packet body, from begin position of buf 解析包体,从buf的开头位置解析起 |
void |
setFamily(int family)
|
Methods inherited from class net.sf.jqql.packets.BasicInPacket |
---|
decryptBody, encryptBody, getBodyBytes, getCryptographStart, getHeadLength, getLength, getPacketName, getTailLength, parseHeader, parseTail, putBody, putHead, putTail, toString |
Methods inherited from class net.sf.jqql.packets.InPacket |
---|
validateHeader |
Methods inherited from class net.sf.jqql.packets.Packet |
---|
dump, equals, getCommand, getHeader, getSequence, getSource, hash, hashCode, isDuplicated, setDuplicated, setHeader, setSequence |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int ERROR_CONNECTION_BROKEN
public static final int ERROR_TIMEOUT
public static final int ERROR_PROXY
public static final int ERROR_NETWORK
public static final int RUNTIME_ERROR
public int errorCode
public String connectionId
public String errorMessage
public OutPacket timeoutPacket
Constructor Detail |
---|
public ErrorPacket(int errorCode, QQUser user)
Method Detail |
---|
protected void parseBody(ByteBuffer buf) throws PacketParseException
Packet
parseBody
in class Packet
buf
- ByteBuffer
PacketParseException
- if parse error
如果解析出错public int getFamily()
getFamily
in class BasicInPacket
public void setFamily(int family)
family
- the family to set
|
JML | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |