UNPKG

@geogirafe/lib-geoportal

Version:

GeoGirafe is a flexible application to build online geoportals.

34 lines (33 loc) 1.34 kB
import GirafeSingleton from '../../base/GirafeSingleton.js'; import { Feature } from 'ol'; import { Vector as VectorLayer } from 'ol/layer.js'; import { Vector as VectorSource } from 'ol/source.js'; import { Geometry } from 'ol/geom.js'; import LayerLocalFile from '../../models/layers/layerlocalfile.js'; import IGirafeContext from '../context/icontext.js'; declare class LocalFileManager extends GirafeSingleton { private readonly map; private readonly name; private readonly supportedFileFormats; private readonly supportedFileExtensions; private activeLayers; constructor(context: IGirafeContext); initializeSingleton(): void; private registerEvents; private createInteraction; loadLocalFile(localFile: File): Promise<void>; private loadLocalFileFeatures; private handleUnsupportedFiles; private validateAndCompleteFeatures; addLayer(layerFile: LayerLocalFile): void; getLayer(layerFile: LayerLocalFile): VectorLayer<VectorSource<Feature<Geometry, { [x: string]: any; }>>, Feature<Geometry, { [x: string]: any; }>> | null; removeLayer(layerFile: LayerLocalFile): void; layerExists(layer: LayerLocalFile): boolean; selectFeatures(extent: number[]): void; changeOpacity(layer: LayerLocalFile): void; } export default LocalFileManager;