Interface GivenCodeUnitsConjunction<CODE_UNIT extends JavaCodeUnit>
-
- All Superinterfaces:
GivenConjunction<CODE_UNIT>,GivenMembersConjunction<CODE_UNIT>
- All Known Subinterfaces:
GivenConstructorsConjunction,GivenMethodsConjunction
public interface GivenCodeUnitsConjunction<CODE_UNIT extends JavaCodeUnit> extends GivenMembersConjunction<CODE_UNIT>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CodeUnitsThat<? extends GivenCodeUnitsConjunction<CODE_UNIT>>and()GivenCodeUnitsConjunction<CODE_UNIT>and(DescribedPredicate<? super CODE_UNIT> predicate)Combines the current predicate (e.g.CodeUnitsThat<? extends GivenCodeUnitsConjunction<CODE_UNIT>>or()GivenCodeUnitsConjunction<CODE_UNIT>or(DescribedPredicate<? super CODE_UNIT> predicate)Combines the current predicate (e.g.CodeUnitsShould<? extends CodeUnitsShouldConjunction<CODE_UNIT>>should()CodeUnitsShouldConjunction<CODE_UNIT>should(ArchCondition<? super CODE_UNIT> condition)
-
-
-
Method Detail
-
and
@PublicAPI(usage=ACCESS) CodeUnitsThat<? extends GivenCodeUnitsConjunction<CODE_UNIT>> and()
- Specified by:
andin interfaceGivenMembersConjunction<CODE_UNIT extends JavaCodeUnit>
-
or
@PublicAPI(usage=ACCESS) CodeUnitsThat<? extends GivenCodeUnitsConjunction<CODE_UNIT>> or()
- Specified by:
orin interfaceGivenMembersConjunction<CODE_UNIT extends JavaCodeUnit>
-
and
@PublicAPI(usage=ACCESS) GivenCodeUnitsConjunction<CODE_UNIT> and(DescribedPredicate<? super CODE_UNIT> predicate)
Description copied from interface:GivenConjunctionCombines the current predicate (e.g.simpleName== 'SomeClass') with another predicate (e.g.resideInAPackage'foo.bar') using AND (i.e. both predicates must be satisfied).
NOTE:
GivenConjunction.and(DescribedPredicate)andGivenConjunction.or(DescribedPredicate)combine predicates in the sequence they are declared, without any "operator precedence". I.e.
all(objects()).that(predicateA).or(predicateB).and(predicateC)...will filter on predicate
(predicateA || predicateB) && predicateC, and
all(objects()).that(predicateA).and(predicateB).or(predicateC)...will filter on predicate
(predicateA && predicateB) || predicateC. If you need more control over the precedence, how predicates are joined, you have to join these predicates separately, i.e.
all(objects()).that(predicateA.or(predicateB.and(predicateC)))...- Specified by:
andin interfaceGivenConjunction<CODE_UNIT extends JavaCodeUnit>- Specified by:
andin interfaceGivenMembersConjunction<CODE_UNIT extends JavaCodeUnit>- Parameters:
predicate- The predicate to be ANDed on the current object filter predicate- Returns:
- A syntax conjunction element, which can be completed to form a full rule
-
or
@PublicAPI(usage=ACCESS) GivenCodeUnitsConjunction<CODE_UNIT> or(DescribedPredicate<? super CODE_UNIT> predicate)
Description copied from interface:GivenConjunctionCombines the current predicate (e.g.simpleName== 'SomeClass') with another predicate (e.g.resideInAPackage'foo.bar') using OR (i.e. at least one of the predicates must be satisfied).
NOTE: For considerations about precedence, when joining predicates, consider note at
GivenConjunction.and(DescribedPredicate)- Specified by:
orin interfaceGivenConjunction<CODE_UNIT extends JavaCodeUnit>- Specified by:
orin interfaceGivenMembersConjunction<CODE_UNIT extends JavaCodeUnit>- Parameters:
predicate- The predicate to be ORed on the current object filter predicate- Returns:
- A syntax conjunction element, which can be completed to form a full rule
-
should
@PublicAPI(usage=ACCESS) CodeUnitsShouldConjunction<CODE_UNIT> should(ArchCondition<? super CODE_UNIT> condition)
- Specified by:
shouldin interfaceGivenConjunction<CODE_UNIT extends JavaCodeUnit>- Specified by:
shouldin interfaceGivenMembersConjunction<CODE_UNIT extends JavaCodeUnit>
-
should
@PublicAPI(usage=ACCESS) CodeUnitsShould<? extends CodeUnitsShouldConjunction<CODE_UNIT>> should()
- Specified by:
shouldin interfaceGivenMembersConjunction<CODE_UNIT extends JavaCodeUnit>
-
-