Record Class WeatheringCopperCollection<T>
java.lang.Object
java.lang.Record
net.minecraft.world.level.block.WeatheringCopperCollection<T>
public record WeatheringCopperCollection<T>(WeatheringCopperCollection.ByState<T> weathering, WeatheringCopperCollection.ByState<T> waxed)
extends Record
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final WeatheringCopperCollection<String> private final WeatheringCopperCollection.ByState<T> The field for thewaxedrecord component.private final WeatheringCopperCollection.ByState<T> The field for theweatheringrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionWeatheringCopperCollection(WeatheringCopperCollection.ByState<T> weathering, WeatheringCopperCollection.ByState<T> waxed) Creates an instance of aWeatheringCopperCollectionrecord class. -
Method Summary
Modifier and TypeMethodDescription<U> WeatheringCopperCollection<U> apply(Function<WeatheringCopperCollection.ByState<T>, WeatheringCopperCollection.ByState<U>> mapper) <U> WeatheringCopperCollection<U> apply(Function<WeatheringCopperCollection.ByState<T>, WeatheringCopperCollection.ByState<U>> weatheringMapper, Function<WeatheringCopperCollection.ByState<T>, WeatheringCopperCollection.ByState<U>> waxedMapper) asList()static WeatheringCopperCollection<String> createFamily(BiFunction<String, WeatheringCopper.WeatherState, BlockFamily> waxedProvider, BiFunction<String, WeatheringCopper.WeatherState, BlockFamily> weatheringProvider) final booleanIndicates whether some other object is "equal to" this one.voidfinal inthashCode()Returns a hash code value for this object.<U> WeatheringCopperCollection<U> static WeatheringCopperCollection<String> static <WaxedBlock extends Block, WeatheringBlock extends Block & WeatheringCopper, Id>
WeatheringCopperCollection<Block> registerBlocks(WeatheringCopperCollection<Id> ids, org.apache.commons.lang3.function.TriFunction<Id, Function<BlockBehaviour.Properties, Block>, BlockBehaviour.Properties, Block> register, BiFunction<WeatheringCopper.WeatherState, BlockBehaviour.Properties, WaxedBlock> waxedBlockFactory, BiFunction<WeatheringCopper.WeatherState, BlockBehaviour.Properties, WeatheringBlock> weatheringFactory, Function<WeatheringCopper.WeatherState, BlockBehaviour.Properties> propertiesSupplier) static <Id> WeatheringCopperCollection<Item> registerItems(WeatheringCopperCollection<Id> ids, WeatheringCopperCollection<Block> blocks, BiFunction<Id, Block, Item> itemFactory) static WeatheringCopperCollection<String> same(WeatheringCopperCollection.ByState<String> byState) final StringtoString()Returns a string representation of this record class.waxed()Returns the value of thewaxedrecord component.Returns the value of theweatheringrecord component.static <T,U> void zipApply(WeatheringCopperCollection.ByState<T> first, WeatheringCopperCollection.ByState<U> second, BiConsumer<T, U> consumer) static <T,U> void zipApply(WeatheringCopperCollection<T> first, WeatheringCopperCollection<U> second, BiConsumer<T, U> consumer) static <T,U, R> WeatheringCopperCollection.ByState <R> zipMap(WeatheringCopperCollection.ByState<T> first, WeatheringCopperCollection.ByState<U> second, BiFunction<T, U, R> operation) static <T,U, R> WeatheringCopperCollection <R> zipMap(WeatheringCopperCollection<T> first, WeatheringCopperCollection<U> second, BiFunction<T, U, R> operation) voidzipUnwaxedWaxed(BiConsumer<T, T> consumer)
-
Field Details
-
weathering
The field for theweatheringrecord component. -
waxed
The field for thewaxedrecord component. -
STATES
-
PREFIXES
-
-
Constructor Details
-
WeatheringCopperCollection
public WeatheringCopperCollection(WeatheringCopperCollection.ByState<T> weathering, WeatheringCopperCollection.ByState<T> waxed) Creates an instance of aWeatheringCopperCollectionrecord class.- Parameters:
weathering- the value for theweatheringrecord componentwaxed- the value for thewaxedrecord component
-
-
Method Details
-
prefixWithState
public static WeatheringCopperCollection<String> prefixWithState(WeatheringCopperCollection<String> ids) -
create
-
same
public static WeatheringCopperCollection<String> same(WeatheringCopperCollection.ByState<String> byState) -
registerBlocks
public static <WaxedBlock extends Block, WeatheringBlock extends Block & WeatheringCopper, Id> WeatheringCopperCollection<Block> registerBlocks(WeatheringCopperCollection<Id> ids, org.apache.commons.lang3.function.TriFunction<Id, Function<BlockBehaviour.Properties, Block>, BlockBehaviour.Properties, Block> register, BiFunction<WeatheringCopper.WeatherState, BlockBehaviour.Properties, WaxedBlock> waxedBlockFactory, BiFunction<WeatheringCopper.WeatherState, BlockBehaviour.Properties, WeatheringBlock> weatheringFactory, Function<WeatheringCopper.WeatherState, BlockBehaviour.Properties> propertiesSupplier) -
registerItems
public static <Id> WeatheringCopperCollection<Item> registerItems(WeatheringCopperCollection<Id> ids, WeatheringCopperCollection<Block> blocks, BiFunction<Id, Block, Item> itemFactory) -
createFamily
public static WeatheringCopperCollection<BlockFamily> createFamily(BiFunction<String, WeatheringCopper.WeatherState, BlockFamily> waxedProvider, BiFunction<String, WeatheringCopper.WeatherState, BlockFamily> weatheringProvider) -
asList
-
forEach
-
map
-
apply
public <U> WeatheringCopperCollection<U> apply(Function<WeatheringCopperCollection.ByState<T>, WeatheringCopperCollection.ByState<U>> mapper) -
apply
public <U> WeatheringCopperCollection<U> apply(Function<WeatheringCopperCollection.ByState<T>, WeatheringCopperCollection.ByState<U>> weatheringMapper, Function<WeatheringCopperCollection.ByState<T>, WeatheringCopperCollection.ByState<U>> waxedMapper) -
zipApply
public static <T,U> void zipApply(WeatheringCopperCollection<T> first, WeatheringCopperCollection<U> second, BiConsumer<T, U> consumer) -
zipMap
public static <T,U, WeatheringCopperCollection<R> zipMapR> (WeatheringCopperCollection<T> first, WeatheringCopperCollection<U> second, BiFunction<T, U, R> operation) -
zipUnwaxedWaxed
-
zipApply
public static <T,U> void zipApply(WeatheringCopperCollection.ByState<T> first, WeatheringCopperCollection.ByState<U> second, BiConsumer<T, U> consumer) -
zipMap
public static <T,U, WeatheringCopperCollection.ByState<R> zipMapR> (WeatheringCopperCollection.ByState<T> first, WeatheringCopperCollection.ByState<U> second, BiFunction<T, U, R> operation) -
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). -
weathering
Returns the value of theweatheringrecord component.- Returns:
- the value of the
weatheringrecord component
-
waxed
Returns the value of thewaxedrecord component.- Returns:
- the value of the
waxedrecord component
-