Package com.atlassian.bamboo.project
Class ProjectPredicates
java.lang.Object
com.atlassian.bamboo.project.ProjectPredicates
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic com.google.common.base.Predicate<Project>
isEmpty
(@NotNull CachedPlanManager cachedPlanManager) Returns predicate that filters project containing no plans.static com.google.common.base.Predicate<Project>
isNotEmpty
(@NotNull CachedPlanManager cachedPlanManager) Returns predicate that filters project containing at least one plan.withPlansThat
(@NotNull CachedPlanManager cachedPlanManager, Predicate<? super ImmutableChain> planFilter) Returns predicate that filters project containing plans that match given plan predicate.
-
Constructor Details
-
ProjectPredicates
public ProjectPredicates()
-
-
Method Details
-
withPlansThat
public static Predicate<Project> withPlansThat(@NotNull @NotNull CachedPlanManager cachedPlanManager, @NotNull Predicate<? super ImmutableChain> planFilter) Returns predicate that filters project containing plans that match given plan predicate. Predicate usesCachedPlanManager
to avoid unnecessary DB hits.- Parameters:
cachedPlanManager
-planFilter
-- Returns:
-
isEmpty
public static com.google.common.base.Predicate<Project> isEmpty(@NotNull @NotNull CachedPlanManager cachedPlanManager) Returns predicate that filters project containing no plans. Predicate usesCachedPlanManager
to avoid unnecessary DB hits.- Parameters:
cachedPlanManager
-- Returns:
-
isNotEmpty
public static com.google.common.base.Predicate<Project> isNotEmpty(@NotNull @NotNull CachedPlanManager cachedPlanManager) Returns predicate that filters project containing at least one plan. Predicate usesCachedPlanManager
to avoid unnecessary DB hits.- Parameters:
cachedPlanManager
-- Returns:
-