Class AccountIndexRewriter
- java.lang.Object
-
- com.google.gerrit.server.index.account.AccountIndexRewriter
-
- All Implemented Interfaces:
IndexRewriter<AccountState>
public class AccountIndexRewriter extends Object implements IndexRewriter<AccountState>
Rewriter for the account index. SeeIndexRewriter
for details.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Predicate<AccountState>
rewrite(Predicate<AccountState> in, QueryOptions opts)
Returns a sanitized version of the provided predicate.void
validateMaxTermsInQuery(Predicate<AccountState> predicate)
Validates whether a query has too many terms.
-
-
-
Method Detail
-
rewrite
public Predicate<AccountState> rewrite(Predicate<AccountState> in, QueryOptions opts) throws QueryParseException
Description copied from interface:IndexRewriter
Returns a sanitized version of the provided predicate. UsesQueryOptions
to enforce index-specific limits such asmaxTerms
.- Specified by:
rewrite
in interfaceIndexRewriter<AccountState>
- Throws:
QueryParseException
-
validateMaxTermsInQuery
public void validateMaxTermsInQuery(Predicate<AccountState> predicate) throws QueryParseException
Validates whether a query has too many terms.- Parameters:
predicate
- the predicate for which the leaf predicates should be counted- Throws:
QueryParseException
- thrown if the query has too many terms
-
-