ClassLoader.
Usable in tests and standalone environments.
| Modifier and Type | Field and Description |
|---|---|
| private final WeavingTransformer |
| Access | Constructor and Description |
|---|---|
| public | SimpleInstrumentableClassLoader(ClassLoader
the ClassLoader to build an instrumentable ClassLoader for parent)Create a new SimpleInstrumentableClassLoader for the given ClassLoader. |
| Modifier and Type | Method and Description |
|---|---|
| public void | addTransformer(ClassFileTransformer
the transformer)ClassFileTransformer to registerAdd a |
| protected byte[] | transformIfNecessary(String
the fully-qualified name of the class being transformed name, byte[] the raw bytes of the class bytes)Overrides org. |
| weavingTransformer | back to summary |
|---|---|
| private final WeavingTransformer weavingTransformer | |
| SimpleInstrumentableClassLoader | back to summary |
|---|---|
| public SimpleInstrumentableClassLoader(ClassLoader parent) Create a new SimpleInstrumentableClassLoader for the given ClassLoader.
| |
| addTransformer | back to summary |
|---|---|
| public void addTransformer(ClassFileTransformer transformer) Add a
| |
| transformIfNecessary | back to summary |
|---|---|
| protected byte[] transformIfNecessary(String name, byte[] bytes) Overrides org. Doc from org. Transformation hook to be implemented by subclasses. The default implementation simply returns the given bytes as-is. | |