Package net.minecraft.core.component
Interface DataComponentMap
- All Superinterfaces:
Iterable<TypedDataComponent<?>>
- All Known Implementing Classes:
DataComponentMap.Builder.SimpleMap
,PatchedDataComponentMap
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<DataComponentMap> static final DataComponentMap
-
Method Summary
Modifier and TypeMethodDescriptionstatic DataComponentMap.Builder
builder()
static DataComponentMap
composite
(DataComponentMap p_329885_, DataComponentMap p_330534_) default DataComponentMap
filter
(Predicate<DataComponentType<?>> p_329403_) <T> T
get
(DataComponentType<? extends T> p_331367_) default <T> T
getOrDefault
(DataComponentType<? extends T> p_333956_, T p_334477_) default <T> TypedDataComponent
<T> getTyped
(DataComponentType<T> p_334795_) default boolean
has
(DataComponentType<?> p_334046_) default boolean
isEmpty()
default Iterator
<TypedDataComponent<?>> iterator()
Set
<DataComponentType<?>> keySet()
static com.mojang.serialization.Codec
<DataComponentMap> makeCodec
(com.mojang.serialization.Codec<DataComponentType<?>> p_343101_) static com.mojang.serialization.Codec
<DataComponentMap> makeCodecFromMap
(com.mojang.serialization.Codec<Map<DataComponentType<?>, Object>> p_343378_) default int
size()
default Stream
<TypedDataComponent<?>> stream()
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
EMPTY
-
CODEC
-
-
Method Details
-
makeCodec
static com.mojang.serialization.Codec<DataComponentMap> makeCodec(com.mojang.serialization.Codec<DataComponentType<?>> p_343101_) -
makeCodecFromMap
static com.mojang.serialization.Codec<DataComponentMap> makeCodecFromMap(com.mojang.serialization.Codec<Map<DataComponentType<?>, Object>> p_343378_) -
composite
-
builder
-
get
-
keySet
Set<DataComponentType<?>> keySet() -
has
-
getOrDefault
-
getTyped
-
iterator
- Specified by:
iterator
in interfaceIterable<TypedDataComponent<?>>
-
stream
-
size
default int size() -
isEmpty
default boolean isEmpty() -
filter
-