public class ClassByExtensionBenchmark extends Object
ExampleClass which overrides all methods to invoke the
direct super class's implementation. The benchmark furthermore creates an instance of this class since some
code generation frameworks rely on this property. Because this benchmark requires the creation of a subclass,
the JDK proxy is not included in this benchmark.| Modifier and Type | Class and Description |
|---|---|
static class |
ClassByExtensionBenchmark.ByteBuddyInterceptor
Instead of using the
SuperMethodCall instrumentation, we are using
a delegate in order to emulate the interception approach of other instrumentation libraries. |
| Modifier and Type | Field and Description |
|---|---|
static Class<? extends ExampleClass> |
BASE_CLASS
The base class to be subclassed in all benchmarks.
|
| Constructor and Description |
|---|
ClassByExtensionBenchmark() |
| Modifier and Type | Method and Description |
|---|---|
ExampleClass |
benchmarkByteBuddySpecialized()
Performs a benchmark of a class extension using Byte Buddy.
|
ExampleClass |
benchmarkByteBuddyWithAnnotations()
Performs a benchmark of a class extension using Byte Buddy.
|
ExampleClass |
benchmarkCglib()
Performs a benchmark of a class extension using cglib.
|
ExampleClass |
benchmarkJavassist()
Performs a benchmark of a class extension using javassist proxies.
|
public static final Class<? extends ExampleClass> BASE_CLASS
public ExampleClass benchmarkByteBuddyWithAnnotations() throws Exception
Exception - If the reflective invocation causes an exception.public ExampleClass benchmarkByteBuddySpecialized() throws Exception
Exception - If the reflective invocation causes an exception.public ExampleClass benchmarkCglib()
public ExampleClass benchmarkJavassist() throws Exception
Exception - If the reflective invocation causes an exception.Copyright © 2014. All rights reserved.