目录

interface info
public interface BarrierClient
Entry for the client to register with the server and query barriers on the server.

Public Method Summary

Return typeMethod name
Task<BarrierQueryResponse>public Task<BarrierQueryResponse> queryBarriers(BarrierQueryRequest request)
Task<Void>public Task<Void> updateBarriers(BarrierUpdateRequest request)

Public Methods

Method
public Task<BarrierQueryResponse> queryBarriers(BarrierQueryRequest request)
Queries the current status of a target barrier.

Parameters

Parameter nameParameter desc
requestQuery request containing query condition parameters.


Return

Typedesc
Task<BarrierQueryResponse>Target barrier information, including the key value and current status.
Method
public Task<Void> updateBarriers(BarrierUpdateRequest request)

Adds or deletes a group of barriers.

If a barrier is added using a key that has been registered, the new barrier will replace the original one. No matter whether the new barrier is registered successfully, all callback requests of the original one will be invalid.

Parameters

Parameter nameParameter desc
requestRequest for adding or deleting a barrier.

Return

Typedesc
Task<Void>Generics of Task. You can use isSuccessful() in Task to check whether the operation is successful.

public void enableUpdateWindow(boolean isEnable)

Indicates whether to display a dialog box when Awareness Kit and HMS Core are upgraded.

Note: Excise precaution when using this method. If you determine not to display such a dialog box, no upgrade will be performed, because not displaying the dialog box has the same effect as selecting Cancel in the dialog box if it appears. All functions of Awareness Kit will be unavailable before its upgrade is complete. In this case, wait for a silent upgrade, which generally occurs every 7 to 14 days. The functions will be resumed after a silent upgrade is complete.