DataComponentMap
Importing the class
If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.
import crafttweaker.api.component.DataComponentMap;Description
A map ofDataComponentTypes to their values.   Implements
Undocumented Interfaces
Iterable<TypedDataComponent<?>>
Operators
DataComponentType.myDataComponentType<?> in myDataComponentMapParameters:
Return Type:
bool
Members
Returns: A new DataComponentMap.Builder.
DataComponentMap.builder();
Return Type:
DataComponentMapBuilder
DataComponentMaps.Returns: A new DataComponentMap that is the result of combining the two DataComponentMaps.
DataComponentMap.composite(myDataComponentMap, myDataComponentMap);Parameters:
Return Type:
DataComponentMap
DataComponentType.Returns: The value of the data component for the given type.
myDataComponentMap.getComponent<T>(myDataComponentType);Parameters:
Return Type:
T?
DataComponentType. If the data component is not present, the default value is returned.Returns: The value of the data component for the given type.
myDataComponentMap.getOrDefault<T>(myDataComponentType, myT);Parameters:
defaultValue: T  Type: T 
- The default value to return if the data component is not present.   
Return Type:
T
TypedDataComponent for the given DataComponentType.Returns: The TypedDataComponent for the given type.
myDataComponentMap.getTyped<T>(myDataComponentType);Parameters:
type: DataComponentType<T>  Type: DataComponentType<T> 
- The DataComponentType to get the TypedDataComponent for.   
Return Type:
TypedDataComponent<T>
DataComponentType.Returns: True if the data component map has the DataComponentType, false otherwise.
myDataComponentMap.has(myDataComponentType);Parameters:
Return Type:
bool
// DataComponentMap.isEmpty as boolmyDataComponentMap.isEmpty
Return Type:
bool
DataComponentTypes in the data component map.myDataComponentMap.keySet
Return Type:
Set<DataComponentType<?>>
myDataComponentMap.list
Return Type:
List<TypedDataComponent<?>>
// DataComponentMap.size as intmyDataComponentMap.size
Return Type:
int