Code example for ServiceConnection

Methods: onServiceConnected

0
      } 
       
      public void onServiceConnected(ComponentName className, android.os.IBinder service) {
          sService = IMediaPlaybackService.Stub.asInterface(service);
          if (mCallback != null) {
              mCallback.onServiceConnected(className, service);
          } 
      } 
       
      public void onServiceDisconnected(ComponentName className) {
          if (mCallback != null) {
              mCallback.onServiceDisconnected(className);
          } 
          sService = null;
      } 
  } 
   
   
  /////////////////////////////////////////////////// 
   
Experience pair programming with AI  Get Codota for Java