public class ObjectHolderRegistry
extends java.lang.Object
ObjectHolder
referencesModifier and Type | Field and Description |
---|---|
private static org.apache.logging.log4j.Logger |
LOGGER |
private static org.objectweb.asm.Type |
MOD |
private static org.objectweb.asm.Type |
OBJECT_HOLDER |
private static java.util.Set<java.util.function.Consumer<java.util.function.Predicate<ResourceLocation>>> |
objectHolders |
Constructor and Description |
---|
ObjectHolderRegistry() |
Modifier and Type | Method and Description |
---|---|
static void |
addHandler(java.util.function.Consumer<java.util.function.Predicate<ResourceLocation>> ref)
Exposed to allow modders to register their own notification handlers.
|
static void |
applyObjectHolders() |
static void |
applyObjectHolders(java.util.function.Predicate<ResourceLocation> filter) |
static void |
findObjectHolders() |
static boolean |
removeHandler(java.util.function.Consumer<java.util.function.Predicate<ResourceLocation>> ref)
Removed the specified handler from the notification list.
|
private static void |
scanClassForFields(java.util.Map<org.objectweb.asm.Type,java.lang.String> classModIds,
org.objectweb.asm.Type targetClass,
java.lang.String value,
java.lang.Class<?> clazz,
boolean extractFromExistingValues) |
private static void |
scanTarget(java.util.Map<org.objectweb.asm.Type,java.lang.String> classModIds,
java.util.Map<org.objectweb.asm.Type,java.lang.Class<?>> classCache,
org.objectweb.asm.Type type,
java.lang.String annotationTarget,
java.lang.String value,
boolean isClass,
boolean extractFromValue) |
private static final org.apache.logging.log4j.Logger LOGGER
private static final java.util.Set<java.util.function.Consumer<java.util.function.Predicate<ResourceLocation>>> objectHolders
private static final org.objectweb.asm.Type OBJECT_HOLDER
private static final org.objectweb.asm.Type MOD
public static void addHandler(java.util.function.Consumer<java.util.function.Predicate<ResourceLocation>> ref)
public static boolean removeHandler(java.util.function.Consumer<java.util.function.Predicate<ResourceLocation>> ref)
public static void findObjectHolders()
private static void scanTarget(java.util.Map<org.objectweb.asm.Type,java.lang.String> classModIds, java.util.Map<org.objectweb.asm.Type,java.lang.Class<?>> classCache, org.objectweb.asm.Type type, @Nullable java.lang.String annotationTarget, java.lang.String value, boolean isClass, boolean extractFromValue)
private static void scanClassForFields(java.util.Map<org.objectweb.asm.Type,java.lang.String> classModIds, org.objectweb.asm.Type targetClass, java.lang.String value, java.lang.Class<?> clazz, boolean extractFromExistingValues)
public static void applyObjectHolders()
public static void applyObjectHolders(java.util.function.Predicate<ResourceLocation> filter)