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
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static net.minecraft.core.component.DataComponentPatch
    build(net.minecraft.core.component.DataComponentPatch.Builder internal)
    Builds the DataComponentPatch.
    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 the DataComponentType from the DataComponentPatch.Builder.
    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 given DataComponentType.
    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 the TypedDataComponent for the given DataComponentType.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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 given DataComponentType.
      Parameters:
      type - The DataComponentType to set the value for.
      value - The value to set for the given DataComponentType.
      Returns:
      The DataComponentPatch.Builder with 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 the DataComponentType from the DataComponentPatch.Builder.
      Parameters:
      type - The DataComponentType to remove.
      Returns:
      The DataComponentPatch.Builder with the DataComponentType removed.
    • 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 the TypedDataComponent for the given DataComponentType.
      Parameters:
      type - The DataComponentType to set the TypedDataComponent for.
      Returns:
      The DataComponentPatch.Builder with the TypedDataComponent set.
    • build

      public static net.minecraft.core.component.DataComponentPatch build(net.minecraft.core.component.DataComponentPatch.Builder internal)
      Builds the DataComponentPatch.
      Returns:
      The DataComponentPatch.