Record Class Warp
java.lang.Object
java.lang.Record
fr.mathildeuh.youneedme.api.model.Warp
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable Stringcategory()Returns the value of thecategoryrecord component.doublecost()Returns the value of thecostrecord component.longReturns the value of thecreatedAtrecord component.@Nullable UUIDReturns the value of thecreatedByrecord component.@Nullable StringReturns the value of thedescriptionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanhidden()Returns the value of thehiddenrecord component.name()Returns the value of thenamerecord component.@Nullable StringReturns the value of thepermissionrecord component.position()Returns the value of thepositionrecord component.final StringtoString()Returns a string representation of this record class.withCategory(@Nullable String newCategory) withCost(double newCost) withDescription(@Nullable String newDescription) withHidden(boolean newHidden) withPermission(@Nullable String newPermission) withPosition(Position newPosition)
-
Constructor Details
-
Warp
public Warp(String name, Position position, @Nullable @Nullable String category, @Nullable @Nullable String permission, double cost, @Nullable @Nullable String description, boolean hidden, @Nullable @Nullable UUID createdBy, long createdAt) Creates an instance of aWarprecord class.- Parameters:
name- the value for thenamerecord componentposition- the value for thepositionrecord componentcategory- the value for thecategoryrecord componentpermission- the value for thepermissionrecord componentcost- the value for thecostrecord componentdescription- the value for thedescriptionrecord componenthidden- the value for thehiddenrecord componentcreatedBy- the value for thecreatedByrecord componentcreatedAt- the value for thecreatedAtrecord component
-
-
Method Details
-
withPosition
-
withPermission
-
withCost
-
withDescription
-
withCategory
-
withHidden
-
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. -
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
position
Returns the value of thepositionrecord component.- Returns:
- the value of the
positionrecord component
-
category
Returns the value of thecategoryrecord component.- Returns:
- the value of the
categoryrecord component
-
permission
Returns the value of thepermissionrecord component.- Returns:
- the value of the
permissionrecord component
-
cost
public double cost()Returns the value of thecostrecord component.- Returns:
- the value of the
costrecord component
-
description
Returns the value of thedescriptionrecord component.- Returns:
- the value of the
descriptionrecord component
-
createdBy
Returns the value of thecreatedByrecord component.- Returns:
- the value of the
createdByrecord component
-
createdAt
public long createdAt()Returns the value of thecreatedAtrecord component.- Returns:
- the value of the
createdAtrecord component
-