Package net.minecraft.core
Record Class RegistrySetBuilder.RegistryContents<T>
java.lang.Object
java.lang.Record
net.minecraft.core.RegistrySetBuilder.RegistryContents<T>
- Enclosing class:
- RegistrySetBuilder
static record RegistrySetBuilder.RegistryContents<T>(ResourceKey<? extends Registry<? extends T>> key, com.mojang.serialization.Lifecycle lifecycle, Map<ResourceKey<T>,RegistrySetBuilder.ValueAndHolder<T>> values)
extends Record 
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final ResourceKey<? extends Registry<? extends T>>The field for thekeyrecord component.private final com.mojang.serialization.LifecycleThe field for thelifecyclerecord component.private final Map<ResourceKey<T>,RegistrySetBuilder.ValueAndHolder<T>> The field for thevaluesrecord component.
- 
Constructor SummaryConstructorsConstructorDescriptionRegistryContents(ResourceKey<? extends Registry<? extends T>> key, com.mojang.serialization.Lifecycle lifecycle, Map<ResourceKey<T>, RegistrySetBuilder.ValueAndHolder<T>> values) Creates an instance of aRegistryContentsrecord class.
- 
Method SummaryModifier and TypeMethodDescriptionbuildAsLookup(RegistrySetBuilder.CompositeOwner p_312295_) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.ResourceKey<? extends Registry<? extends T>>key()Returns the value of thekeyrecord component.com.mojang.serialization.LifecycleReturns the value of thelifecyclerecord component.final StringtoString()Returns a string representation of this record class.values()Returns the value of thevaluesrecord component.
- 
Field Details- 
keyThe field for thekeyrecord component.
- 
lifecycleprivate final com.mojang.serialization.Lifecycle lifecycleThe field for thelifecyclerecord component.
- 
valuesThe field for thevaluesrecord component.
 
- 
- 
Constructor Details- 
RegistryContentsRegistryContents(ResourceKey<? extends Registry<? extends T>> key, com.mojang.serialization.Lifecycle lifecycle, Map<ResourceKey<T>, RegistrySetBuilder.ValueAndHolder<T>> values) Creates an instance of aRegistryContentsrecord class.- Parameters:
- key- the value for the- keyrecord component
- lifecycle- the value for the- lifecyclerecord component
- values- the value for the- valuesrecord component
 
 
- 
- 
Method Details- 
buildAsLookup
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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).
- 
keyReturns the value of thekeyrecord component.- Returns:
- the value of the keyrecord component
 
- 
lifecyclepublic com.mojang.serialization.Lifecycle lifecycle()Returns the value of thelifecyclerecord component.- Returns:
- the value of the lifecyclerecord component
 
- 
valuesReturns the value of thevaluesrecord component.- Returns:
- the value of the valuesrecord component
 
 
-