Enum Class DensityFunctions.WeirdScaledSampler.RarityValueMapper
java.lang.Object
java.lang.Enum<DensityFunctions.WeirdScaledSampler.RarityValueMapper>
net.minecraft.world.level.levelgen.DensityFunctions.WeirdScaledSampler.RarityValueMapper
- All Implemented Interfaces:
Serializable, Comparable<DensityFunctions.WeirdScaledSampler.RarityValueMapper>, Constable, StringRepresentable
- Enclosing class:
DensityFunctions.WeirdScaledSampler
public static enum DensityFunctions.WeirdScaledSampler.RarityValueMapper
extends Enum<DensityFunctions.WeirdScaledSampler.RarityValueMapper>
implements StringRepresentable
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E>Nested classes/interfaces inherited from interface StringRepresentable
StringRepresentable.EnumCodec<E>, StringRepresentable.StringRepresentableCodec<S> -
Enum Constant Summary
Enum Constants -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<DensityFunctions.WeirdScaledSampler.RarityValueMapper> private final it.unimi.dsi.fastutil.doubles.Double2DoubleFunctionprivate final doubleprivate final StringFields inherited from interface StringRepresentable
PRE_BUILT_MAP_THRESHOLD -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateRarityValueMapper(String name, it.unimi.dsi.fastutil.doubles.Double2DoubleFunction mapper, double maxRarity) -
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this class with the specified name.values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
TYPE1
-
TYPE2
-
-
Field Details
-
CODEC
public static final com.mojang.serialization.Codec<DensityFunctions.WeirdScaledSampler.RarityValueMapper> CODEC -
name
-
mapper
private final it.unimi.dsi.fastutil.doubles.Double2DoubleFunction mapper -
maxRarity
private final double maxRarity
-
-
Constructor Details
-
RarityValueMapper
private RarityValueMapper(String name, it.unimi.dsi.fastutil.doubles.Double2DoubleFunction mapper, double maxRarity)
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
getSerializedName
- Specified by:
getSerializedNamein interfaceStringRepresentable
-