Class AndChangeSource
- java.lang.Object
-
- com.google.gerrit.index.query.Predicate<T>
-
- com.google.gerrit.index.query.AndPredicate<T>
-
- com.google.gerrit.index.query.AndSource<ChangeData>
-
- com.google.gerrit.server.query.change.AndChangeSource
-
- All Implemented Interfaces:
DataSource<ChangeData>
,Matchable<ChangeData>
,ChangeDataSource
,Comparator<Predicate<ChangeData>>
public class AndChangeSource extends AndSource<ChangeData> implements ChangeDataSource
-
-
Constructor Summary
Constructors Constructor Description AndChangeSource(Predicate<ChangeData> that, IsVisibleToPredicate<ChangeData> isVisibleToPredicate, int start)
AndChangeSource(Collection<Predicate<ChangeData>> that)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(Predicate<ChangeData> a, Predicate<ChangeData> b)
boolean
hasChange()
protected List<ChangeData>
transformBuffer(List<ChangeData> buffer)
-
Methods inherited from class com.google.gerrit.index.query.AndSource
getCardinality, isMatchable, match, read, readRaw
-
Methods inherited from class com.google.gerrit.index.query.AndPredicate
copy, equals, getChild, getChildCount, getChildren, getCost, hashCode, toString
-
Methods inherited from class com.google.gerrit.index.query.Predicate
and, and, any, asMatchable, estimateCost, getLeafCount, not, or, or
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Methods inherited from interface com.google.gerrit.index.query.DataSource
getCardinality, read, readRaw
-
-
-
-
Constructor Detail
-
AndChangeSource
public AndChangeSource(Collection<Predicate<ChangeData>> that)
-
AndChangeSource
public AndChangeSource(Predicate<ChangeData> that, IsVisibleToPredicate<ChangeData> isVisibleToPredicate, int start)
-
-
Method Detail
-
hasChange
public boolean hasChange()
- Specified by:
hasChange
in interfaceChangeDataSource
- Returns:
- true if all returned ChangeData.hasChange() will be true.
-
transformBuffer
protected List<ChangeData> transformBuffer(List<ChangeData> buffer)
- Overrides:
transformBuffer
in classAndSource<ChangeData>
-
compare
public int compare(Predicate<ChangeData> a, Predicate<ChangeData> b)
- Specified by:
compare
in interfaceComparator<Predicate<ChangeData>>
- Overrides:
compare
in classAndSource<ChangeData>
-
-