public interface CompassEngine
LocationComponent when in compass related
RenderMode or
CameraModes.| Modifier and Type | Method and Description |
|---|---|
void |
addCompassListener(CompassListener compassListener)
Adds a
CompassListener that can be used to
receive heading and state changes. |
int |
getLastAccuracySensorStatus()
Provides the last know accuracy status from the sensor manager.
|
float |
getLastHeading()
Returns the last heading value produced and pushed via
a compass listener.
|
void |
removeCompassListener(CompassListener compassListener)
Removes a
CompassListener that can be used to
receive heading and state changes. |
void addCompassListener(@NonNull
CompassListener compassListener)
CompassListener that can be used to
receive heading and state changes.compassListener - to be addedvoid removeCompassListener(@NonNull
CompassListener compassListener)
CompassListener that can be used to
receive heading and state changes.compassListener - to be removedfloat getLastHeading()
int getLastAccuracySensorStatus()
An integer value which is identical to the SensorManager class constants:
android.hardware.SensorManager#SENSOR_STATUS_NO_CONTACTandroid.hardware.SensorManager#SENSOR_STATUS_UNRELIABLEandroid.hardware.SensorManager#SENSOR_STATUS_ACCURACY_LOWandroid.hardware.SensorManager#SENSOR_STATUS_ACCURACY_MEDIUMandroid.hardware.SensorManager#SENSOR_STATUS_ACCURACY_HIGH