Record Class GeyserSmithingRecipe.Trim

java.lang.Object
java.lang.Record
org.geysermc.geyser.inventory.recipe.GeyserSmithingRecipe.Trim
All Implemented Interfaces:
GeyserRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>, GeyserSmithingRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
Enclosing interface:
GeyserSmithingRecipe<T extends org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.RecipeData>

public static record GeyserSmithingRecipe.Trim(int id, int netId, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay template, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay base, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay addition) extends Record implements GeyserSmithingRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.geysermc.geyser.inventory.recipe.GeyserSmithingRecipe

    GeyserSmithingRecipe.RecipeDataConstructor<T extends org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.RecipeData>, GeyserSmithingRecipe.Transform, GeyserSmithingRecipe.Trim
  • Constructor Summary

    Constructors
    Constructor
    Description
    Trim(int id, int netId, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay template, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay base, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay addition)
    Creates an instance of a Trim record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay
    Returns the value of the addition record component.
    List<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
     
    org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay
    Returns the value of the base record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    List<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
    getCraftingDataList(org.cloudburstmc.protocol.bedrock.packet.CraftingDataPacket craftingDataPacket)
     
    final int
    Returns a hash code value for this object.
    int
    id()
    Returns the value of the id record component.
    int
    Returns the value of the netId record component.
    of(int id, int netId, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.SmithingRecipeDisplay display)
     
    org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay
     
    org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay
    Returns the value of the template 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

    Methods inherited from interface org.geysermc.geyser.inventory.recipe.GeyserSmithingRecipe

    addToPacket, asRecipeData, isShaped, matches
  • Constructor Details

    • Trim

      public Trim(int id, int netId, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay template, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay base, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay addition)
      Creates an instance of a Trim record class.
      Parameters:
      id - the value for the id record component
      netId - the value for the netId record component
      template - the value for the template record component
      base - the value for the base record component
      addition - the value for the addition record component
  • Method Details

    • of

      public static GeyserSmithingRecipe.Trim of(int id, int netId, org.geysermc.mcprotocollib.protocol.data.game.recipe.display.SmithingRecipeDisplay display)
    • getCraftingDataList

      public List<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData> getCraftingDataList(org.cloudburstmc.protocol.bedrock.packet.CraftingDataPacket craftingDataPacket)
      Specified by:
      getCraftingDataList in interface GeyserSmithingRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
    • result

      public org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay result()
      Specified by:
      result in interface GeyserRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
    • asRecipeData

      public List<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData> asRecipeData(GeyserSession session)
      Specified by:
      asRecipeData in interface GeyserRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
    • 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.
    • id

      public int id()
      Returns the value of the id record component.
      Returns:
      the value of the id record component
    • netId

      public int netId()
      Returns the value of the netId record component.
      Returns:
      the value of the netId record component
    • template

      public org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay template()
      Returns the value of the template record component.
      Specified by:
      template in interface GeyserSmithingRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
      Returns:
      the value of the template record component
    • base

      public org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay base()
      Returns the value of the base record component.
      Specified by:
      base in interface GeyserSmithingRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
      Returns:
      the value of the base record component
    • addition

      public org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay addition()
      Returns the value of the addition record component.
      Specified by:
      addition in interface GeyserSmithingRecipe<org.cloudburstmc.protocol.bedrock.data.inventory.crafting.recipe.SmithingTrimRecipeData>
      Returns:
      the value of the addition record component