Package net.minecraft.state.property
Class Property<T extends Comparable<T>>
java.lang.Object
net.minecraft.state.property.Property<T>
- Direct Known Subclasses:
BooleanProperty,EnumProperty,IntProperty
- Mappings:
Namespace Name named net/minecraft/state/property/Propertyintermediary net/minecraft/class_2769official duf
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.mojang.serialization.Codec<T> private final StringThe name of this property.private final com.mojang.serialization.Codec<Property.Value<T>> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcreateValue(State<?, ?> state) createValue(T value) booleancom.mojang.serialization.Codec<T> getCodec()getName()Returns the name of this property.getType()Returns the type of the values of this property.com.mojang.serialization.Codec<Property.Value<T>> abstract Collection<T> Returns all possible values of this property.final inthashCode()abstract StringReturns the name of the given value of this property.<U,S extends State<?, S>>
com.mojang.serialization.DataResult<S> parse(com.mojang.serialization.DynamicOps<U> ops, S state, U input) stream()toString()
-
Field Details
-
type
- Mappings:
Namespace Name Mixin selector named typeLnet/minecraft/state/property/Property;type:Ljava/lang/Class;intermediary field_24742Lnet/minecraft/class_2769;field_24742:Ljava/lang/Class;official aLduf;a:Ljava/lang/Class;
-
name
The name of this property.Note that the name is required to match the valid name pattern. Otherwise,
IllegalArgumentExceptionwill be thrown during the validation of a property.- Mappings:
Namespace Name Mixin selector named nameLnet/minecraft/state/property/Property;name:Ljava/lang/String;intermediary field_24743Lnet/minecraft/class_2769;field_24743:Ljava/lang/String;official bLduf;b:Ljava/lang/String;
-
hashCodeCache
- Mappings:
Namespace Name Mixin selector named hashCodeCacheLnet/minecraft/state/property/Property;hashCodeCache:Ljava/lang/Integer;intermediary field_24744Lnet/minecraft/class_2769;field_24744:Ljava/lang/Integer;official cLduf;c:Ljava/lang/Integer;
-
codec
- Mappings:
Namespace Name Mixin selector named codecLnet/minecraft/state/property/Property;codec:Lcom/mojang/serialization/Codec;intermediary field_24745Lnet/minecraft/class_2769;field_24745:Lcom/mojang/serialization/Codec;official dLduf;d:Lcom/mojang/serialization/Codec;
-
valueCodec
- Mappings:
Namespace Name Mixin selector named valueCodecLnet/minecraft/state/property/Property;valueCodec:Lcom/mojang/serialization/Codec;intermediary field_25670Lnet/minecraft/class_2769;field_25670:Lcom/mojang/serialization/Codec;official eLduf;e:Lcom/mojang/serialization/Codec;
-
-
Constructor Details
-
Property
- Mappings:
Namespace Name Mixin selector named <init>Lnet/minecraft/state/property/Property;<init>(Ljava/lang/String;Ljava/lang/Class;)Vintermediary <init>Lnet/minecraft/class_2769;<init>(Ljava/lang/String;Ljava/lang/Class;)Vofficial <init>Lduf;<init>(Ljava/lang/String;Ljava/lang/Class;)V
-
-
Method Details
-
createValue
- Mappings:
Namespace Name Mixin selector named createValueLnet/minecraft/state/property/Property;createValue(Ljava/lang/Comparable;)Lnet/minecraft/state/property/Property$Value;intermediary method_30042Lnet/minecraft/class_2769;method_30042(Ljava/lang/Comparable;)Lnet/minecraft/class_2769$class_4933;official bLduf;b(Ljava/lang/Comparable;)Lduf$a;
-
createValue
- Mappings:
Namespace Name Mixin selector named createValueLnet/minecraft/state/property/Property;createValue(Lnet/minecraft/state/State;)Lnet/minecraft/state/property/Property$Value;intermediary method_30041Lnet/minecraft/class_2769;method_30041(Lnet/minecraft/class_2688;)Lnet/minecraft/class_2769$class_4933;official aLduf;a(Ldte;)Lduf$a;
-
stream
- Mappings:
Namespace Name Mixin selector named streamLnet/minecraft/state/property/Property;stream()Ljava/util/stream/Stream;intermediary method_30043Lnet/minecraft/class_2769;method_30043()Ljava/util/stream/Stream;official cLduf;c()Ljava/util/stream/Stream;
-
getCodec
- Mappings:
Namespace Name Mixin selector named getCodecLnet/minecraft/state/property/Property;getCodec()Lcom/mojang/serialization/Codec;intermediary method_35308Lnet/minecraft/class_2769;method_35308()Lcom/mojang/serialization/Codec;official dLduf;d()Lcom/mojang/serialization/Codec;
-
getValueCodec
- Mappings:
Namespace Name Mixin selector named getValueCodecLnet/minecraft/state/property/Property;getValueCodec()Lcom/mojang/serialization/Codec;intermediary method_30044Lnet/minecraft/class_2769;method_30044()Lcom/mojang/serialization/Codec;official eLduf;e()Lcom/mojang/serialization/Codec;
-
getName
Returns the name of this property.- Mappings:
Namespace Name Mixin selector named getNameLnet/minecraft/state/property/Property;getName()Ljava/lang/String;intermediary method_11899Lnet/minecraft/class_2769;method_11899()Ljava/lang/String;official fLduf;f()Ljava/lang/String;
-
getType
Returns the type of the values of this property.- Mappings:
Namespace Name Mixin selector named getTypeLnet/minecraft/state/property/Property;getType()Ljava/lang/Class;intermediary method_11902Lnet/minecraft/class_2769;method_11902()Ljava/lang/Class;official gLduf;g()Ljava/lang/Class;
-
getValues
Returns all possible values of this property.- Mappings:
Namespace Name Mixin selector named getValuesLnet/minecraft/state/property/Property;getValues()Ljava/util/Collection;intermediary method_11898Lnet/minecraft/class_2769;method_11898()Ljava/util/Collection;official aLduf;a()Ljava/util/Collection;
-
name
Returns the name of the given value of this property.- Mappings:
Namespace Name Mixin selector named nameLnet/minecraft/state/property/Property;name(Ljava/lang/Comparable;)Ljava/lang/String;intermediary method_11901Lnet/minecraft/class_2769;method_11901(Ljava/lang/Comparable;)Ljava/lang/String;official aLduf;a(Ljava/lang/Comparable;)Ljava/lang/String;
-
parse
- Mappings:
Namespace Name Mixin selector named parseLnet/minecraft/state/property/Property;parse(Ljava/lang/String;)Ljava/util/Optional;intermediary method_11900Lnet/minecraft/class_2769;method_11900(Ljava/lang/String;)Ljava/util/Optional;official bLduf;b(Ljava/lang/String;)Ljava/util/Optional;
-
toString
-
equals
-
hashCode
public final int hashCode() -
computeHashCode
public int computeHashCode()- Mappings:
Namespace Name Mixin selector named computeHashCodeLnet/minecraft/state/property/Property;computeHashCode()Iintermediary method_11799Lnet/minecraft/class_2769;method_11799()Iofficial bLduf;b()I
-
parse
public <U,S extends State<?, com.mojang.serialization.DataResult<S> parseS>> (com.mojang.serialization.DynamicOps<U> ops, S state, U input) - Mappings:
Namespace Name Mixin selector named parseLnet/minecraft/state/property/Property;parse(Lcom/mojang/serialization/DynamicOps;Lnet/minecraft/state/State;Ljava/lang/Object;)Lcom/mojang/serialization/DataResult;intermediary method_35307Lnet/minecraft/class_2769;method_35307(Lcom/mojang/serialization/DynamicOps;Lnet/minecraft/class_2688;Ljava/lang/Object;)Lcom/mojang/serialization/DataResult;official aLduf;a(Lcom/mojang/serialization/DynamicOps;Ldte;Ljava/lang/Object;)Lcom/mojang/serialization/DataResult;
-