aircitytype 1.0.6 → 1.0.8

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.
Files changed (2) hide show
  1. package/index.d.ts +20 -15
  2. package/package.json +2 -2
package/index.d.ts CHANGED
@@ -158,7 +158,7 @@ interface TileLayer {
158
158
  }>;
159
159
  // getActorInfo(data, fn)
160
160
  // getObjectIDs(ids, fn)
161
- hide(p: string, fn?: any): void;
161
+ hide(p: string | string[], fn?: any): void;
162
162
  // hideActor(id, objectId, fn)
163
163
  // hideActors(data, fn)
164
164
  // hideAllActors(tileLayerId)
@@ -321,6 +321,7 @@ interface AircityEvent {
321
321
  PropertyName: string;
322
322
  Position: [number, number, number];
323
323
  UserData: string;
324
+ coordinates: [number, number, number][]
324
325
  }
325
326
 
326
327
  declare class CameraTourKeyFrame {
@@ -342,14 +343,8 @@ declare class CameraTour {
342
343
  }
343
344
 
344
345
  interface Polygon {
345
- add(v: {
346
- id: string;
347
- coordinates: Array<number[]>; //左上,右上,右下,做下这样的顺序
348
- color: number[]; //多边形的填充颜色
349
- frameColor: Color;
350
- frameThickness: number;
351
- depthTest: boolean;
352
- }): void;
346
+ add(v: PolygonType | PolygonType[]): void;
347
+ delete(id: string | string[]): void;
353
348
  clear(): void;
354
349
  }
355
350
 
@@ -362,7 +357,7 @@ interface Polygon3D {
362
357
  interface Polyline {
363
358
  add(arg0: PolyLineType): void;
364
359
  focus(id: string, distance?: number): void;
365
- delete(id: string): void;
360
+ delete(id: string | string[]): void;
366
361
  hide(id: string): void;
367
362
  clear(): void;
368
363
  }
@@ -422,7 +417,7 @@ interface ODLine {
422
417
  interface RadiationPoint {
423
418
  add(data: RadiationPointData, fn?: () => void): void;
424
419
  clear(fn?: () => void): void;
425
- delete(ids: string[] | string, fn: () => void): void;
420
+ delete(ids: string[] | string, fn?: () => void): void;
426
421
  focus(
427
422
  ids: string[] | string,
428
423
  distance?: number,
@@ -477,7 +472,7 @@ type CustomObjectParams = {
477
472
  };
478
473
 
479
474
  interface CustomObject {
480
- delete: any;
475
+ delete(id: string | string[]): void;
481
476
  focus(id: string, t: number): void;
482
477
  startMove(id: string, v: number, t: any[]): void;
483
478
  add(p: CustomObjectParams | CustomObjectParams[]): void;
@@ -506,6 +501,7 @@ interface CustomObject {
506
501
  show(ids: string[] | string, fn?: () => void): void;
507
502
  hide(ids: string[] | string, fn?: () => void): void;
508
503
  restoreMaterial(ids: string | string[]): void;
504
+ callBatchBPFunction(param: { id: string, functionName: string, parameters: any } | { id: string, functionName: string, parameters: any }[]): void;
509
505
  /**
510
506
  *
511
507
  * data object | array
@@ -519,7 +515,7 @@ interface CustomObject {
519
515
  可选的回调函数,请参考二次开发:异步接口调用方式
520
516
  */
521
517
 
522
- overrideMaterial(data: any, fn: () => void): void;
518
+ overrideMaterial(data: any, fn?: () => void): void;
523
519
  }
524
520
 
525
521
  interface Heatmap {
@@ -589,7 +585,7 @@ interface PolyLineType {
589
585
  color?: string | [number, number, number, number]; // 颜色值,支持四种格式,取值示例
590
586
  coordinates?: [number, number, number][]; // 坐标点数组,取值示例
591
587
  coordinateType?: number; // 坐标系类型,取值范围:0为Projection类型,1为WGS84类型,默认值:0
592
- style?: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7; // 折线样式,箭头/光流/贴地/实线/虚线等,取值范围:[0~7],参考 PolylineStyle
588
+ style?: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7; // {Arrow: 0, Arrow1: 1, Flow: 2, Beam: 3, Normal: 4,OnTerrain:5} 参考 PolylineStyle
593
589
  thickness?: number; //线宽,单位:米,默认值20
594
590
  intensity?: number; //亮度,取值范围:[0~1000],默认值:0.5
595
591
  flowRate?: number; // 流速,取值范围:[0~1.0],默认值:0.5
@@ -598,6 +594,15 @@ interface PolyLineType {
598
594
  shape?: number; //样式,0:直线, 1:曲线
599
595
  }
600
596
 
597
+ interface PolygonType {
598
+ id: string;
599
+ coordinates: Array<number[]>; //左上,右上,右下,做下这样的顺序
600
+ color: number[]; //多边形的填充颜色
601
+ frameColor: Color;
602
+ frameThickness: number;
603
+ depthTest: boolean;
604
+ }
605
+
601
606
  interface Marker {
602
607
  clear(): void;
603
608
  add(p: markType | markType[]): Promise<null>;
@@ -777,4 +782,4 @@ declare var IP2: string;
777
782
  declare var imgURL: string;
778
783
  declare var Disk: string;
779
784
  declare var objectIds: string[];
780
- declare var wrap: (id: string, id1: string, url: string) => void;
785
+ declare var wrap: (id: string, id1: string, url: string) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aircitytype",
3
- "version": "1.0.6",
3
+ "version": "1.0.8",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -9,4 +9,4 @@
9
9
  "keywords": [],
10
10
  "author": "",
11
11
  "license": "ISC"
12
- }
12
+ }