terra-route
Version:
A library for routing along GeoJSON LineString networks
14 lines (13 loc) • 797 B
TypeScript
import { FeatureCollection, LineString } from 'geojson';
/**
* Type representing a bounding box as [minLng, minLat, maxLng, maxLat]
*/
export type BoundingBox = [number, number, number, number];
/**
* Filters a FeatureCollection of LineString features to only include LineStrings
* that are completely within the specified bounding box.
* @param featureCollection - A GeoJSON FeatureCollection containing LineString features
* @param boundingBox - A bounding box array in the format [minLng, minLat, maxLng, maxLat]
* @returns A new FeatureCollection<LineString> containing only the LineStrings completely within the bounding box
*/
export declare function getNetworkInBoundingBox(featureCollection: FeatureCollection<LineString>, boundingBox: BoundingBox): FeatureCollection<LineString>;