Record Class SealedHierarchyDiagnostic
java.lang.Object
java.lang.Record
dev.archunitjava.model.SealedHierarchyDiagnostic
- All Implemented Interfaces:
Comparable<SealedHierarchyDiagnostic>
public record SealedHierarchyDiagnostic(SealedHierarchyDiagnosticCode code, Optional<JavaTypeName> relatedType)
extends Record
implements Comparable<SealedHierarchyDiagnostic>
One bounded inconsistency or gap in declared sealed-hierarchy evidence.
-
Constructor Summary
ConstructorsConstructorDescriptionSealedHierarchyDiagnostic(SealedHierarchyDiagnosticCode code, Optional<JavaTypeName> relatedType) Creates an instance of aSealedHierarchyDiagnosticrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncode()Returns the value of thecoderecord component.intfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of therelatedTyperecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SealedHierarchyDiagnostic
public SealedHierarchyDiagnostic(SealedHierarchyDiagnosticCode code, Optional<JavaTypeName> relatedType) Creates an instance of aSealedHierarchyDiagnosticrecord class.- Parameters:
code- the value for thecoderecord componentrelatedType- the value for therelatedTyperecord component
-
-
Method Details
-
compareTo
- Specified by:
compareToin interfaceComparable<SealedHierarchyDiagnostic>
-
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). -
code
Returns the value of thecoderecord component.- Returns:
- the value of the
coderecord component
-