import { default as RBush } from 'rbush'; import { Bbox, Point, Polygon } from '@allmaps/types'; type RTreeItem = { minX: number; minY: number; maxX: number; maxY: number; id: string; }; /** * 2D spatial index for polygons */ export declare class RTree { #private; rbush: RBush; polygonsById: Map; bboxesById: Map; itemsById: Map; addItem(id: string, polygon: Polygon): void; removeItem(id: string): void; clear(): void; getBbox(id: string): Bbox | undefined; getPolygon(id: string): Polygon | undefined; searchFromBbox(bbox: Bbox): string[]; searchFromPoint(point: Point, filterInsidePolygon?: boolean): string[]; } export {};