Package net.minecraft.component
Record Class ComponentMap.Builder.SimpleComponentMap
java.lang.Object
java.lang.Record
net.minecraft.component.ComponentMap.Builder.SimpleComponentMap
- Record Components:
map
-
- All Implemented Interfaces:
Iterable<Component<?>>
,ComponentMap
- Enclosing class:
ComponentMap.Builder
private static record ComponentMap.Builder.SimpleComponentMap(Reference2ObjectMap<ComponentType<?>,Object> map)
extends Record
implements ComponentMap
- Mappings:
Namespace Name named net/minecraft/component/ComponentMap$Builder$SimpleComponentMap
intermediary net/minecraft/class_9323$class_9324$class_9325
official km$a$a
named map
intermediary comp_2440
official c
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.component.ComponentMap
ComponentMap.Builder
-
Field Summary
Modifier and TypeFieldDescriptionprivate final Reference2ObjectMap
<ComponentType<?>, Object> The field for themap
record component.Fields inherited from interface net.minecraft.component.ComponentMap
CODEC, EMPTY
-
Constructor Summary
ConstructorDescriptionSimpleComponentMap
(Reference2ObjectMap<ComponentType<?>, Object> reference2ObjectMap) -
Method Summary
Modifier and TypeMethodDescriptionboolean
contains
(ComponentType<?> type) final boolean
Indicates whether some other object is "equal to" this one.<T> T
get
(ComponentType<? extends T> type) Set
<ComponentType<?>> getTypes()
final int
hashCode()
Returns a hash code value for this object.iterator()
map()
Returns the value of themap
record component.int
size()
toString()
Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.minecraft.component.ComponentMap
copy, filtered, getOrDefault, isEmpty, stream
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
map
The field for themap
record component.
-
-
Constructor Details
-
SimpleComponentMap
SimpleComponentMap(Reference2ObjectMap<ComponentType<?>, Object> reference2ObjectMap)
-
-
Method Details
-
get
- Specified by:
get
in interfaceComponentMap
- Mappings:
Namespace Name Mixin selector named get
Lnet/minecraft/component/ComponentMap;get(Lnet/minecraft/component/ComponentType;)Ljava/lang/Object;
intermediary method_57829
Lnet/minecraft/class_9323;method_57829(Lnet/minecraft/class_9331;)Ljava/lang/Object;
official a
Lkm;a(Lkp;)Ljava/lang/Object;
-
contains
- Specified by:
contains
in interfaceComponentMap
- Mappings:
Namespace Name Mixin selector named contains
Lnet/minecraft/component/ComponentMap;contains(Lnet/minecraft/component/ComponentType;)Z
intermediary method_57832
Lnet/minecraft/class_9323;method_57832(Lnet/minecraft/class_9331;)Z
official b
Lkm;b(Lkp;)Z
-
getTypes
- Specified by:
getTypes
in interfaceComponentMap
- Mappings:
Namespace Name Mixin selector named getTypes
Lnet/minecraft/component/ComponentMap;getTypes()Ljava/util/Set;
intermediary method_57831
Lnet/minecraft/class_9323;method_57831()Ljava/util/Set;
official b
Lkm;b()Ljava/util/Set;
-
iterator
- Specified by:
iterator
in interfaceComponentMap
- Specified by:
iterator
in interfaceIterable<Component<?>>
-
size
public int size()- Specified by:
size
in interfaceComponentMap
- Mappings:
Namespace Name Mixin selector named size
Lnet/minecraft/component/ComponentMap;size()I
intermediary method_57835
Lnet/minecraft/class_9323;method_57835()I
official d
Lkm;d()I
-
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)
. -
map
Returns the value of themap
record component.- Returns:
- the value of the
map
record component
-