java.lang.Object
de.powerstat.validation.values.Department
- All Implemented Interfaces:
IValueObject
,Comparable<Department>
Address Department.
Not DSGVO relevant.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
compareTo
(Department obj) Compare with another object.boolean
Is equal with another object.int
hashCode()
Calculate hash code.static Department
Department factory.Returns the value of this Department as a string.toString()
Returns the string representation of this Department.
-
Field Details
-
DEPARTMENT_REGEXP
Department regexp. -
department
Department.
-
-
Constructor Details
-
Department
Constructor.- Parameters:
department
- Department name- Throws:
NullPointerException
- if department is nullIllegalArgumentException
- if department is not a correct department name
-
-
Method Details
-
of
Department factory.- Parameters:
department
- Department name- Returns:
- Department object
-
stringValue
Returns the value of this Department as a string.- Specified by:
stringValue
in interfaceIValueObject
- Returns:
- he text 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 Department. The exact details of this representation are unspecified and subject to change, but the following may be regarded as typical: "Department[department=Research]" -
compareTo
Compare with another object.- Specified by:
compareTo
in interfaceComparable<Department>
- Parameters:
obj
- Object to compare with- Returns:
- 0: equal; 1: greater; -1: smaller
- See Also:
-