As before, I work with Android Beacon Library,
It already worked and I can found out beacon via BLE - Bluetooth low energy,
But now, after updated to latest
If you are implementing the BeaconConsumer
interface in a Fragment
(and not an Activity
, Service
or Application
instance), you need to chain all of the methods. Like this:
@Override
public Context getApplicationContext() {
return getActivity().getApplicationContext();
}
@Override
public void unbindService(ServiceConnection serviceConnection) {
getActivity().unbindService(serviceConnection);
}
@Override
public boolean bindService(Intent intent, ServiceConnection serviceConnection, int i) {
return getActivity().bindService(intent, serviceConnection, i);
}