@idm-plugin/geo 2.1.1 → 2.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +271 -248
- package/dist/index.umd.cjs +7 -6
- package/dist/lane/src/index.d.ts +28 -6
- package/package.json +1 -1
package/dist/lane/src/index.d.ts
CHANGED
|
@@ -370,17 +370,39 @@ export declare class LaneHelper {
|
|
|
370
370
|
static waypoints2RTZ10(name: string, waypoints: Coordinate[]): string;
|
|
371
371
|
static toRTZWaypoints(waypoints: Coordinate[], precision?: number): string[];
|
|
372
372
|
/**
|
|
373
|
-
*
|
|
374
|
-
*
|
|
373
|
+
* 路径转通用CSV (纯十进制度数、无厂商头、RFC 4180标准)
|
|
374
|
+
* 大部分海图设备/导航软件均可导入此格式
|
|
375
|
+
* @param name 兼容旧版本
|
|
375
376
|
* @param waypoints 途径点
|
|
377
|
+
* @param options.precision 经纬度小数位数,默认6
|
|
376
378
|
*/
|
|
377
|
-
static waypoints2CSV(name: string, waypoints: Coordinate[],
|
|
379
|
+
static waypoints2CSV(name: string, waypoints: Coordinate[], options?: {
|
|
380
|
+
precision?: number;
|
|
381
|
+
}): string;
|
|
378
382
|
/**
|
|
379
|
-
*
|
|
380
|
-
|
|
383
|
+
* RFC 4180 CSV字段转义:含逗号、双引号、换行时用双引号包裹,内部双引号翻倍
|
|
384
|
+
*/
|
|
385
|
+
static csvEscapeField(value: any): string;
|
|
386
|
+
/**
|
|
387
|
+
* 十进制度数转NMEA度分格式 (DDMM.MM / DDDMM.MM)
|
|
388
|
+
* @param value 十进制度数
|
|
389
|
+
* @param isLat true为纬度,false为经度
|
|
390
|
+
*/
|
|
391
|
+
static decimalToNmeaDm(value: number, isLat: boolean): {
|
|
392
|
+
dm: string;
|
|
393
|
+
dir: string;
|
|
394
|
+
};
|
|
395
|
+
/**
|
|
396
|
+
* 计算NMEA 0183校验和 ($与*之间所有字符的异或,两字符十六进制大写)
|
|
397
|
+
* @param sentence $与*之间的字符串
|
|
398
|
+
*/
|
|
399
|
+
static nmeaChecksum(sentence: string): string;
|
|
400
|
+
/**
|
|
401
|
+
* 路径转NMEA 0183 WPL航点语句
|
|
381
402
|
* @param waypoints 途径点
|
|
403
|
+
* @returns 多条$GPWPL语句,以\r\n分隔
|
|
382
404
|
*/
|
|
383
|
-
static
|
|
405
|
+
static waypoints2NMEA(waypoints: Coordinate[]): string;
|
|
384
406
|
/**
|
|
385
407
|
* 路径摘要
|
|
386
408
|
* @param coordinates 已排序的坐标
|