java.lang.Object
java.lang.Record
io.github.matyrobbrt.curseforgeapi.schemas.mod.Mod

@CurseForgeSchema("https://docs.curseforge.com/#schemamod") public record Mod(int id, int gameId, String name, String slug, ModLinks links, String summary, ModStatus status, double downloadCount, boolean isFeatured, int primaryCategoryId, List<Category> categories, Integer classId, List<ModAuthor> authors, ModAsset logo, List<ModAsset> screenshots, int mainFileId, List<File> latestFiles, List<FileIndex> latestFilesIndexes, String dateModified, String dateReleased, Boolean allowModDistribution, int gamePopularityRank) extends Record
  • Constructor Details

    • Mod

      public Mod(int id, int gameId, String name, String slug, ModLinks links, String summary, ModStatus status, double downloadCount, boolean isFeatured, int primaryCategoryId, List<Category> categories, Integer classId, List<ModAuthor> authors, ModAsset logo, List<ModAsset> screenshots, int mainFileId, List<File> latestFiles, List<FileIndex> latestFilesIndexes, String dateModified, String dateReleased, Boolean allowModDistribution, int gamePopularityRank)
      Creates an instance of a Mod record class.
      Parameters:
      id - the value for the id record component
      gameId - the value for the gameId record component
      name - the value for the name record component
      slug - the value for the slug record component
      links - the value for the links record component
      summary - the value for the summary record component
      status - the value for the status record component
      downloadCount - the value for the downloadCount record component
      isFeatured - the value for the isFeatured record component
      primaryCategoryId - the value for the primaryCategoryId record component
      categories - the value for the categories record component
      classId - the value for the classId record component
      authors - the value for the authors record component
      logo - the value for the logo record component
      screenshots - the value for the screenshots record component
      mainFileId - the value for the mainFileId record component
      latestFiles - the value for the latestFiles record component
      latestFilesIndexes - the value for the latestFilesIndexes record component
      dateModified - the value for the dateModified record component
      dateReleased - the value for the dateReleased record component
      allowModDistribution - the value for the allowModDistribution record component
      gamePopularityRank - the value for the gamePopularityRank record component
  • Method Details

    • getDateModifiedAsInstant

      public Instant getDateModifiedAsInstant()
    • getDateReleasedAsInstant

      public Instant getDateReleasedAsInstant()
    • 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
    • gameId

      public int gameId()
      Returns the value of the gameId record component.
      Returns:
      the value of the gameId record component
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • slug

      public String slug()
      Returns the value of the slug record component.
      Returns:
      the value of the slug record component
    • links

      public ModLinks links()
      Returns the value of the links record component.
      Returns:
      the value of the links record component
    • summary

      public String summary()
      Returns the value of the summary record component.
      Returns:
      the value of the summary record component
    • status

      public ModStatus status()
      Returns the value of the status record component.
      Returns:
      the value of the status record component
    • downloadCount

      public double downloadCount()
      Returns the value of the downloadCount record component.
      Returns:
      the value of the downloadCount record component
    • isFeatured

      public boolean isFeatured()
      Returns the value of the isFeatured record component.
      Returns:
      the value of the isFeatured record component
    • primaryCategoryId

      public int primaryCategoryId()
      Returns the value of the primaryCategoryId record component.
      Returns:
      the value of the primaryCategoryId record component
    • categories

      public List<Category> categories()
      Returns the value of the categories record component.
      Returns:
      the value of the categories record component
    • classId

      public Integer classId()
      Returns the value of the classId record component.
      Returns:
      the value of the classId record component
    • authors

      public List<ModAuthor> authors()
      Returns the value of the authors record component.
      Returns:
      the value of the authors record component
    • logo

      public ModAsset logo()
      Returns the value of the logo record component.
      Returns:
      the value of the logo record component
    • screenshots

      public List<ModAsset> screenshots()
      Returns the value of the screenshots record component.
      Returns:
      the value of the screenshots record component
    • mainFileId

      public int mainFileId()
      Returns the value of the mainFileId record component.
      Returns:
      the value of the mainFileId record component
    • latestFiles

      public List<File> latestFiles()
      Returns the value of the latestFiles record component.
      Returns:
      the value of the latestFiles record component
    • latestFilesIndexes

      public List<FileIndex> latestFilesIndexes()
      Returns the value of the latestFilesIndexes record component.
      Returns:
      the value of the latestFilesIndexes record component
    • dateModified

      public String dateModified()
      Returns the value of the dateModified record component.
      Returns:
      the value of the dateModified record component
    • dateReleased

      public String dateReleased()
      Returns the value of the dateReleased record component.
      Returns:
      the value of the dateReleased record component
    • allowModDistribution

      public Boolean allowModDistribution()
      Returns the value of the allowModDistribution record component.
      Returns:
      the value of the allowModDistribution record component
    • gamePopularityRank

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