public interface LocatorCallback
This class allows your application to obtain the location result reported by the system after the location service is initiated.
LocatorSystemCapability.Location#LOCATION| 限定符和类型 | 方法 | 说明 |
|---|---|---|
void |
onErrorReport(int type) |
Obtains the error that occurs during the location service process.
|
void |
onLocationReport(Location location) |
Obtains the location result after the location service is initiated.
|
void |
onStatusChanged(int type) |
Obtains the location service status after the location service is initiated.
|
void onLocationReport(Location location)
location - Indicates the location result, which is specified by Location.void onStatusChanged(int type)
The location service status can be:
type - Indicates the location service status.Locatorvoid onErrorReport(int type)
The error can be:
type - Indicates the error type.Locator