Package ch.aaap.harvestclient.impl
Class ClientsApiImpl
Object
ch.aaap.harvestclient.impl.ClientsApiImpl
- All Implemented Interfaces:
Api.Create<Client>
,Api.Delete<Client>
,Api.Get<Client>
,Api.Simple<Client>
,ClientsApi
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionCreate a new Clientvoid
Delete an existing Client.Return an existing Client.list
(ClientFilter filter) list
(ClientFilter filter, int page, int perPage) Return a list of clients, sorted by creation date, newest first.update
(Reference<Client> clientReference, ClientUpdateInfo toChange) Updates the specific client by setting the values of the parameters passed.
-
Constructor Details
-
ClientsApiImpl
-
-
Method Details
-
list
- Specified by:
list
in interfaceClientsApi
- Parameters:
filter
- filtering options- Returns:
- a list of all Clients in the account, sorted by creation date, newest first.
-
list
Description copied from interface:ClientsApi
Return a list of clients, sorted by creation date, newest first. Use the filter object to filter the list. Page and perPage allow controlling how many results to return.- Specified by:
list
in interfaceClientsApi
- Parameters:
filter
- filtering optionspage
- the page numberperPage
- how many results to return for one page. Max 100- Returns:
- a (filtered) list of Client
-
get
Description copied from interface:ClientsApi
Return an existing Client.- Specified by:
get
in interfaceApi.Get<Client>
- Specified by:
get
in interfaceClientsApi
- Parameters:
clientReference
- a reference to an existing Client- Returns:
- the full Client object
-
create
Description copied from interface:ClientsApi
Create a new Client- Specified by:
create
in interfaceApi.Create<Client>
- Specified by:
create
in interfaceClientsApi
- Parameters:
creationInfo
- creation information- Returns:
- the created Client
-
update
Description copied from interface:ClientsApi
Updates the specific client by setting the values of the parameters passed. Any parameters not provided will be left unchanged- Specified by:
update
in interfaceClientsApi
- Parameters:
clientReference
- An existing Client to be updatedtoChange
- the changes to be performed- Returns:
- the updated Client
-
delete
Description copied from interface:ClientsApi
Delete an existing Client.- Specified by:
delete
in interfaceApi.Delete<Client>
- Specified by:
delete
in interfaceClientsApi
- Parameters:
clientReference
- a reference to the Client to be deleted
-