Record Class BasicSoil.Properties

java.lang.Object
java.lang.Record
net.darkhax.botanypots.common.impl.data.recipe.soil.BasicSoil.Properties
Enclosing class:
BasicSoil

public static record BasicSoil.Properties(net.minecraft.world.item.crafting.Ingredient input, Display display, float growthModifier, int lightLevel, float yieldModifier) extends Record
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final com.mojang.serialization.MapCodec<BasicSoil.Properties>
     
    static final net.minecraft.network.codec.StreamCodec<net.minecraft.network.RegistryFriendlyByteBuf,BasicSoil.Properties>
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    Properties(net.minecraft.world.item.crafting.Ingredient input, Display display, float growthModifier, int lightLevel, float yieldModifier)
    Creates an instance of a Properties record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the value of the display record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    float
    Returns the value of the growthModifier record component.
    final int
    Returns a hash code value for this object.
    net.minecraft.world.item.crafting.Ingredient
    Returns the value of the input record component.
    int
    Returns the value of the lightLevel record component.
    final String
    Returns a string representation of this record class.
    float
    Returns the value of the yieldModifier record component.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Field Details

    • CODEC

      public static final com.mojang.serialization.MapCodec<BasicSoil.Properties> CODEC
    • STREAM

      public static final net.minecraft.network.codec.StreamCodec<net.minecraft.network.RegistryFriendlyByteBuf,BasicSoil.Properties> STREAM
  • Constructor Details

    • Properties

      public Properties(net.minecraft.world.item.crafting.Ingredient input, Display display, float growthModifier, int lightLevel, float yieldModifier)
      Creates an instance of a Properties record class.
      Parameters:
      input - the value for the input record component
      display - the value for the display record component
      growthModifier - the value for the growthModifier record component
      lightLevel - the value for the lightLevel record component
      yieldModifier - the value for the yieldModifier record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • input

      public net.minecraft.world.item.crafting.Ingredient input()
      Returns the value of the input record component.
      Returns:
      the value of the input record component
    • display

      public Display display()
      Returns the value of the display record component.
      Returns:
      the value of the display record component
    • growthModifier

      public float growthModifier()
      Returns the value of the growthModifier record component.
      Returns:
      the value of the growthModifier record component
    • lightLevel

      public int lightLevel()
      Returns the value of the lightLevel record component.
      Returns:
      the value of the lightLevel record component
    • yieldModifier

      public float yieldModifier()
      Returns the value of the yieldModifier record component.
      Returns:
      the value of the yieldModifier record component