Class StructureCompiler
java.lang.Object
com.comphenix.protocol.reflect.compiler.StructureCompiler
Represents a StructureModifier compiler.
- Author:
- Kristian
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescription<TField> StructureModifier<TField>compile(StructureModifier<TField> source)Compiles the given structure modifier.<TField> booleanlookupClassLoader(StructureModifier<TField> source)Lookup the current class loader for any previously generated classes before we attempt to generate something.
-
Field Details
-
REPORT_TOO_MANY_GENERATED_CLASSES
-
attemptClassLoad
public static boolean attemptClassLoad
-
-
Method Details
-
lookupClassLoader
Lookup the current class loader for any previously generated classes before we attempt to generate something.- Type Parameters:
TField- Type- Parameters:
source- - the structure modifier to look up.- Returns:
- TRUE if we successfully found a previously generated class, FALSE otherwise.
-
compile
Compiles the given structure modifier.WARNING: Do NOT call this method in the main thread. Compiling may easily take 10 ms, which is already over 1/4 of a tick (50 ms). Let the background thread automatically compile the structure modifiers instead.
- Type Parameters:
TField- Type- Parameters:
source- - structure modifier to compile.- Returns:
- A compiled structure modifier.
-