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
FieldsModifier and TypeFieldDescriptionprivate final RegistryAccess.WritableThe field for theaccessrecord component.private final RegistryLoaderThe field for theloaderrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionBound(RegistryAccess.Writable access, RegistryLoader loader) Creates an instance of aBoundrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaccess()Returns the value of theaccessrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.loader()Returns the value of theloaderrecord 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 StringtoString()Returns a string representation of this record class.
-
Field Details
-
access
The field for theaccessrecord component. -
loader
The field for theloaderrecord component.
-
-
Constructor Details
-
Bound
Creates an instance of aBoundrecord class.- Parameters:
access- the value for theaccessrecord componentloader- the value for theloaderrecord 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 theaccessrecord component.- Returns:
- the value of the
accessrecord component
-
loader
Returns the value of theloaderrecord component.- Returns:
- the value of the
loaderrecord component
-