Record Class AnnotationQuery
java.lang.Object
java.lang.Record
dev.archunitjava.selector.AnnotationQuery
public record AnnotationQuery(JavaTypeName annotationType, AnnotationMatchMode mode, Optional<AnnotationVisibility> visibility, int maximumMetaDepth, UnknownHierarchyPolicy unknownPolicy)
extends Record
Immutable annotation target, relationship, visibility, traversal bound, and unknown policy.
-
Constructor Summary
ConstructorsConstructorDescriptionAnnotationQuery(JavaTypeName annotationType, AnnotationMatchMode mode, Optional<AnnotationVisibility> visibility, int maximumMetaDepth, UnknownHierarchyPolicy unknownPolicy) Creates an instance of aAnnotationQueryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theannotationTyperecord component.static AnnotationQueryfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static AnnotationQueryintReturns the value of themaximumMetaDepthrecord component.static AnnotationQuerymetaAnnotated(String annotationBinaryName) mode()Returns the value of themoderecord component.final StringtoString()Returns a string representation of this record class.static AnnotationQueryReturns the value of theunknownPolicyrecord component.Returns the value of thevisibilityrecord component.withMaximumMetaDepth(int value)
-
Constructor Details
-
AnnotationQuery
public AnnotationQuery(JavaTypeName annotationType, AnnotationMatchMode mode, Optional<AnnotationVisibility> visibility, int maximumMetaDepth, UnknownHierarchyPolicy unknownPolicy) Creates an instance of aAnnotationQueryrecord class.- Parameters:
annotationType- the value for theannotationTyperecord componentmode- the value for themoderecord componentvisibility- the value for thevisibilityrecord componentmaximumMetaDepth- the value for themaximumMetaDepthrecord componentunknownPolicy- the value for theunknownPolicyrecord component
-
-
Method Details
-
direct
-
metaAnnotated
-
inherited
-
typeUse
-
withVisibility
-
withMaximumMetaDepth
-
withUnknownPolicy
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
annotationType
Returns the value of theannotationTyperecord component.- Returns:
- the value of the
annotationTyperecord component
-
mode
Returns the value of themoderecord component.- Returns:
- the value of the
moderecord component
-
visibility
Returns the value of thevisibilityrecord component.- Returns:
- the value of the
visibilityrecord component
-
maximumMetaDepth
public int maximumMetaDepth()Returns the value of themaximumMetaDepthrecord component.- Returns:
- the value of the
maximumMetaDepthrecord component
-
unknownPolicy
Returns the value of theunknownPolicyrecord component.- Returns:
- the value of the
unknownPolicyrecord component
-