Class ExpandDataComponentPatch.ExpandDataComponentPatchBuilder
java.lang.Object
com.blamejared.crafttweaker.natives.component.ExpandDataComponentPatch.ExpandDataComponentPatchBuilder
- Enclosing class:
ExpandDataComponentPatch
@ZenRegister
public static class ExpandDataComponentPatch.ExpandDataComponentPatchBuilder
extends Object
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic net.minecraft.core.component.DataComponentPatchbuild(net.minecraft.core.component.DataComponentPatch.Builder internal) Builds theDataComponentPatch.static <T> net.minecraft.core.component.DataComponentPatch.Builderremove(net.minecraft.core.component.DataComponentPatch.Builder internal, Class<T> tClass, net.minecraft.core.component.DataComponentType<T> type) Removes theDataComponentTypefrom theDataComponentPatch.Builder.static <T> net.minecraft.core.component.DataComponentPatch.BuildersetComponent(net.minecraft.core.component.DataComponentPatch.Builder internal, Class<T> tClass, net.minecraft.core.component.DataComponentType<T> type, T value) Sets the value for the givenDataComponentType.static <T> net.minecraft.core.component.DataComponentPatch.BuildersetComponent(net.minecraft.core.component.DataComponentPatch.Builder internal, Class<T> tClass, net.minecraft.core.component.TypedDataComponent<T> type) Sets theTypedDataComponentfor the givenDataComponentType.
-
Constructor Details
-
ExpandDataComponentPatchBuilder
public ExpandDataComponentPatchBuilder()
-
-
Method Details
-
setComponent
public static <T> net.minecraft.core.component.DataComponentPatch.Builder setComponent(net.minecraft.core.component.DataComponentPatch.Builder internal, Class<T> tClass, net.minecraft.core.component.DataComponentType<T> type, T value) Sets the value for the givenDataComponentType.- Parameters:
type- TheDataComponentTypeto set the value for.value- The value to set for the givenDataComponentType.- Returns:
- The
DataComponentPatch.Builderwith the value set.
-
remove
public static <T> net.minecraft.core.component.DataComponentPatch.Builder remove(net.minecraft.core.component.DataComponentPatch.Builder internal, Class<T> tClass, net.minecraft.core.component.DataComponentType<T> type) Removes theDataComponentTypefrom theDataComponentPatch.Builder.- Parameters:
type- TheDataComponentTypeto remove.- Returns:
- The
DataComponentPatch.Builderwith theDataComponentTyperemoved.
-
setComponent
public static <T> net.minecraft.core.component.DataComponentPatch.Builder setComponent(net.minecraft.core.component.DataComponentPatch.Builder internal, Class<T> tClass, net.minecraft.core.component.TypedDataComponent<T> type) Sets theTypedDataComponentfor the givenDataComponentType.- Parameters:
type- TheDataComponentTypeto set theTypedDataComponentfor.- Returns:
- The
DataComponentPatch.Builderwith theTypedDataComponentset.
-
build
public static net.minecraft.core.component.DataComponentPatch build(net.minecraft.core.component.DataComponentPatch.Builder internal) Builds theDataComponentPatch.- Returns:
- The
DataComponentPatch.
-