import * as i0 from '@angular/core'; import { OnInit, Injector, InjectionToken, Type } from '@angular/core'; import { HsQueryBaseService } from 'hslayers-ng/services/query'; import * as ol_renderer_Layer from 'ol/renderer/Layer'; import { BehaviorSubject, Observable, Subject } from 'rxjs'; import { Feature } from 'ol'; import * as ol_geom from 'ol/geom'; import { Geometry } from 'ol/geom'; import * as ol_layer from 'ol/layer'; import { Layer } from 'ol/layer'; import * as ol_source from 'ol/source'; import { Source, Vector, TileWMS, ImageWMS, WMTS } from 'ol/source'; import { getTitle } from 'hslayers-ng/common/extensions'; import * as ol_Feature from 'ol/Feature'; import { HsFeatureDescriptor } from 'hslayers-ng/types'; import { jsonGetFeatureInfo } from 'hslayers-ng/common/get-feature-info'; import { HsMapService } from 'hslayers-ng/services/map'; import Popup from 'ol-popup'; import { HsPanelBaseComponent } from 'hslayers-ng/common/panels'; declare class HsQueryAttributeRowComponent implements OnInit { isObject: boolean; attribute: any; feature: any; readonly: boolean; template: any; tmpObjectValue: any; ngOnInit(): void; /** * Act on feature attribute changes */ change(): void; /** * Check if attribute value is object and stringify it if needed */ checkAttributeValue(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class HsQueryDefaultInfoPanelBodyComponent implements OnInit { hsQueryBaseService: HsQueryBaseService; featureInfoExpanded: boolean; ngOnInit(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } interface exportFormats { name: 'WKT' | 'GeoJSON'; ext: string; serializedData?: string; mimeType: string; downloadData?: any; } declare class HsFeatureCommonService { private hsQueryVectorService; private hsToastService; private hsLanguageService; private hsMapService; listSubject: BehaviorSubject>[]>; availableLayer$: Observable[]>; constructor(); /** * Translate string value to the selected UI language * @param module - Locales json key * @param text - Locales json key value * @returns Translated text */ translateString(module: string, text: string): string; /** * Update layer list from the current app map */ updateLayerList(): void; /** * Prepare features for export * @param exportFormats - Export formats selected * @param features - Features to export */ toggleExportMenu(exportFormats: exportFormats[], features: Feature[] | Feature): void; /** * Move or copy feature/s * @param type - Action type ('move' or 'copy') * @param features - Features to interact with * @param toLayer - Target layer */ moveOrCopyFeature(type: 'move' | 'copy', features: Feature[], toLayer: Layer): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare class HsQueryFeatureListComponent { private hsQueryVectorService; private hsDialogContainerService; hsFeatureCommonService: HsFeatureCommonService; hsQueryBaseService: HsQueryBaseService; exportMenuVisible: any; selectedFeaturesVisible: boolean; exportFormats: exportFormats[]; editType: any; editMenuVisible: boolean; selectedLayer: any; getTitle: typeof getTitle; /** * Track item by OpenLayers feature, ol_uid value * @param index - Index * @param item - Item provided */ trackById(index: any, item: any): string; /** * Get OL feature array * @returns Feature array */ olFeatureArray(): Feature[]; /** * Toggle dropdown menus * @param beingToggled - Menu name that is being toggled * @param other - Other menu name to be closed if opened */ toggleMenus(beingToggled: string, other: string): void; /** * Toggle export menu */ toggleExportMenu(): void; /** * Toggle edit menu */ toggleEditMenu(): void; /** * Set edit type * @param type - Type selected */ editTypeSelected(type: string): void; /** * Move or copy feature */ moveOrCopyFeature(): void; /** * Remove all selected features */ removeAllSelectedFeatures(): Promise; /** * Translate string value to the selected UI language * @param module - Locales json key * @param text - Locales json key value * @returns Translated text */ translateString(module: string, text: string): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class HsQueryFeatureComponent implements OnInit { private hsMapService; private hsQueryVectorService; private hsFeatureCommonService; private destroyRef; feature: i0.InputSignal; olFeature: i0.Signal>; layer: i0.Signal>, ol_Feature.default>>; isFeatureRemovable: i0.Signal; attributeName: string; attributeValue: string; newAttribVisible: boolean; exportFormats: exportFormats[]; exportMenuVisible: boolean; editMenuVisible: boolean; selectedLayer: any; editType: 'move' | 'copy'; getTitle: typeof getTitle; availableLayers: Observable; ngOnInit(): void; /** * Set new feature attribute * @param attributeName - New attribute name * @param attributeValue - New attribute value */ saveNewAttribute(attributeName: string, attributeValue: any): void; /** * Remove this feature */ removeFeature(): void; /** * Zoom to this feature */ zoomToFeature(): void; /** * Toggle dropdown menus * @param beingToggled - Menu name that is being toggled * @param other - Other menu name to be closed if opened */ toggleMenus(beingToggled: string, other: string): void; /** * Toggle export menus */ toggleExportMenu(): void; /** * Set edit type (move or copy) * @param type - Type selected */ editTypeSelected(type: 'move' | 'copy'): void; /** * Show or hide edit menu */ toggleEditMenu(): void; /** * Move or copy feature */ moveOrCopyFeature(): void; /** * Translate string value to the selected UI language * @param module - Locales json key * @param text - Locales json key value * @returns Translated text */ translateString(module: string, text: string): string; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class HsQueryWmsService { private hsMapService; private hsLanguageService; private httpClient; private hsLogService; private hsQueryWmtsService; private hsQueryBaseService; private hsProxyService; infoCounter: number; constructor(); /** * Request information about clicked WMS layer coordinates * @param url - Request URL * @param infoFormat - Request information format * @param coordinate - Clicked coordinates * @param layer - Target layer */ request(url: string, infoFormat: string, coordinate: number[], layer: Layer): Promise; /** * Error callback to decrease infoCounter * @param coordinate - Clicked coordinates * @param exception - Error caught */ featureInfoError(coordinate: number[], exception: any): void; /** * Parse Information from GetFeatureInfo request. If result came in XML format, Infopanel data are updated. If response is in HTML, popup window is updated and shown. * @param response - Response of GetFeatureInfoRequest * @param infoFormat - Format of GetFeatureInfoResponse * @param coordinate - Coordinate of request * @param layer - Target layer */ featureInfoReceived(response: string, infoFormat: string, coordinate: number[], layer: Layer): void; /** * Parse information from a GetFeatureInfo response with INFO_FORMAT containing * 'json' (e.g. application/json). The response is a GeoJSON-like object; * features are converted to OpenLayers Feature instances for the query panel. * @param response - Parsed GetFeatureInfo JSON body (GeoJSON FeatureCollection-like) * @param layer - Target WMS layer */ parseJSONResponse(response: jsonGetFeatureInfo, layer: Layer): void; /** * Parse Information from XML based GetFeatureInfo response. * @param features - Parsed features * @param layer - Target layer */ parseXmlResponse(features: Feature[], layer: Layer): void; /** * Acknowledge that queries for clicked coordinates have been collected * @param coordinate - Clicked coordinates */ queriesCollected(coordinate: number[]): void; /** * Get FeatureInfo from WMS queryable layer (only if format of response is XML/GML/HTML). Use hs.query.service_getwmsfeatureinfo service for request and parsing response. * @param layer - Layer to Query * @param coordinate - Clicked coordinates */ queryWmsLayer(layer: Layer, coordinate: number[]): void; /** * Check if the selected layer is queryable * @param layer - Layer selected * @returns True if the layer is queryable, false otherwise */ isLayerWmsQueryable(layer: Layer): boolean; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare class HsQueryWmtsService { hsMapService: HsMapService; /** * Parse request URL * @param layer - Layer to Query * @param coordinate - Clicked coordinates * @returns Request URL and format */ parseRequestURL(layer: Layer, coordinate: number[]): Promise<{ url: string; format: string; }>; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } declare class HsQueryComponent extends HsPanelBaseComponent implements OnInit { hsQueryBaseService: HsQueryBaseService; private hsMapService; private hsLog; private hsQueryVectorService; private hsDrawService; private hsQueryWmsService; infoPanelComponent: i0.Type; injector: Injector; popup: Popup; popupOpens: Subject; name: string; queryDeactivator: Subject; ngOnInit(): Promise; /** * Act on query status changes * @param active - Query status state */ queryStatusChanged(active: boolean): void; /** * Check if popup HTML body contains valid elements * @param docChildren - Popup HTML collection * @returns True or false */ checkForBodyElements(docChildren: HTMLCollection): boolean; /** * Check if any feature is selected * @returns True or false */ noFeatureSelected(): boolean; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare const QUERY_INFO_PANEL: InjectionToken>; export { HsFeatureCommonService, HsQueryAttributeRowComponent, HsQueryComponent, HsQueryDefaultInfoPanelBodyComponent, HsQueryFeatureComponent, HsQueryFeatureListComponent, HsQueryWmsService, HsQueryWmtsService, QUERY_INFO_PANEL }; export type { exportFormats };