Package net.bytebuddy.utility
Class OpenedClassReader
java.lang.Object
net.bytebuddy.utility.OpenedClassReader
A
ClassReader
that does not apply a class file version check if the net.bytebuddy.experimental
property is set.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
Indicates the ASM API version that is used throughout Byte Buddy.static final boolean
true
if Byte Buddy is executed in experimental mode.static final String
Indicates that Byte Buddy should not validate the maximum supported class file version. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static <T> T
doPrivileged
(PrivilegedAction<T> action) A proxy forjava.security.AccessController#doPrivileged
that is activated if available.static org.objectweb.asm.ClassReader
of
(byte[] binaryRepresentation) Creates a class reader for the given binary representation of a class file.
-
Field Details
-
EXPERIMENTAL_PROPERTY
Indicates that Byte Buddy should not validate the maximum supported class file version.- See Also:
-
EXPERIMENTAL
public static final boolean EXPERIMENTALtrue
if Byte Buddy is executed in experimental mode. -
ASM_API
public static final int ASM_APIIndicates the ASM API version that is used throughout Byte Buddy.
-
-
Constructor Details
-
OpenedClassReader
private OpenedClassReader()Not intended for construction.
-
-
Method Details
-
doPrivileged
A proxy forjava.security.AccessController#doPrivileged
that is activated if available.- Type Parameters:
T
- The type of the action's resolved value.- Parameters:
action
- The action to execute from a privileged context.- Returns:
- The action's resolved value.
-
of
public static org.objectweb.asm.ClassReader of(byte[] binaryRepresentation) Creates a class reader for the given binary representation of a class file.- Parameters:
binaryRepresentation
- The binary representation of a class file to read.- Returns:
- An appropriate class reader.
-