Methods Summary |
---|
static com.sun.cldchi.tools.memoryprofiler.jdwp.Reply | Error(int ErrorCode)This method
prepares a JDWP reply packet with specified error code.
Reply r = new Reply();
r.setLength();
r.setID(0);
r.setFlags(flReply);
r.setErrorCode(ErrorCode);
return r;
|
public int | getErrorCode()Returns value of the "error code" field of JDWP reply packet.
int err = 0;
try {
err = (int) getID(ErrorCodeOffset, 2);
}
catch (BoundException e) {};
return err;
|
public boolean | ok()Returns true if this packet's error code equals zero.
return (getErrorCode() == errOk);
|
public void | setErrorCode(long err)Sets value of the "error code" field of JDWP reply packet.
try {
putID(ErrorCodeOffset, err, 2);
}
catch (BoundException e) {};
|
public java.lang.String | toString()Returns a string representation of the reply packet. This method
is used by BackEndTest to print all the
replies that were not requested by other parts of code. It's useful
for localizing problems.
String s;
if (getFlags() == 0)
s = "command ";
else
s = "error code ";
return "length " + Tools.Hex(length(), 8) + "\n" +
"id " + Tools.Hex(getID(), 8) + "\n" +
"flags " + Tools.Hex(getFlags(), 2) + "\n" +
s + Tools.Hex(getErrorCode(), 4) + "\n" +
super.toString(PacketHeaderSize);
|