AppStateClient reconnect - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for AppStateClient reconnect method.

This code example shows how to use the following methods:isConnected, reconnect
                && mGamesClient.isConnected()) {
            mConnectedClients &= ~CLIENT_GAMES;
        if ((whatClients & CLIENT_APPSTATE) != 0 && mAppStateClient != null
                && mAppStateClient.isConnected()) {
            mConnectedClients &= ~CLIENT_APPSTATE;
    /** Called when we successfully obtain a connection to a client. */ 
    public void onConnected(Bundle connectionHint) {
        debugLog("onConnected: connected! client=" + mClientCurrentlyConnecting);
        // Mark the current client as connected 
        mConnectedClients |= mClientCurrentlyConnecting;
        // If this was the games client and it came with an invite, store it for later 
reconnect Method Overview
Closes the current connection to Google Play services and creates a new connection.
See Code Examples for other Android AppStateClient Methods: