public class RegistryNamespaced extends RegistrySimple implements IObjectIntIterable
Modifier and Type | Field and Description |
---|---|
protected java.util.Map |
field_148758_b |
protected ObjectIntIdentityMap |
underlyingIntegerMap
The backing store that maps Integers to objects.
|
registryObjects
Constructor and Description |
---|
RegistryNamespaced() |
Modifier and Type | Method and Description |
---|---|
void |
addObject(int p_148756_1_,
java.lang.String p_148756_2_,
java.lang.Object p_148756_3_)
Adds a new object to this registry, keyed by both the given integer ID and the given string.
|
boolean |
containsId(int p_148753_1_)
Gets a value indicating whether this registry contains an object that can be identified by the given integer
value
|
boolean |
containsKey(java.lang.Object p_148741_1_)
Does this registry contain an entry for the given key?
|
boolean |
containsKey(java.lang.String p_148752_1_)
Does this registry contain an entry for the given key?
|
protected java.util.Map |
createUnderlyingMap()
Creates the Map we will use to map keys to their registered values.
|
protected static java.lang.String |
ensureNamespaced(java.lang.String p_148755_0_)
Ensures that the given name is indicated by a colon-delimited namespace, prepending "minecraft:" if it is not
already.
|
int |
getIDForObject(java.lang.Object p_148757_1_)
Gets the integer ID we use to identify the given object.
|
java.lang.String |
getNameForObject(java.lang.Object p_148750_1_)
Gets the name we use to identify the given object.
|
java.lang.Object |
getObject(java.lang.Object par1Obj) |
java.lang.Object |
getObject(java.lang.String p_148751_1_) |
java.lang.Object |
getObjectById(int p_148754_1_)
Gets the object identified by the given ID.
|
java.util.Iterator |
iterator() |
getKeys, putObject
protected ObjectIntIdentityMap underlyingIntegerMap
protected final java.util.Map field_148758_b
public void addObject(int p_148756_1_, java.lang.String p_148756_2_, java.lang.Object p_148756_3_)
protected java.util.Map createUnderlyingMap()
createUnderlyingMap
in class RegistrySimple
public java.lang.Object getObject(java.lang.String p_148751_1_)
public java.lang.String getNameForObject(java.lang.Object p_148750_1_)
public boolean containsKey(java.lang.String p_148752_1_)
public int getIDForObject(java.lang.Object p_148757_1_)
public java.lang.Object getObjectById(int p_148754_1_)
public java.util.Iterator iterator()
iterator
in interface java.lang.Iterable
public boolean containsId(int p_148753_1_)
protected static java.lang.String ensureNamespaced(java.lang.String p_148755_0_)
public boolean containsKey(java.lang.Object p_148741_1_)
containsKey
in class RegistrySimple
public java.lang.Object getObject(java.lang.Object par1Obj)
getObject
in interface IRegistry
getObject
in class RegistrySimple