Class InternalAccountQuery
java.lang.Object
com.google.gerrit.index.query.InternalQuery<AccountState,InternalAccountQuery>
com.google.gerrit.server.query.account.InternalAccountQuery
Query wrapper for the account index.
Instances are one-time-use. Other singleton classes should inject a Provider rather than holding on to a single instance.
-
Field Summary
Fields inherited from class com.google.gerrit.index.query.InternalQuery
indexConfig, indexes
-
Method Summary
Modifier and TypeMethodDescriptionbyExternalId
(ExternalId.Key externalId) byExternalId
(String scheme, String id) byFullName
(String fullName) byPreferredEmail
(String email) Queries for accounts that have a preferred email that exactly matches the given email.com.google.common.collect.Multimap<String,
AccountState> byPreferredEmail
(List<String> emails) Makes multiple queries for accounts by preferred email (exact match).byWatchedProject
(Project.NameKey project) oneByExternalId
(ExternalId.Key externalId) Methods inherited from class com.google.gerrit.index.query.InternalQuery
enforceVisibility, noFields, query, query, queryExhaustively, schema, self, setLimit, setRequestedFields
-
Method Details
-
byDefault
-
byExternalId
-
byExternalId
-
oneByExternalId
-
byFullName
-
byPreferredEmail
Queries for accounts that have a preferred email that exactly matches the given email.- Parameters:
email
- preferred email by which accounts should be found- Returns:
- list of accounts that have a preferred email that exactly matches the given email
-
byPreferredEmail
public com.google.common.collect.Multimap<String,AccountState> byPreferredEmail(List<String> emails) Makes multiple queries for accounts by preferred email (exact match).- Parameters:
emails
- preferred emails by which accounts should be found- Returns:
- multimap of the given emails to accounts that have a preferred email that exactly matches this email
-
byWatchedProject
-