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 TypeMethodDescriptionintCompare with another object.booleanIs equal with another object.inthashCode()Calculate hash code.static UUIDof()UUID factory.static UUIDUUID 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:
stringValuein 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:
compareToin interfaceComparable<UUID>- Parameters:
obj- Object to compare with- Returns:
- 0: equal; 1: greater; -1: smaller
- See Also:
-