Record Class AnnotationSite
java.lang.Object
java.lang.Record
dev.archunitjava.model.AnnotationSite
public record AnnotationSite(AnnotationSiteKind kind, String ownerKey, OptionalInt parameterIndex, Optional<JavaTypeUseTarget> typeUseTarget)
extends Record
Exact owner and sub-location of an annotation occurrence.
-
Constructor Summary
ConstructorsConstructorDescriptionAnnotationSite(AnnotationSiteKind kind, String ownerKey, OptionalInt parameterIndex, Optional<JavaTypeUseTarget> typeUseTarget) Creates an instance of aAnnotationSiterecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.kind()Returns the value of thekindrecord component.ownerKey()Returns the value of theownerKeyrecord component.Returns the value of theparameterIndexrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetypeUseTargetrecord component.
-
Constructor Details
-
AnnotationSite
public AnnotationSite(AnnotationSiteKind kind, String ownerKey, OptionalInt parameterIndex, Optional<JavaTypeUseTarget> typeUseTarget) Creates an instance of aAnnotationSiterecord class.- Parameters:
kind- the value for thekindrecord componentownerKey- the value for theownerKeyrecord componentparameterIndex- the value for theparameterIndexrecord componenttypeUseTarget- the value for thetypeUseTargetrecord component
-
-
Method Details
-
stableKey
-
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). -
kind
Returns the value of thekindrecord component.- Returns:
- the value of the
kindrecord component
-
ownerKey
Returns the value of theownerKeyrecord component.- Returns:
- the value of the
ownerKeyrecord component
-
parameterIndex
Returns the value of theparameterIndexrecord component.- Returns:
- the value of the
parameterIndexrecord component
-
typeUseTarget
Returns the value of thetypeUseTargetrecord component.- Returns:
- the value of the
typeUseTargetrecord component
-