Package net.minecraft.util.registry
Record Class DynamicRegistryManager.Info<E>
java.lang.Object
java.lang.Record
net.minecraft.util.registry.DynamicRegistryManager.Info<E>
- Record Components:
registry
-entryCodec
-networkEntryCodec
-
- Enclosing interface:
DynamicRegistryManager
public static record DynamicRegistryManager.Info<E>(RegistryKey<? extends Registry<E>> registry, com.mojang.serialization.Codec<E> entryCodec, @Nullable com.mojang.serialization.Codec<E> networkEntryCodec)
extends Record
Represents the serialization behavior of the registries, including the
id of the registry, the codec for its elements, and whether the registry
should be sent to the client.
- Mappings:
Namespace Name official hn$c
intermediary net/minecraft/class_5455$class_5456
named net/minecraft/util/registry/DynamicRegistryManager$Info
official a
intermediary comp_293
named registry
official b
intermediary comp_294
named entryCodec
official c
intermediary comp_295
named networkEntryCodec
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.mojang.serialization.Codec<E>
The field for theentryCodec
record component.The field for thenetworkEntryCodec
record component.private final RegistryKey<? extends Registry<E>>
The field for theregistry
record component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.serialization.Codec<E>
Returns the value of theentryCodec
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.boolean
isSynced()
Returns the value of thenetworkEntryCodec
record component.RegistryKey<? extends Registry<E>>
registry()
Returns the value of theregistry
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
registry
The field for theregistry
record component. -
entryCodec
The field for theentryCodec
record component. -
networkEntryCodec
The field for thenetworkEntryCodec
record component.
-
-
Constructor Details
-
Info
public Info(RegistryKey<? extends Registry<E>> registry, com.mojang.serialization.Codec<E> entryCodec, @Nullable @Nullable com.mojang.serialization.Codec<E> networkEntryCodec) Creates an instance of aInfo
record class.- Parameters:
registry
- the value for theregistry
record componententryCodec
- the value for theentryCodec
record componentnetworkEntryCodec
- the value for thenetworkEntryCodec
record component
-
-
Method Details
-
isSynced
public boolean isSynced()- Mappings:
Namespace Name Mixin selector official a
Lhn$c;a()Z
intermediary method_30537
Lnet/minecraft/class_5455$class_5456;method_30537()Z
named isSynced
Lnet/minecraft/util/registry/DynamicRegistryManager$Info;isSynced()Z
-
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)
. -
registry
Returns the value of theregistry
record component.- Returns:
- the value of the
registry
record component
-
entryCodec
Returns the value of theentryCodec
record component.- Returns:
- the value of the
entryCodec
record component
-
networkEntryCodec
Returns the value of thenetworkEntryCodec
record component.- Returns:
- the value of the
networkEntryCodec
record component
-