| 1 | import type { Bounds, ICameraOptions, ILngLat, IPoint, IStatusOptions, Point } from '@antv/l7-core'; |
| 2 | |
| 3 | export default interface IMapController { |
| 4 | /** |
| 5 | * 当前缩放等级 |
| 6 | */ |
| 7 | getZoom(): number; |
| 8 | |
| 9 | /** |
| 10 | * 中心点经纬度 |
| 11 | */ |
| 12 | getCenter(options?: ICameraOptions): ILngLat; |
| 13 | |
| 14 | /** |
| 15 | * 仰角 |
| 16 | */ |
| 17 | getPitch(): number; |
| 18 | |
| 19 | /** |
| 20 | * 逆时针旋转角度 |
| 21 | */ |
| 22 | getRotation(): number; |
| 23 | |
| 24 | /** |
| 25 | * 获取当前地图可视区域 `[西南角、东北角]` |
| 26 | */ |
| 27 | getBounds(): Bounds; |
| 28 | |
| 29 | /** |
| 30 | * 放大地图 |
| 31 | */ |
| 32 | zoomIn(): void; |
| 33 | |
| 34 | /** |
| 35 | * 缩小地图 |
| 36 | */ |
| 37 | zoomOut(): void; |
| 38 | |
| 39 | /** |
| 40 | * 地图平移到指定点 `[x, y]` |
| 41 | */ |
| 42 | panTo(p: Point): void; |
| 43 | |
| 44 | /** |
| 45 | * 地图平移到指定点 `[x, y]` |
| 46 | */ |
| 47 | panBy(x: number, y: number): void; |
| 48 | |
| 49 | /** |
| 50 | * 调整地图适合指定区域 |
| 51 | */ |
| 52 | fitBounds(bound: Bounds, fitBoundsOptions?: unknown): void; |
| 53 | |
| 54 | getContainer(): HTMLElement | null; |
| 55 | getSize(): [number, number]; |
| 56 | // get map status method |
| 57 | getMinZoom(): number; |
| 58 | getMaxZoom(): number; |
| 59 | // get map params |
| 60 | getType(): string; |
no outgoing calls
no test coverage detected