Package net.minecraft.world.level.chunk
Record Class PalettedContainerFactory
java.lang.Object
java.lang.Record
net.minecraft.world.level.chunk.PalettedContainerFactory
public record PalettedContainerFactory(Strategy<BlockState> blockStatesStrategy, BlockState defaultBlockState, com.mojang.serialization.Codec<PalettedContainer<BlockState>> blockStatesContainerCodec, Strategy<Holder<Biome>> biomeStrategy, Holder<Biome> defaultBiome, com.mojang.serialization.Codec<PalettedContainerRO<Holder<Biome>>> biomeContainerCodec)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.mojang.serialization.Codec<PalettedContainerRO<Holder<Biome>>> The field for thebiomeContainerCodecrecord component.The field for thebiomeStrategyrecord component.private final com.mojang.serialization.Codec<PalettedContainer<BlockState>> The field for theblockStatesContainerCodecrecord component.private final Strategy<BlockState> The field for theblockStatesStrategyrecord component.The field for thedefaultBiomerecord component.private final BlockStateThe field for thedefaultBlockStaterecord component. -
Constructor Summary
ConstructorsConstructorDescriptionPalettedContainerFactory(Strategy<BlockState> blockStatesStrategy, BlockState defaultBlockState, com.mojang.serialization.Codec<PalettedContainer<BlockState>> blockStatesContainerCodec, Strategy<Holder<Biome>> biomeStrategy, Holder<Biome> defaultBiome, com.mojang.serialization.Codec<PalettedContainerRO<Holder<Biome>>> biomeContainerCodec) Creates an instance of aPalettedContainerFactoryrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.serialization.Codec<PalettedContainerRO<Holder<Biome>>> Returns the value of thebiomeContainerCodecrecord component.Returns the value of thebiomeStrategyrecord component.com.mojang.serialization.Codec<PalettedContainer<BlockState>> Returns the value of theblockStatesContainerCodecrecord component.Returns the value of theblockStatesStrategyrecord component.static PalettedContainerFactorycreate(RegistryAccess pRegistries) Returns the value of thedefaultBiomerecord component.Returns the value of thedefaultBlockStaterecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
blockStatesStrategy
The field for theblockStatesStrategyrecord component. -
defaultBlockState
The field for thedefaultBlockStaterecord component. -
blockStatesContainerCodec
private final com.mojang.serialization.Codec<PalettedContainer<BlockState>> blockStatesContainerCodecThe field for theblockStatesContainerCodecrecord component. -
biomeStrategy
The field for thebiomeStrategyrecord component. -
defaultBiome
The field for thedefaultBiomerecord component. -
biomeContainerCodec
private final com.mojang.serialization.Codec<PalettedContainerRO<Holder<Biome>>> biomeContainerCodecThe field for thebiomeContainerCodecrecord component.
-
-
Constructor Details
-
PalettedContainerFactory
public PalettedContainerFactory(Strategy<BlockState> blockStatesStrategy, BlockState defaultBlockState, com.mojang.serialization.Codec<PalettedContainer<BlockState>> blockStatesContainerCodec, Strategy<Holder<Biome>> biomeStrategy, Holder<Biome> defaultBiome, com.mojang.serialization.Codec<PalettedContainerRO<Holder<Biome>>> biomeContainerCodec) Creates an instance of aPalettedContainerFactoryrecord class.- Parameters:
blockStatesStrategy- the value for theblockStatesStrategyrecord componentdefaultBlockState- the value for thedefaultBlockStaterecord componentblockStatesContainerCodec- the value for theblockStatesContainerCodecrecord componentbiomeStrategy- the value for thebiomeStrategyrecord componentdefaultBiome- the value for thedefaultBiomerecord componentbiomeContainerCodec- the value for thebiomeContainerCodecrecord component
-
-
Method Details
-
create
-
createForBlockStates
-
createForBiomes
-
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). -
blockStatesStrategy
Returns the value of theblockStatesStrategyrecord component.- Returns:
- the value of the
blockStatesStrategyrecord component
-
defaultBlockState
Returns the value of thedefaultBlockStaterecord component.- Returns:
- the value of the
defaultBlockStaterecord component
-
blockStatesContainerCodec
Returns the value of theblockStatesContainerCodecrecord component.- Returns:
- the value of the
blockStatesContainerCodecrecord component
-
biomeStrategy
Returns the value of thebiomeStrategyrecord component.- Returns:
- the value of the
biomeStrategyrecord component
-
defaultBiome
Returns the value of thedefaultBiomerecord component.- Returns:
- the value of the
defaultBiomerecord component
-
biomeContainerCodec
Returns the value of thebiomeContainerCodecrecord component.- Returns:
- the value of the
biomeContainerCodecrecord component
-