Record Class JavaAnnotationValue.EnumValue
java.lang.Object
java.lang.Record
dev.archunitjava.model.JavaAnnotationValue.EnumValue
- All Implemented Interfaces:
JavaAnnotationValue, Comparable<JavaAnnotationValue>
- Enclosing interface:
JavaAnnotationValue
public static record JavaAnnotationValue.EnumValue(JvmReferenceType enumType, String constantName)
extends Record
implements JavaAnnotationValue
-
Nested Class Summary
Nested classes/interfaces inherited from interface JavaAnnotationValue
JavaAnnotationValue.ArrayValue, JavaAnnotationValue.ClassValue, JavaAnnotationValue.EnumValue, JavaAnnotationValue.NestedAnnotationValue, JavaAnnotationValue.ScalarKind, JavaAnnotationValue.ScalarValue -
Constructor Summary
ConstructorsConstructorDescriptionEnumValue(JvmReferenceType enumType, String constantName) Creates an instance of aEnumValuerecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theconstantNamerecord component.enumType()Returns the value of theenumTyperecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.Methods inherited from interface JavaAnnotationValue
compareTo
-
Constructor Details
-
EnumValue
Creates an instance of aEnumValuerecord class.- Parameters:
enumType- the value for theenumTyperecord componentconstantName- the value for theconstantNamerecord component
-
-
Method Details
-
stableKey
- Specified by:
stableKeyin interfaceJavaAnnotationValue
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
enumType
Returns the value of theenumTyperecord component.- Returns:
- the value of the
enumTyperecord component
-
constantName
Returns the value of theconstantNamerecord component.- Returns:
- the value of the
constantNamerecord component
-