Record Class Category
java.lang.Object
java.lang.Record
io.github.matyrobbrt.curseforgeapi.schemas.Category
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionclassId()
Returns the value of theclassId
record component.Returns the value of thedateModified
record component.final boolean
Indicates whether some other object is "equal to" this one.int
gameId()
Returns the value of thegameId
record component.final int
hashCode()
Returns a hash code value for this object.iconUrl()
Returns the value of theiconUrl
record component.int
id()
Returns the value of theid
record component.boolean
isClass()
Returns the value of theisClass
record component.name()
Returns the value of thename
record component.Returns the value of theparentCategoryId
record component.slug()
Returns the value of theslug
record component.final String
toString()
Returns a string representation of this record class.url()
Returns the value of theurl
record component.
-
Constructor Details
-
Category
public Category(int id, int gameId, String name, String slug, String url, String iconUrl, String dateModified, boolean isClass, Integer classId, Integer parentCategoryId) Creates an instance of aCategory
record class.- Parameters:
id
- the value for theid
record componentgameId
- the value for thegameId
record componentname
- the value for thename
record componentslug
- the value for theslug
record componenturl
- the value for theurl
record componenticonUrl
- the value for theiconUrl
record componentdateModified
- the value for thedateModified
record componentisClass
- the value for theisClass
record componentclassId
- the value for theclassId
record componentparentCategoryId
- the value for theparentCategoryId
record component
-
-
Method Details
-
dateModifiedAsInstant
-
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. -
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. -
equals
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 withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
id
public int id()Returns the value of theid
record component.- Returns:
- the value of the
id
record component
-
gameId
public int gameId()Returns the value of thegameId
record component.- Returns:
- the value of the
gameId
record component
-
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-
slug
Returns the value of theslug
record component.- Returns:
- the value of the
slug
record component
-
url
Returns the value of theurl
record component.- Returns:
- the value of the
url
record component
-
iconUrl
Returns the value of theiconUrl
record component.- Returns:
- the value of the
iconUrl
record component
-
dateModified
Returns the value of thedateModified
record component.- Returns:
- the value of the
dateModified
record component
-
isClass
public boolean isClass()Returns the value of theisClass
record component.- Returns:
- the value of the
isClass
record component
-
classId
Returns the value of theclassId
record component.- Returns:
- the value of the
classId
record component
-
parentCategoryId
Returns the value of theparentCategoryId
record component.- Returns:
- the value of the
parentCategoryId
record component
-