import type { IClear , ICopy , IEmpty , Pair } from "@thi.ng/api" ; export interface ISpatialMap < K , V > extends Iterable < Pair < K , V > > , IClear , ICopy < ISpatialMap < K , V > > , IEmpty < ISpatialMap < K , V > > { readonly size : number ; keys ( ) : IterableIterator < K > ; values ( ) : IterableIterator < V > ; set ( key , v , eps ? ) : boolean ; into ( pairs , eps ? ) : boolean ; remove ( key ) : boolean ; has ( key , eps ? ) : boolean ; get ( key , eps ? ) : V | undefined ; } export interface ISpatialSet < K > extends Iterable < K > , IClear , ICopy < ISpatialSet < K > > , IEmpty < ISpatialSet < K > > { readonly size : number ; keys ( ) : IterableIterator < K > ; values ( ) : IterableIterator < K > ; add ( key , eps ? ) : boolean ; into ( keys , eps ? ) : boolean ; remove ( key ) : boolean ; has ( key , eps ? ) : boolean ; get ( key , eps ? ) : K | undefined ; } export interface IRegionQuery < K , V , R > { query ( q , region , limit , acc ? ) : Pair < K , V > [ ] ; queryKeys ( q , region , limit , acc ? ) : K [ ] ; queryValues ( q , region , limit , acc ? ) : V [ ] ; }