Page 580 - 완) I MDP 프로젝트 작품 보고서(전체과 1학년)1.6
P. 580
//monitoring 실패 시 코드 작성
Log.i(Tag, "monitoring failed");
}
public void onDestroy() {
Log.i(Tag, "destroy beacon service");
for (RECOBeaconRegion region : mRegions) {
try {
mRecoManager.stopMonitoringForRegion(region);
} catch (RemoteException e) {
Log.e("BackMonitoringService", "RemoteException has occured while
executing RECOManager.stopMonitoringForRegion()");
e.printStackTrace();
} catch (NullPointerException e) {
Log.e("BackMonitoringService", "NullPointerException has occured while
executing RECOManager.stopMonitoringForRegion()");
e.printStackTrace();
}
}
try {
mRecoManager.unbind();
} catch (RemoteException e) {
Log.e("BackMonitoringService", "RemoteException has o c c u r e d w h i l e
executing unbind()");
e.printStackTrace();
}
Log.i(Tag,"Beacon stopmonitoring");
this.popupNotification("motor stop");
- 573 -