Package net.minecraft.entity.ai.brain
Record Class MemoryQuery.Value<Value>
java.lang.Object
java.lang.Record
net.minecraft.entity.ai.brain.MemoryQuery.Value<Value>
- Record Components:
memory-
- All Implemented Interfaces:
MemoryQuery<com.mojang.datafixers.kinds.IdF.Mu,Value>
- Enclosing interface:
MemoryQuery<F extends com.mojang.datafixers.kinds.K1,Value>
public static record MemoryQuery.Value<Value>(MemoryModuleType<Value> memory)
extends Record
implements MemoryQuery<com.mojang.datafixers.kinds.IdF.Mu,Value>
A query that succeeds if a value is present in the memory. The result is the queried value.
- See Also:
- Mappings:
Namespace Name official bld$bintermediary net/minecraft/class_7907$class_7909named net/minecraft/entity/ai/brain/MemoryQuery$Valueofficial aintermediary comp_1151named memory
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.entity.ai.brain.MemoryQuery
MemoryQuery.Absent<Value>, MemoryQuery.Optional<Value>, MemoryQuery.Value<Value> -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final MemoryModuleType<Value>The field for thememoryrecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.getState()final inthashCode()Returns a hash code value for this object.memory()MemoryQueryResult<com.mojang.datafixers.kinds.IdF.Mu,Value> toQueryResult(Brain<?> brain, Optional<Value> value) final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.entity.ai.brain.MemoryQuery
toQueryResult
-
Field Details
-
memory
The field for thememoryrecord component.
-
-
Constructor Details
-
Value
-
-
Method Details
-
getState
- Specified by:
getStatein interfaceMemoryQuery<com.mojang.datafixers.kinds.IdF.Mu,Value> - Mappings:
Namespace Name Mixin selector official bLbld;b()Lbpa;intermediary method_47254Lnet/minecraft/class_7907;method_47254()Lnet/minecraft/class_4141;named getStateLnet/minecraft/entity/ai/brain/MemoryQuery;getState()Lnet/minecraft/entity/ai/brain/MemoryModuleState;
-
toQueryResult
public MemoryQueryResult<com.mojang.datafixers.kinds.IdF.Mu,Value> toQueryResult(Brain<?> brain, Optional<Value> value) - Mappings:
Namespace Name Mixin selector official aLbld;a(Lbgy;Ljava/util/Optional;)Lblc;intermediary method_47253Lnet/minecraft/class_7907;method_47253(Lnet/minecraft/class_4095;Ljava/util/Optional;)Lnet/minecraft/class_7906;named toQueryResultLnet/minecraft/entity/ai/brain/MemoryQuery;toQueryResult(Lnet/minecraft/entity/ai/brain/Brain;Ljava/util/Optional;)Lnet/minecraft/entity/ai/brain/MemoryQueryResult;
-
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). -
memory
- Specified by:
memoryin interfaceMemoryQuery<com.mojang.datafixers.kinds.IdF.Mu,Value> - Mappings:
Namespace Name Mixin selector official aLbld;a()Lboz;intermediary comp_1151Lnet/minecraft/class_7907;comp_1151()Lnet/minecraft/class_4140;named memoryLnet/minecraft/entity/ai/brain/MemoryQuery;memory()Lnet/minecraft/entity/ai/brain/MemoryModuleType;
-