mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 06:45:07 +02:00
8335290: Rename ClassFile::transform to ClassFile::transformClass
Reviewed-by: asotona
This commit is contained in:
parent
d51141e5fc
commit
0db9bc57de
58 changed files with 171 additions and 174 deletions
|
@ -195,7 +195,7 @@ class PackageSnippets {
|
|||
builder.with(element);
|
||||
};
|
||||
var cc = ClassFile.of();
|
||||
byte[] newBytes = cc.transform(cc.parse(bytes), ct);
|
||||
byte[] newBytes = cc.transformClass(cc.parse(bytes), ct);
|
||||
// @end
|
||||
}
|
||||
|
||||
|
@ -346,7 +346,7 @@ class PackageSnippets {
|
|||
|
||||
void codeRelabeling(ClassModel classModel) {
|
||||
// @start region="codeRelabeling"
|
||||
byte[] newBytes = ClassFile.of().transform(classModel,
|
||||
byte[] newBytes = ClassFile.of().transformClass(classModel,
|
||||
ClassTransform.transformingMethodBodies(
|
||||
CodeTransform.ofStateful(CodeRelabeler::of)));
|
||||
// @end
|
||||
|
@ -360,7 +360,7 @@ class PackageSnippets {
|
|||
var targetFieldNames = target.fields().stream().map(f -> f.fieldName().stringValue()).collect(Collectors.toSet());
|
||||
var targetMethods = target.methods().stream().map(m -> m.methodName().stringValue() + m.methodType().stringValue()).collect(Collectors.toSet());
|
||||
var instrumentorClassRemapper = ClassRemapper.of(Map.of(instrumentor.thisClass().asSymbol(), target.thisClass().asSymbol()));
|
||||
return ClassFile.of().transform(target,
|
||||
return ClassFile.of().transformClass(target,
|
||||
ClassTransform.transformingMethods(
|
||||
instrumentedMethodsFilter,
|
||||
(mb, me) -> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue