Record Class User
java.lang.Object
java.lang.Record
ch.martinelli.mite4java.domain.User
public record User(int id, String name, String email, String note, boolean archived, String role, String language, OffsetDateTime createdAt, OffsetDateTime updatedAt)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionUser(int id, String name, String email, String note, boolean archived, String role, String language, OffsetDateTime createdAt, OffsetDateTime updatedAt) Creates an instance of aUserrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanarchived()Returns the value of thearchivedrecord component.Returns the value of thecreatedAtrecord component.email()Returns the value of theemailrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intid()Returns the value of theidrecord component.language()Returns the value of thelanguagerecord component.name()Returns the value of thenamerecord component.note()Returns the value of thenoterecord component.role()Returns the value of therolerecord component.final StringtoString()Returns a string representation of this record class.Returns the value of theupdatedAtrecord component.
-
Constructor Details
-
User
public User(int id, String name, String email, String note, boolean archived, String role, String language, OffsetDateTime createdAt, OffsetDateTime updatedAt) Creates an instance of aUserrecord class.- Parameters:
id- the value for theidrecord componentname- the value for thenamerecord componentemail- the value for theemailrecord componentnote- the value for thenoterecord componentarchived- the value for thearchivedrecord componentrole- the value for therolerecord componentlanguage- the value for thelanguagerecord componentcreatedAt- the value for thecreatedAtrecord componentupdatedAt- the value for theupdatedAtrecord component
-
-
Method Details
-
toString
-
hashCode
-
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 thecomparemethod from their corresponding wrapper classes. -
id
public int id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
email
Returns the value of theemailrecord component.- Returns:
- the value of the
emailrecord component
-
note
Returns the value of thenoterecord component.- Returns:
- the value of the
noterecord component
-
archived
public boolean archived()Returns the value of thearchivedrecord component.- Returns:
- the value of the
archivedrecord component
-
role
Returns the value of therolerecord component.- Returns:
- the value of the
rolerecord component
-
language
Returns the value of thelanguagerecord component.- Returns:
- the value of the
languagerecord component
-
createdAt
Returns the value of thecreatedAtrecord component.- Returns:
- the value of the
createdAtrecord component
-
updatedAt
Returns the value of theupdatedAtrecord component.- Returns:
- the value of the
updatedAtrecord component
-