public class InternalAccountQuery extends InternalQuery<AccountState>
Instances are one-time-use. Other singleton classes should inject a Provider rather than holding on to a single instance.
indexConfig
Modifier and Type | Method and Description |
---|---|
List<AccountState> |
byDefault(String query) |
List<AccountState> |
byExternalId(ExternalId.Key externalId) |
List<AccountState> |
byExternalId(String scheme,
String id) |
List<AccountState> |
byFullName(String fullName) |
com.google.common.collect.Multimap<String,AccountState> |
byPreferredEmail(String... emails)
Makes multiple queries for accounts by preferred email (exact match).
|
List<AccountState> |
byPreferredEmail(String email)
Queries for accounts that have a preferred email that exactly matches the given email.
|
List<AccountState> |
byWatchedProject(Project.NameKey project) |
InternalAccountQuery |
enforceVisibility(boolean enforce) |
InternalAccountQuery |
noFields() |
AccountState |
oneByExternalId(ExternalId.Key externalId) |
InternalAccountQuery |
setLimit(int n) |
InternalAccountQuery |
setRequestedFields(FieldDef<AccountState,?>... fields) |
query, query, schema
public InternalAccountQuery setLimit(int n)
setLimit
in class InternalQuery<AccountState>
public InternalAccountQuery enforceVisibility(boolean enforce)
enforceVisibility
in class InternalQuery<AccountState>
@SafeVarargs public final InternalAccountQuery setRequestedFields(FieldDef<AccountState,?>... fields)
setRequestedFields
in class InternalQuery<AccountState>
public InternalAccountQuery noFields()
noFields
in class InternalQuery<AccountState>
public List<AccountState> byDefault(String query) throws com.google.gwtorm.server.OrmException
com.google.gwtorm.server.OrmException
public List<AccountState> byExternalId(String scheme, String id) throws com.google.gwtorm.server.OrmException
com.google.gwtorm.server.OrmException
public List<AccountState> byExternalId(ExternalId.Key externalId) throws com.google.gwtorm.server.OrmException
com.google.gwtorm.server.OrmException
public AccountState oneByExternalId(ExternalId.Key externalId) throws com.google.gwtorm.server.OrmException
com.google.gwtorm.server.OrmException
public List<AccountState> byFullName(String fullName) throws com.google.gwtorm.server.OrmException
com.google.gwtorm.server.OrmException
public List<AccountState> byPreferredEmail(String email) throws com.google.gwtorm.server.OrmException
email
- preferred email by which accounts should be foundcom.google.gwtorm.server.OrmException
- if query cannot be parsedpublic com.google.common.collect.Multimap<String,AccountState> byPreferredEmail(String... emails) throws com.google.gwtorm.server.OrmException
emails
- preferred emails by which accounts should be foundcom.google.gwtorm.server.OrmException
- if query cannot be parsedpublic List<AccountState> byWatchedProject(Project.NameKey project) throws com.google.gwtorm.server.OrmException
com.google.gwtorm.server.OrmException