public final class Instrumentor extends Object
Simple -javaagent compatible instrumentor. Provides a premain implementation which grabs a handle to the JVM Instrumentation and keeps a reference
to it for use later on.
| Constructor and Description |
|---|
Instrumentor() |
| Modifier and Type | Method and Description |
|---|---|
static Collection<Class<?>> |
annotatedWith(Class<? extends Annotation> theAnnotation)
Return all the classes which have the given annotation applied to them
|
static <T> Collection<Class<? extends T>> |
instancesOf(Class<T> theClass)
Return all the classes loaded into the JVM which extend from the provided class
|
static Instrumentation |
instrumentation()
Return the JVM instrumentation
|
static boolean |
isInitialized()
Return whether or not the JVM instrumentation has been initialized via the JVM agent
|
static void |
premain(String theAgentArgs,
Instrumentation theJVMInst)
Premain method for use with -javaagent.
|
public static Instrumentation instrumentation()
public static void premain(String theAgentArgs, Instrumentation theJVMInst)
theAgentArgs - the cmd line argstheJVMInst - the JVM instrumentationpublic static <T> Collection<Class<? extends T>> instancesOf(Class<T> theClass)
T - the base class typetheClass - the classpublic static Collection<Class<?>> annotatedWith(Class<? extends Annotation> theAnnotation)
theAnnotation - the annotationpublic static boolean isInitialized()
Copyright © 2010-2016 Stardog Union. All Rights Reserved.