Record Class ContentCounts

java.lang.Object
java.lang.Record
com.ultikits.ultitools.bootstrap.ContentCounts

record ContentCounts(int enchantments, int tags, int datapacks) extends Record
Counts distinct content keys for the early log and the translated console report.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final int
    The field for the datapacks record component.
    private final int
    The field for the enchantments record component.
    private final int
    The field for the tags record component.
  • Constructor Summary

    Constructors
    Constructor
    Description
    ContentCounts(int enchantments, int tags, int datapacks)
    Creates an instance of a ContentCounts record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    (package private) Arg[]
     
    private static int
    count(List<ContentEntry> entries, String kind)
     
    int
    Returns the value of the datapacks record component.
    int
    Returns the value of the enchantments record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    (package private) static String
     
    (package private) static ContentCounts
    of(List<ContentEntry> entries)
     
    int
    Returns the value of the tags record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class Object

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

    • enchantments

      private final int enchantments
      The field for the enchantments record component.
    • tags

      private final int tags
      The field for the tags record component.
    • datapacks

      private final int datapacks
      The field for the datapacks record component.
  • Constructor Details

    • ContentCounts

      ContentCounts(int enchantments, int tags, int datapacks)
      Creates an instance of a ContentCounts record class.
      Parameters:
      enchantments - the value for the enchantments record component
      tags - the value for the tags record component
      datapacks - the value for the datapacks record component
  • Method Details

    • of

      static ContentCounts of(List<ContentEntry> entries)
    • kind

      static String kind(ContentEntry entry)
    • count

      private static int count(List<ContentEntry> entries, String kind)
    • args

      Arg[] args()
    • 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 the compare method from their corresponding wrapper classes.
      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.
    • enchantments

      public int enchantments()
      Returns the value of the enchantments record component.
      Returns:
      the value of the enchantments record component
    • tags

      public int tags()
      Returns the value of the tags record component.
      Returns:
      the value of the tags record component
    • datapacks

      public int datapacks()
      Returns the value of the datapacks record component.
      Returns:
      the value of the datapacks record component