Package net.minecraft.resources
Record Class RegistryLoader.Bound
java.lang.Object
java.lang.Record
net.minecraft.resources.RegistryLoader.Bound
- Enclosing class:
- RegistryLoader
public static record RegistryLoader.Bound(RegistryAccess.Writable access, RegistryLoader loader)
extends Record
-
Field Summary
Modifier and TypeFieldDescriptionprivate final RegistryAccess.Writable
The field for theaccess
record component.private final RegistryLoader
The field for theloader
record component. -
Constructor Summary
ConstructorDescriptionBound
(RegistryAccess.Writable access, RegistryLoader loader) Creates an instance of aBound
record class. -
Method Summary
Modifier and TypeMethodDescriptionaccess()
Returns the value of theaccess
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.loader()
Returns the value of theloader
record component.<E> com.mojang.serialization.DataResult<Holder<E>>
overrideElementFromResources
(ResourceKey<? extends Registry<E>> p_206794_, com.mojang.serialization.Codec<E> p_206795_, ResourceKey<E> p_206796_, com.mojang.serialization.DynamicOps<com.google.gson.JsonElement> p_206797_) <E> com.mojang.serialization.DataResult<? extends Registry<E>>
overrideRegistryFromResources
(ResourceKey<? extends Registry<E>> p_206790_, com.mojang.serialization.Codec<E> p_206791_, com.mojang.serialization.DynamicOps<com.google.gson.JsonElement> p_206792_) final String
toString()
Returns a string representation of this record class.
-
Field Details
-
access
The field for theaccess
record component. -
loader
The field for theloader
record component.
-
-
Constructor Details
-
Bound
Creates an instance of aBound
record class.- Parameters:
access
- the value for theaccess
record componentloader
- the value for theloader
record component
-
-
Method Details
-
overrideRegistryFromResources
public <E> com.mojang.serialization.DataResult<? extends Registry<E>> overrideRegistryFromResources(ResourceKey<? extends Registry<E>> p_206790_, com.mojang.serialization.Codec<E> p_206791_, com.mojang.serialization.DynamicOps<com.google.gson.JsonElement> p_206792_) -
overrideElementFromResources
public <E> com.mojang.serialization.DataResult<Holder<E>> overrideElementFromResources(ResourceKey<? extends Registry<E>> p_206794_, com.mojang.serialization.Codec<E> p_206795_, ResourceKey<E> p_206796_, com.mojang.serialization.DynamicOps<com.google.gson.JsonElement> p_206797_) -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
access
Returns the value of theaccess
record component.- Returns:
- the value of the
access
record component
-
loader
Returns the value of theloader
record component.- Returns:
- the value of the
loader
record component
-