Record Class CheckExtensibleEnums
java.lang.Object
java.lang.Record
net.neoforged.neoforge.network.configuration.CheckExtensibleEnums
- All Implemented Interfaces:
ConfigurationTask
@Internal
public record CheckExtensibleEnums(ServerConfigurationPacketListener listener)
extends Record
implements ConfigurationTask
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordprivate static enumNested classes/interfaces inherited from interface ConfigurationTask
ConfigurationTask.Type -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static Map<String, CheckExtensibleEnums.EnumEntry> private final ServerConfigurationPacketListenerThe field for thelistenerrecord component.private static final org.slf4j.Loggerprivate static final Typestatic final ConfigurationTask.Type -
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of aCheckExtensibleEnumsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionprivate static Class<?> classForName(String name) final booleanIndicates whether some other object is "equal to" this one.private static Map<String, CheckExtensibleEnums.EnumEntry> private static ExtensionInfogetEnumExtensionInfo(Class<? extends Enum<?>> enumClass) static voidhandleClientboundPayload(ExtensibleEnumDataPayload payload, IPayloadContext context) static voidhandleServerboundPayload(ExtensibleEnumAcknowledgePayload payload, IPayloadContext context) static booleanfinal inthashCode()Returns a hash code value for this object.listener()Returns the value of thelistenerrecord component.voidfinal StringtoString()Returns a string representation of this record class.type()Methods inherited from interface ConfigurationTask
tick
-
Field Details
-
listener
The field for thelistenerrecord component. -
TYPE
-
LOGGER
private static final org.slf4j.Logger LOGGER -
NETWORKED_ENUM
-
NETWORKED_EXTENSIBLE_ENUM_CLASSES
-
enumEntries
-
-
Constructor Details
-
CheckExtensibleEnums
Creates an instance of aCheckExtensibleEnumsrecord class.- Parameters:
listener- the value for thelistenerrecord component
-
-
Method Details
-
start
- Specified by:
startin interfaceConfigurationTask
-
handleClientboundPayload
public static void handleClientboundPayload(ExtensibleEnumDataPayload payload, IPayloadContext context) -
handleServerboundPayload
public static void handleServerboundPayload(ExtensibleEnumAcknowledgePayload payload, IPayloadContext context) -
handleVanillaServerConnection
-
getEnumEntries
-
getEnumExtensionInfo
-
collectNetworkedEnumClasses
-
classForName
-
type
- Specified by:
typein interfaceConfigurationTask
-
toString
-
hashCode
-
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). -
listener
Returns the value of thelistenerrecord component.- Returns:
- the value of the
listenerrecord component
-