Record Class TemplateData<C>

java.lang.Object
java.lang.Record
dev.aurelium.slate.item.TemplateData<C>

public record TemplateData<C>(Map<C,PositionProvider> positions, Map<C,org.bukkit.inventory.ItemStack> baseItems, Map<C,String> displayNames, Map<C,List<LoreLine>> lore, Map<C,ItemConditions> conditions, Map<C,ItemActions> actions, List<TemplateVariant<C>> variants) extends Record
  • Constructor Details

    • TemplateData

      public TemplateData(Map<C,PositionProvider> positions, Map<C,org.bukkit.inventory.ItemStack> baseItems, Map<C,String> displayNames, Map<C,List<LoreLine>> lore, Map<C,ItemConditions> conditions, Map<C,ItemActions> actions, List<TemplateVariant<C>> variants)
      Creates an instance of a TemplateData record class.
      Parameters:
      positions - the value for the positions record component
      baseItems - the value for the baseItems record component
      displayNames - the value for the displayNames record component
      lore - the value for the lore record component
      conditions - the value for the conditions record component
      actions - the value for the actions record component
      variants - the value for the variants 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.
    • positions

      public Map<C,PositionProvider> positions()
      Returns the value of the positions record component.
      Returns:
      the value of the positions record component
    • baseItems

      public Map<C,org.bukkit.inventory.ItemStack> baseItems()
      Returns the value of the baseItems record component.
      Returns:
      the value of the baseItems record component
    • displayNames

      public Map<C,String> displayNames()
      Returns the value of the displayNames record component.
      Returns:
      the value of the displayNames record component
    • lore

      public Map<C,List<LoreLine>> lore()
      Returns the value of the lore record component.
      Returns:
      the value of the lore record component
    • conditions

      public Map<C,ItemConditions> conditions()
      Returns the value of the conditions record component.
      Returns:
      the value of the conditions record component
    • actions

      public Map<C,ItemActions> actions()
      Returns the value of the actions record component.
      Returns:
      the value of the actions record component
    • variants

      public List<TemplateVariant<C>> variants()
      Returns the value of the variants record component.
      Returns:
      the value of the variants record component