use of com.ibm.j9ddr.vm29.pointer.generated.J9EnclosingObjectPointer in project openj9 by eclipse.
the class J9BCUtil method dumpEnclosingMethod.
private static void dumpEnclosingMethod(PrintStream out, J9ROMClassPointer romClass, long flags) throws CorruptDataException {
J9EnclosingObjectPointer enclosingMethodForROMClass = OptInfo.getEnclosingMethodForROMClass(romClass);
if (!enclosingMethodForROMClass.isNull()) {
J9ROMConstantPoolItemPointer constantPool = ConstantPoolHelpers.J9_ROM_CP_FROM_ROM_CLASS(romClass);
J9ROMClassRefPointer romClassRefPointer = J9ROMClassRefPointer.cast(constantPool);
String className = romClassRefPointer.name().toString();
J9ROMNameAndSignaturePointer nameAndSignature = enclosingMethodForROMClass.nameAndSignature();
if (!nameAndSignature.isNull()) {
out.append(String.format("Enclosing Method: %s%s%s", className, J9UTF8Helper.stringValue(nameAndSignature.name()), J9UTF8Helper.stringValue(nameAndSignature.signature())));
} else {
out.append(String.format("Enclosing Class: %s", className));
}
}
}
Aggregations