ClassesRuleBuilder
A builder for compiling and verifying architectural rules on Kotlin classes.
Accumulates filtering conditions (that()) and assertions (should()), which are verified against all project classes by calling check.
Functions
Configures this builder to allow empty selections (i.e. if no classes match the that() filter, the rule will pass instead of throwing an AssertionError).
Logical AND operator for chaining filter conditions.
Logical AND operator for chaining assertion conditions.
Executes the built class rules against the specified project graph.
Logical NOT operator for negating the next filter condition.
Logical NOT operator for negating the next assertion condition.
Logical OR operator for chaining filter conditions.
Logical OR operator for chaining assertion conditions.
Starts adding assertion rules that the selected classes must satisfy.
Asserts rules on filtered classes using a lambda block that provides a ClassDeclarationShouldContext receiver.
Starts adding filtering conditions to select which classes to verify.
Filters classes in this rule using a concise lambda predicate evaluated on each ClassDeclaration.
Logical XOR (Exclusive OR) operator for chaining filter conditions.
Logical XOR (Exclusive OR) operator for chaining assertion conditions.