Record Class PokedexData

java.lang.Object
java.lang.Record
com.pixelmonmod.pixelmon.client.storage.pokemon.PokedexData

public record PokedexData(PokemonBase pokemonBase, List<SimplifiedSpawning> spawningInfo, List<net.minecraft.world.item.ItemStack> drops, List<net.minecraft.world.item.ItemStack> daycareRequirements, net.minecraft.network.chat.Component daycareDuration) extends Record
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final com.mojang.serialization.Codec<PokedexData>
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    PokedexData(PokemonBase pokemonBase, List<SimplifiedSpawning> spawningInfo, List<net.minecraft.world.item.ItemStack> drops, List<net.minecraft.world.item.ItemStack> daycareRequirements, net.minecraft.network.chat.Component daycareDuration)
    Creates an instance of a PokedexData record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    net.minecraft.network.chat.Component
    Returns the value of the daycareDuration record component.
    List<net.minecraft.world.item.ItemStack>
    Returns the value of the daycareRequirements record component.
    List<net.minecraft.world.item.ItemStack>
    Returns the value of the drops record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    Returns the value of the pokemonBase record component.
    Returns the value of the spawningInfo record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

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

    • CODEC

      public static final com.mojang.serialization.Codec<PokedexData> CODEC
  • Constructor Details

    • PokedexData

      public PokedexData(PokemonBase pokemonBase, List<SimplifiedSpawning> spawningInfo, List<net.minecraft.world.item.ItemStack> drops, List<net.minecraft.world.item.ItemStack> daycareRequirements, net.minecraft.network.chat.Component daycareDuration)
      Creates an instance of a PokedexData record class.
      Parameters:
      pokemonBase - the value for the pokemonBase record component
      spawningInfo - the value for the spawningInfo record component
      drops - the value for the drops record component
      daycareRequirements - the value for the daycareRequirements record component
      daycareDuration - the value for the daycareDuration 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. All components in this record class are compared with Objects::equals(Object,Object).
      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.
    • pokemonBase

      public PokemonBase pokemonBase()
      Returns the value of the pokemonBase record component.
      Returns:
      the value of the pokemonBase record component
    • spawningInfo

      public List<SimplifiedSpawning> spawningInfo()
      Returns the value of the spawningInfo record component.
      Returns:
      the value of the spawningInfo record component
    • drops

      public List<net.minecraft.world.item.ItemStack> drops()
      Returns the value of the drops record component.
      Returns:
      the value of the drops record component
    • daycareRequirements

      public List<net.minecraft.world.item.ItemStack> daycareRequirements()
      Returns the value of the daycareRequirements record component.
      Returns:
      the value of the daycareRequirements record component
    • daycareDuration

      public net.minecraft.network.chat.Component daycareDuration()
      Returns the value of the daycareDuration record component.
      Returns:
      the value of the daycareDuration record component