Class Accounts.NotImplemented
java.lang.Object
com.google.gerrit.extensions.api.accounts.Accounts.NotImplemented
- All Implemented Interfaces:
Accounts
- Enclosing interface:
- Accounts
A default implementation which allows source compatibility when adding new methods to the
interface.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.google.gerrit.extensions.api.accounts.Accounts
Accounts.NotImplemented, Accounts.QueryRequest, Accounts.SuggestAccountsRequest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreate
(AccountInput input) Create a new account.Create a new account with the given username and default options.id
(int id) Look up an account by ID.Look up an account by ID.query()
Query users.Query users.self()
Look up the account of the current in-scope user.Suggest users for a given query.suggestAccounts
(String query) Suggest users for a given query.
-
Constructor Details
-
NotImplemented
public NotImplemented()
-
-
Method Details
-
id
Description copied from interface:Accounts
Look up an account by ID.Note: This method eagerly reads the account. Methods that mutate the account do not necessarily re-read the account. Therefore, calling a getter method on an instance after calling a mutation method on that same instance is not guaranteed to reflect the mutation. It is not recommended to store references to
AccountApi
instances.- Specified by:
id
in interfaceAccounts
- Parameters:
id
- any identifier supported by the REST API, including numeric ID, email, or username.- Returns:
- API for accessing the account.
- Throws:
RestApiException
- if an error occurred.
-
id
Description copied from interface:Accounts
Look up an account by ID. #id(String)See #id(String)
- Specified by:
id
in interfaceAccounts
- Throws:
RestApiException
-
self
Description copied from interface:Accounts
Look up the account of the current in-scope user.- Specified by:
self
in interfaceAccounts
- Throws:
RestApiException
- See Also:
-
create
Description copied from interface:Accounts
Create a new account with the given username and default options.- Specified by:
create
in interfaceAccounts
- Throws:
RestApiException
-
create
Description copied from interface:Accounts
Create a new account.- Specified by:
create
in interfaceAccounts
- Throws:
RestApiException
-
suggestAccounts
Description copied from interface:Accounts
Suggest users for a given query.Example code:
suggestAccounts().withQuery("Reviewer").withLimit(5).get()
- Specified by:
suggestAccounts
in interfaceAccounts
- Returns:
- API for setting parameters and getting result.
- Throws:
RestApiException
-
suggestAccounts
Description copied from interface:Accounts
Suggest users for a given query.Shortcut API for
suggestAccounts().withQuery(String)
.- Specified by:
suggestAccounts
in interfaceAccounts
- Throws:
RestApiException
- See Also:
-
query
Description copied from interface:Accounts
Query users.Example code:
query().withQuery("name:John email:example.com").withLimit(5).get()
- Specified by:
query
in interfaceAccounts
- Returns:
- API for setting parameters and getting result.
- Throws:
RestApiException
-
query
Description copied from interface:Accounts
Query users.Shortcut API for
query().withQuery(String)
.- Specified by:
query
in interfaceAccounts
- Throws:
RestApiException
- See Also:
-