Code example for ActivityRecognitionClient

Methods: removeActivityUpdates

0
     * Once the connection is available, send a request to remove activity recognition updates.  
     */ 
    private void continueRemoveUpdates() { 
         
        // Remove the updates 
        mActivityRecognitionClient.removeActivityUpdates(mCurrentIntent);
         
        /* 
         * Cancel the PendingIntent. This stops Intents from arriving at the IntentService, even if 
         * request fails.  
         */ 
        mCurrentIntent.cancel();
         
        // Disconnect the client 
        requestDisconnection(); 
    } 
 
    /* 
     * Called by Location Services once the activity recognition client is disconnected. 
     */ 
Contextual code suggestions in your IDE  Get Codota for Java