Enum Class FluidStackImpl

java.lang.Object
java.lang.Enum<FluidStackImpl>
dev.architectury.fluid.fabric.FluidStackImpl
All Implemented Interfaces:
dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>, Serializable, Comparable<FluidStackImpl>, Constable

@Internal public enum FluidStackImpl extends Enum<FluidStackImpl> implements dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
  • Enum Constant Details

  • Field Details

    • toValue

      public static Function<dev.architectury.fluid.FluidStack,Object> toValue
    • fromValue

      public static Function<Object,dev.architectury.fluid.FluidStack> fromValue
  • Method Details

    • values

      public static FluidStackImpl[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static FluidStackImpl valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • adapt

      public static dev.architectury.fluid.FluidStack.FluidStackAdapter<Object> adapt(Function<dev.architectury.fluid.FluidStack,Object> toValue, Function<Object,dev.architectury.fluid.FluidStack> fromValue)
    • create

      public FluidStackImpl.Pair create(Supplier<net.minecraft.world.level.material.Fluid> fluid, long amount, net.minecraft.nbt.CompoundTag tag)
      Specified by:
      create in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • getRawFluidSupplier

      public Supplier<net.minecraft.world.level.material.Fluid> getRawFluidSupplier(FluidStackImpl.Pair object)
      Specified by:
      getRawFluidSupplier in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • getFluid

      public net.minecraft.world.level.material.Fluid getFluid(FluidStackImpl.Pair object)
      Specified by:
      getFluid in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • getAmount

      public long getAmount(FluidStackImpl.Pair object)
      Specified by:
      getAmount in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • setAmount

      public void setAmount(FluidStackImpl.Pair object, long amount)
      Specified by:
      setAmount in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • getTag

      public net.minecraft.nbt.CompoundTag getTag(FluidStackImpl.Pair value)
      Specified by:
      getTag in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • setTag

      public void setTag(FluidStackImpl.Pair value, net.minecraft.nbt.CompoundTag tag)
      Specified by:
      setTag in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • copy

      Specified by:
      copy in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>
    • hashCode

      public int hashCode(FluidStackImpl.Pair value)
      Specified by:
      hashCode in interface dev.architectury.fluid.FluidStack.FluidStackAdapter<FluidStackImpl.Pair>