@Override
 public void onTerminate() {
   super.onTerminate();
   // release whatever is needed
   mBeaconManager.unbind(this);
   mBeaconManager = null;
   SugarContext.terminate();
 }
예제 #2
0
 @Override
 protected void onDestroy() {
   super.onDestroy();
   beaconManager.unbind(this);
 }
 public void stopScanning() {
   if (mBeaconManager != null && mBeaconManager.isBound(this)) mBeaconManager.unbind(this);
 }
예제 #4
0
 /**
  * <pre>
  * 调用该方法 以关闭搜索Beacon基站,解除绑定BeaconService
  * Unbinds an Android Activity or Service to the BeaconService.
  * This should typically be called in the onDestroy() method.
  */
 public void closeSearcher() {
   mBeaconManager.unbind(mBeaconConsumer);
 }