protected static class ClassFileLocator.AgentBased.ExtractionClassFileTransformer
extends java.lang.Object
implements java.lang.instrument.ClassFileTransformer
| Modifier and Type | Field and Description |
|---|---|
private byte[] |
binaryRepresentation
The binary representation of the looked-up class.
|
private java.lang.ClassLoader |
classLoader
The class loader that is expected to have loaded the looked-up a class.
|
private static byte[] |
DO_NOT_TRANSFORM
An indicator that an attempted class file transformation did not alter the handed class file.
|
private java.lang.String |
typeName
The name of the type to look up.
|
| Modifier | Constructor and Description |
|---|---|
protected |
ExtractionClassFileTransformer(java.lang.ClassLoader classLoader,
java.lang.String typeName)
Creates a class file transformer for the purpose of extraction.
|
| Modifier and Type | Method and Description |
|---|---|
protected byte[] |
getBinaryRepresentation()
Returns the binary representation of the class file that was looked up.
|
byte[] |
transform(java.lang.ClassLoader classLoader,
java.lang.String internalName,
java.lang.Class<?> redefinedType,
java.security.ProtectionDomain protectionDomain,
byte[] binaryRepresentation) |
private static final byte[] DO_NOT_TRANSFORM
private final java.lang.ClassLoader classLoader
private final java.lang.String typeName
private volatile byte[] binaryRepresentation
protected ExtractionClassFileTransformer(java.lang.ClassLoader classLoader,
java.lang.String typeName)
classLoader - The class loader that is expected to have loaded the looked-up a class.typeName - The name of the type to look up.public byte[] transform(java.lang.ClassLoader classLoader,
java.lang.String internalName,
java.lang.Class<?> redefinedType,
java.security.ProtectionDomain protectionDomain,
byte[] binaryRepresentation)
transform in interface java.lang.instrument.ClassFileTransformerprotected byte[] getBinaryRepresentation()
null if no such class file could
be located.