PersonGroups Interface

public interface PersonGroups

An instance of this class provides access to all the operations defined in PersonGroups.

Method Summary

Modifier and Type Method and Description
PersonGroupsCreateDefinitionStages.WithPersonGroupId create()

Create a new person group with specified personGroupId, name and user-provided userData.

void create(String personGroupId, CreatePersonGroupsOptionalParameter createOptionalParameter)

Create a new person group with specified personGroupId, name and user-provided userData.

Observable<Void> createAsync(String personGroupId, CreatePersonGroupsOptionalParameter createOptionalParameter)

Create a new person group with specified personGroupId, name and user-provided userData.

void delete(String personGroupId)

Delete an existing person group. Persisted face images of all people in the person group will also be deleted.

Observable<Void> deleteAsync(String personGroupId)

Delete an existing person group. Persisted face images of all people in the person group will also be deleted.

PersonGroup get(String personGroupId)

Retrieve the information of a person group, including its name and userData.

Observable<PersonGroup> getAsync(String personGroupId)

Retrieve the information of a person group, including its name and userData.

TrainingStatus getTrainingStatus(String personGroupId)

Retrieve the training status of a person group (completed or ongoing).

Observable<TrainingStatus> getTrainingStatusAsync(String personGroupId)

Retrieve the training status of a person group (completed or ongoing).

PersonGroupsListDefinitionStages.WithExecute list()

List person groups and their information.

List<PersonGroup> list(ListPersonGroupsOptionalParameter listOptionalParameter)

List person groups and their information.

Observable<List<PersonGroup>> listAsync(ListPersonGroupsOptionalParameter listOptionalParameter)

List person groups and their information.

void train(String personGroupId)

Queue a person group training task, the training task may not be started immediately.

Observable<Void> trainAsync(String personGroupId)

Queue a person group training task, the training task may not be started immediately.

PersonGroupsUpdateDefinitionStages.WithPersonGroupId update()

Update an existing person group's display name and userData. The properties which does not appear in request body will not be updated.

void update(String personGroupId, UpdatePersonGroupsOptionalParameter updateOptionalParameter)

Update an existing person group's display name and userData. The properties which does not appear in request body will not be updated.

Observable<Void> updateAsync(String personGroupId, UpdatePersonGroupsOptionalParameter updateOptionalParameter)

Update an existing person group's display name and userData. The properties which does not appear in request body will not be updated.

Method Details

create

public PersonGroupsCreateDefinitionStages.WithPersonGroupId create()

Create a new person group with specified personGroupId, name and user-provided userData.

Returns:

the first stage of the create call

create

public void create(String personGroupId, CreatePersonGroupsOptionalParameter createOptionalParameter)

Create a new person group with specified personGroupId, name and user-provided userData.

Parameters:

personGroupId - Id referencing a particular person group.
createOptionalParameter - the object representing the optional parameters to be set before calling this API

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

createAsync

public Observable createAsync(String personGroupId, CreatePersonGroupsOptionalParameter createOptionalParameter)

Create a new person group with specified personGroupId, name and user-provided userData.

Parameters:

personGroupId - Id referencing a particular person group.
createOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

a representation of the deferred computation of this call if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation

delete

public void delete(String personGroupId)

Delete an existing person group. Persisted face images of all people in the person group will also be deleted.

Parameters:

personGroupId - Id referencing a particular person group.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

deleteAsync

public Observable deleteAsync(String personGroupId)

Delete an existing person group. Persisted face images of all people in the person group will also be deleted.

Parameters:

personGroupId - Id referencing a particular person group.

Returns:

a representation of the deferred computation of this call if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation

get

public PersonGroup get(String personGroupId)

Retrieve the information of a person group, including its name and userData.

Parameters:

personGroupId - Id referencing a particular person group.

Returns:

the PersonGroup object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

getAsync

public Observable getAsync(String personGroupId)

Retrieve the information of a person group, including its name and userData.

Parameters:

personGroupId - Id referencing a particular person group.

Returns:

the observable to the PersonGroup object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

getTrainingStatus

public TrainingStatus getTrainingStatus(String personGroupId)

Retrieve the training status of a person group (completed or ongoing).

Parameters:

personGroupId - Id referencing a particular person group.

Returns:

the TrainingStatus object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

getTrainingStatusAsync

public Observable getTrainingStatusAsync(String personGroupId)

Retrieve the training status of a person group (completed or ongoing).

Parameters:

personGroupId - Id referencing a particular person group.

Returns:

the observable to the TrainingStatus object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

list

public PersonGroupsListDefinitionStages.WithExecute list()

List person groups and their information.

Returns:

the first stage of the list call

list

public List list(ListPersonGroupsOptionalParameter listOptionalParameter)

List person groups and their information.

Parameters:

listOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the List<PersonGroup> object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

listAsync

public Observable> listAsync(ListPersonGroupsOptionalParameter listOptionalParameter)

List person groups and their information.

Parameters:

listOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the List<PersonGroup> object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

train

public void train(String personGroupId)

Queue a person group training task, the training task may not be started immediately.

Parameters:

personGroupId - Id referencing a particular person group.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

trainAsync

public Observable trainAsync(String personGroupId)

Queue a person group training task, the training task may not be started immediately.

Parameters:

personGroupId - Id referencing a particular person group.

Returns:

a representation of the deferred computation of this call if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation

update

public PersonGroupsUpdateDefinitionStages.WithPersonGroupId update()

Update an existing person group's display name and userData. The properties which does not appear in request body will not be updated.

Returns:

the first stage of the update call

update

public void update(String personGroupId, UpdatePersonGroupsOptionalParameter updateOptionalParameter)

Update an existing person group's display name and userData. The properties which does not appear in request body will not be updated.

Parameters:

personGroupId - Id referencing a particular person group.
updateOptionalParameter - the object representing the optional parameters to be set before calling this API

Throws:

IllegalArgumentException - thrown if parameters fail the validation
APIErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

updateAsync

public Observable updateAsync(String personGroupId, UpdatePersonGroupsOptionalParameter updateOptionalParameter)

Update an existing person group's display name and userData. The properties which does not appear in request body will not be updated.

Parameters:

personGroupId - Id referencing a particular person group.
updateOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

a representation of the deferred computation of this call if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation

Applies to