public class RegistryBuilder<T extends IForgeRegistryEntry<T>>
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.util.List<IForgeRegistry.AddCallback<T>> |
addCallback |
private boolean |
allowModifications |
private boolean |
allowOverrides |
private java.util.List<IForgeRegistry.BakeCallback<T>> |
bakeCallback |
private java.util.List<IForgeRegistry.ClearCallback<T>> |
clearCallback |
private java.util.List<IForgeRegistry.CreateCallback<T>> |
createCallback |
private IForgeRegistry.DummyFactory<T> |
dummyFactory |
private java.util.Set<ResourceLocation> |
legacyNames |
private static int |
MAX_ID |
private int |
maxId |
private int |
minId |
private IForgeRegistry.MissingFactory<T> |
missingFactory |
private ResourceLocation |
optionalDefaultKey |
private ResourceLocation |
registryName |
private java.lang.Class<T> |
registryType |
private boolean |
saveToDisc |
private boolean |
sync |
private java.util.List<IForgeRegistry.ValidateCallback<T>> |
validateCallback |
Constructor and Description |
---|
RegistryBuilder() |
private static final int MAX_ID
private ResourceLocation registryName
private java.lang.Class<T extends IForgeRegistryEntry<T>> registryType
private ResourceLocation optionalDefaultKey
private int minId
private int maxId
private java.util.List<IForgeRegistry.AddCallback<T extends IForgeRegistryEntry<T>>> addCallback
private java.util.List<IForgeRegistry.ClearCallback<T extends IForgeRegistryEntry<T>>> clearCallback
private java.util.List<IForgeRegistry.CreateCallback<T extends IForgeRegistryEntry<T>>> createCallback
private java.util.List<IForgeRegistry.ValidateCallback<T extends IForgeRegistryEntry<T>>> validateCallback
private java.util.List<IForgeRegistry.BakeCallback<T extends IForgeRegistryEntry<T>>> bakeCallback
private boolean saveToDisc
private boolean sync
private boolean allowOverrides
private boolean allowModifications
private IForgeRegistry.DummyFactory<T extends IForgeRegistryEntry<T>> dummyFactory
private IForgeRegistry.MissingFactory<T extends IForgeRegistryEntry<T>> missingFactory
private java.util.Set<ResourceLocation> legacyNames
public RegistryBuilder<T> setName(ResourceLocation name)
public RegistryBuilder<T> setType(java.lang.Class<T> type)
public RegistryBuilder<T> setIDRange(int min, int max)
public RegistryBuilder<T> setMaxID(int max)
public RegistryBuilder<T> setDefaultKey(ResourceLocation key)
public RegistryBuilder<T> addCallback(java.lang.Object inst)
public RegistryBuilder<T> add(IForgeRegistry.AddCallback<T> add)
public RegistryBuilder<T> onAdd(IForgeRegistry.AddCallback<T> add)
public RegistryBuilder<T> add(IForgeRegistry.ClearCallback<T> clear)
public RegistryBuilder<T> onClear(IForgeRegistry.ClearCallback<T> clear)
public RegistryBuilder<T> add(IForgeRegistry.CreateCallback<T> create)
public RegistryBuilder<T> onCreate(IForgeRegistry.CreateCallback<T> create)
public RegistryBuilder<T> add(IForgeRegistry.ValidateCallback<T> validate)
public RegistryBuilder<T> onValidate(IForgeRegistry.ValidateCallback<T> validate)
public RegistryBuilder<T> add(IForgeRegistry.BakeCallback<T> bake)
public RegistryBuilder<T> onBake(IForgeRegistry.BakeCallback<T> bake)
public RegistryBuilder<T> set(IForgeRegistry.DummyFactory<T> factory)
public RegistryBuilder<T> dummy(IForgeRegistry.DummyFactory<T> factory)
public RegistryBuilder<T> set(IForgeRegistry.MissingFactory<T> missing)
public RegistryBuilder<T> missing(IForgeRegistry.MissingFactory<T> missing)
public RegistryBuilder<T> disableSaving()
public RegistryBuilder<T> disableSync()
public RegistryBuilder<T> disableOverrides()
public RegistryBuilder<T> allowModification()
public RegistryBuilder<T> legacyName(java.lang.String name)
public RegistryBuilder<T> legacyName(ResourceLocation name)
public IForgeRegistry<T> create()
@Nullable public IForgeRegistry.AddCallback<T> getAdd()
@Nullable public IForgeRegistry.ClearCallback<T> getClear()
@Nullable public IForgeRegistry.CreateCallback<T> getCreate()
@Nullable public IForgeRegistry.ValidateCallback<T> getValidate()
@Nullable public IForgeRegistry.BakeCallback<T> getBake()
public java.lang.Class<T> getType()
@Nullable public ResourceLocation getDefault()
public int getMinId()
public int getMaxId()
public boolean getAllowOverrides()
public boolean getAllowModifications()
@Nullable public IForgeRegistry.DummyFactory<T> getDummyFactory()
@Nullable public IForgeRegistry.MissingFactory<T> getMissingFactory()
public boolean getSaveToDisc()
public boolean getSync()
public java.util.Set<ResourceLocation> getLegacyNames()