Record Class ComponentsPredicate
java.lang.Object
java.lang.Record
net.minecraft.predicate.component.ComponentsPredicate
- Record Components:
exact
-partial
-
- All Implemented Interfaces:
Predicate<ComponentsAccess>
public record ComponentsPredicate(ComponentMapPredicate exact, Map<ComponentPredicate.Type<?>,ComponentPredicate> partial)
extends Record
implements Predicate<ComponentsAccess>
- Mappings:
Namespace Name named net/minecraft/predicate/component/ComponentsPredicate
intermediary net/minecraft/class_10914
official bo
named exact
intermediary comp_3833
official d
named partial
intermediary comp_3834
official e
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec
<ComponentsPredicate> static final ComponentsPredicate
private final ComponentMapPredicate
The field for theexact
record component.static final PacketCodec
<RegistryByteBuf, ComponentsPredicate> private final Map
<ComponentPredicate.Type<?>, ComponentPredicate> The field for thepartial
record component. -
Constructor Summary
ConstructorsConstructorDescriptionComponentsPredicate
(ComponentMapPredicate componentMapPredicate, Map<ComponentPredicate.Type<?>, ComponentPredicate> map) -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.exact()
Returns the value of theexact
record component.final int
hashCode()
Returns a hash code value for this object.boolean
isEmpty()
partial()
Returns the value of thepartial
record component.boolean
test
(ComponentsAccess componentsAccess) final String
toString()
Returns a string representation of this record class.
-
Field Details
-
exact
The field for theexact
record component. -
partial
The field for thepartial
record component. -
EMPTY
- Mappings:
Namespace Name Mixin selector named EMPTY
Lnet/minecraft/predicate/component/ComponentsPredicate;EMPTY:Lnet/minecraft/predicate/component/ComponentsPredicate;
intermediary field_58044
Lnet/minecraft/class_10914;field_58044:Lnet/minecraft/class_10914;
official a
Lbo;a:Lbo;
-
CODEC
- Mappings:
Namespace Name Mixin selector named CODEC
Lnet/minecraft/predicate/component/ComponentsPredicate;CODEC:Lcom/mojang/serialization/MapCodec;
intermediary field_58045
Lnet/minecraft/class_10914;field_58045:Lcom/mojang/serialization/MapCodec;
official b
Lbo;b:Lcom/mojang/serialization/MapCodec;
-
PACKET_CODEC
- Mappings:
Namespace Name Mixin selector named PACKET_CODEC
Lnet/minecraft/predicate/component/ComponentsPredicate;PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;
intermediary field_58046
Lnet/minecraft/class_10914;field_58046:Lnet/minecraft/class_9139;
official c
Lbo;c:Lze;
-
-
Constructor Details
-
ComponentsPredicate
public ComponentsPredicate(ComponentMapPredicate componentMapPredicate, Map<ComponentPredicate.Type<?>, ComponentPredicate> map)
-
-
Method Details
-
test
- Specified by:
test
in interfacePredicate<ComponentsAccess>
- Mappings:
Namespace Name Mixin selector named test
Lnet/minecraft/predicate/component/ComponentsPredicate;test(Lnet/minecraft/component/ComponentsAccess;)Z
intermediary method_68682
Lnet/minecraft/class_10914;method_68682(Lnet/minecraft/class_9473;)Z
official a
Lbo;a(Lkg;)Z
-
isEmpty
public boolean isEmpty()- Mappings:
Namespace Name Mixin selector named isEmpty
Lnet/minecraft/predicate/component/ComponentsPredicate;isEmpty()Z
intermediary method_68680
Lnet/minecraft/class_10914;method_68680()Z
official a
Lbo;a()Z
-
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)
. -
exact
Returns the value of theexact
record component.- Returns:
- the value of the
exact
record component
-
partial
Returns the value of thepartial
record component.- Returns:
- the value of the
partial
record component
-