本文整理匯總了Java中org.apache.harmony.jpda.tests.framework.jdwp.ReplyPacket.getNextValueAsClassID方法的典型用法代碼示例。如果您正苦於以下問題:Java ReplyPacket.getNextValueAsClassID方法的具體用法?Java ReplyPacket.getNextValueAsClassID怎麽用?Java ReplyPacket.getNextValueAsClassID使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.apache.harmony.jpda.tests.framework.jdwp.ReplyPacket
的用法示例。
在下文中一共展示了ReplyPacket.getNextValueAsClassID方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: asserSuperClassReplyIsValid
import org.apache.harmony.jpda.tests.framework.jdwp.ReplyPacket; //導入方法依賴的package包/類
private void asserSuperClassReplyIsValid(ReplyPacket reply, String expectedSignature) {
assertTrue(reply.getErrorCode() == JDWPConstants.Error.NONE);
long superClassID = reply.getNextValueAsClassID();
logWriter.println("superClassID=" + superClassID);
if (superClassID == 0) {
// for superclass of Object expectedSignature is null
assertNull
("ClassType::Superclass command returned invalid expectedSignature that must be null",
expectedSignature);
} else {
String signature = getClassSignature(superClassID);
logWriter.println("Signature: "+signature);
assertString("ClassType::Superclass command returned invalid signature,",
expectedSignature, signature);
}
}
示例2: getSuperclassId
import org.apache.harmony.jpda.tests.framework.jdwp.ReplyPacket; //導入方法依賴的package包/類
/**
* Returns the immediate superclass of a class
*
* @param classID
* The class ID whose superclass ID is to get
* @return The superclass ID (null if the class ID for java.lang.Object is
* specified).
*/
public final long getSuperclassId(long classID) {
CommandPacket command = new CommandPacket(
JDWPCommands.ClassTypeCommandSet.CommandSetID,
JDWPCommands.ClassTypeCommandSet.SuperclassCommand);
command.setNextValueAsClassID(classID);
ReplyPacket reply = checkReply(performCommand(command));
return reply.getNextValueAsClassID();
}