TencentLocationUtils class abstract
定位相关工具方法。
原生不支持的平台会抛出 TencentLocationError(错误码
unsupportedOnThisPlatform)。各方法的平台支持情况详见方法注释。
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
contains(
{required TencentLocationCoordinate center, required double radius, required TencentLocationCoordinate point}) → bool -
判断指定坐标点是否落在以
center为圆心、半径为radius米的圆形区域内。 -
distanceBetween(
TencentLocationCoordinate a, TencentLocationCoordinate b) → double - 计算两个坐标点之间的距离,单位:米。
-
isInRegion(
{required double latitude, required double longitude}) → Future< bool> - 坐标是否在国内。
-
isSupportGps(
) → Future< bool> - 当前设备是否支持 GPS。
-
wgs84ToGcj02(
TencentLocationCoordinate coord) → Future< TencentLocationCoordinate> - WGS-84 坐标转 GCJ-02 坐标。