Package com.hazelcast.test.archunit
Class UseConsistentNullabilityAnnotationCondition
java.lang.Object
com.tngtech.archunit.lang.ArchCondition<com.tngtech.archunit.core.domain.JavaClass>
com.hazelcast.test.archunit.UseConsistentNullabilityAnnotationCondition
public class UseConsistentNullabilityAnnotationCondition
extends com.tngtech.archunit.lang.ArchCondition<com.tngtech.archunit.core.domain.JavaClass>
There are many different flavours of Java
nullability annotation, and it's easily to be inconsistent, especially when
several are imported from transitive dependencies and often an IDE decides which one to import. Hence, we need to assert our
chosen flavour of annotation is the only one in use.-
Nested Class Summary
Nested classes/interfaces inherited from class com.tngtech.archunit.lang.ArchCondition
com.tngtech.archunit.lang.ArchCondition.ConditionByPredicate<T extends com.tngtech.archunit.base.HasDescription & com.tngtech.archunit.core.domain.properties.HasSourceCodeLocation> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcheck(com.tngtech.archunit.core.domain.JavaClass item, com.tngtech.archunit.lang.ConditionEvents events) static com.tngtech.archunit.lang.ArchCondition<com.tngtech.archunit.core.domain.JavaClass>Methods inherited from class com.tngtech.archunit.lang.ArchCondition
and, as, finish, forSubtype, from, getDescription, init, or, toString
-
Constructor Details
-
UseConsistentNullabilityAnnotationCondition
public UseConsistentNullabilityAnnotationCondition()
-
-
Method Details
-
check
public void check(com.tngtech.archunit.core.domain.JavaClass item, com.tngtech.archunit.lang.ConditionEvents events) - Specified by:
checkin classcom.tngtech.archunit.lang.ArchCondition<com.tngtech.archunit.core.domain.JavaClass>
-
useConsistentNullabilityAnnotation
public static com.tngtech.archunit.lang.ArchCondition<com.tngtech.archunit.core.domain.JavaClass> useConsistentNullabilityAnnotation()
-