AI-generated Key Takeaways
-
FenceApi
is deprecated and developers should useFenceClient
viaAwareness.getFenceClient(Activity)
instead. -
It provided an entry point for the Awareness Fence API using
GoogleApiClient
, which is now outdated. -
queryFences
andupdateFences
methods, previously used withGoogleApiClient
, have been replaced with their counterparts inFenceClient
. -
The Awareness API Guide offers further information and context for utilizing the updated Fence API functionalities.
This interface is deprecated.
Use
getFenceClient(Activity)
instead.
Deprecated entry point for the Awareness Fence API using GoogleApiClient
.
The methods must be used in conjunction with a GoogleApiClient
instance. For example:
new GoogleApiClient.Builder(context)
.addApi(Awareness.API)
.addConnectionCallbacks(this)
.addOnConnectionFailedListener(this)
.build()
See Also
Public Method Summary
abstract PendingResult<FenceQueryResult> |
queryFences(GoogleApiClient
client,
FenceQueryRequest fenceQueryRequest)
This method is deprecated. Use
queryFences(FenceQueryRequest) instead.
|
abstract PendingResult<Status> |
updateFences(GoogleApiClient
client,
FenceUpdateRequest fenceUpdateRequest)
This method is deprecated. Use
updateFences(FenceUpdateRequest) instead.
|
Public Methods
public abstract PendingResult<FenceQueryResult> queryFences (GoogleApiClient client, FenceQueryRequest fenceQueryRequest)
This method is deprecated.
Use
queryFences(FenceQueryRequest)
instead.
Query the state of a registered fence in the Awareness API.
Parameters
client | A GoogleApiClient
instance. |
---|---|
fenceQueryRequest | A request encapsulating the query criteria parameters. |
Returns
- a
PendingResult
with aFenceQueryResult
.
public abstract PendingResult<Status> updateFences (GoogleApiClient client, FenceUpdateRequest fenceUpdateRequest)
This method is deprecated.
Use
updateFences(FenceUpdateRequest)
instead.
Add or remove a set of fences that are registered with the Awareness API.
Parameters
client | A GoogleApiClient
instance. |
---|---|
fenceUpdateRequest | A request indicating a batch of fences to add and/or remove. |
Returns
- a
PendingResult
withStatus
indicating success or failure.