java.lang.Object
de.powerstat.validation.values.UUID
- All Implemented Interfaces:
IValueObject
,Comparable<UUID>
Universally Unique Identifier.
Possibly DSGVO relevant.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
Compare with another object.boolean
Is equal with another object.int
hashCode()
Calculate hash code.static UUID
of()
UUID factory.static UUID
UUID factory.Returns the value of this UUID as an String.toString()
Returns the string representation of this UUID.
-
Field Details
-
uuid
UUID.
-
-
Constructor Details
-
UUID
private UUID()Default constructor. -
UUID
Constructor.- Parameters:
value
- UUID string value
-
-
Method Details
-
of
UUID factory.- Returns:
- UUID object
-
of
UUID factory.- Parameters:
value
- UUID string- Returns:
- UUID object
-
stringValue
Returns the value of this UUID as an String.- Specified by:
stringValue
in interfaceIValueObject
- Returns:
- The numeric value represented by this object after conversion to type String.
-
hashCode
public int hashCode()Calculate hash code. -
equals
Is equal with another object. -
toString
Returns the string representation of this UUID. The exact details of this representation are unspecified and subject to change, but the following may be regarded as typical: "UUID[uuid=e58ed763-928c-4155-bee9-fdbaaadc15f3]" -
compareTo
Compare with another object.- Specified by:
compareTo
in interfaceComparable<UUID>
- Parameters:
obj
- Object to compare with- Returns:
- 0: equal; 1: greater; -1: smaller
- See Also:
-