Package at.petrak.paucal.api.contrib
Record Class ContributorType
java.lang.Object
java.lang.Record
at.petrak.paucal.api.contrib.ContributorType
-
Constructor Summary
ConstructorsConstructorDescriptionContributorType(int level, boolean isDev, boolean isCool) Creates an instance of aContributorTyperecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanisCool()Returns the value of theisCoolrecord component.booleanisDev()Returns the value of theisDevrecord component.intlevel()Returns the value of thelevelrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ContributorType
public ContributorType(int level, boolean isDev, boolean isCool) Creates an instance of aContributorTyperecord class.- Parameters:
level- the value for thelevelrecord componentisDev- the value for theisDevrecord componentisCool- the value for theisCoolrecord component
-
-
Method Details
-
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. All components in this record class are compared with '=='. -
level
public int level()Returns the value of thelevelrecord component.- Returns:
- the value of the
levelrecord component
-
isDev
public boolean isDev()Returns the value of theisDevrecord component.- Returns:
- the value of the
isDevrecord component
-
isCool
public boolean isCool()Returns the value of theisCoolrecord component.- Returns:
- the value of the
isCoolrecord component
-