@elastic/ems-client
Version:
JavaScript client library for the Elastic Maps Service
41 lines (40 loc) • 1.44 kB
TypeScript
import { EMSClient, FileLayerConfig, FileLayerField } from './ems_client';
import { AbstractEmsService } from './ems_service';
import { FeatureCollection } from 'geojson';
export declare enum EMSFormatType {
geojson = "geojson",
topojson = "topojson"
}
export type EMSFormatTypeStrings = keyof typeof EMSFormatType;
export declare class FileLayer extends AbstractEmsService {
protected readonly _config: FileLayerConfig;
constructor(config: FileLayerConfig, emsClient: EMSClient, proxyPath: string);
getGeoJson(): Promise<FeatureCollection | undefined>;
getFields(): FileLayerField[];
getFieldsInLanguage(): {
type: string;
name: string;
description: string;
}[];
getDisplayName(): string;
getId(): string;
hasId(id: string): boolean;
getEMSHotLink(): string;
getDefaultFormatType(): string;
getFormatOfType(type: EMSFormatTypeStrings): EMSFormatTypeStrings;
getDefaultFormatMeta(): {
[key: string]: string;
} | undefined;
getFormatOfTypeMeta(type: EMSFormatTypeStrings): {
[key: string]: string | undefined;
feature_collection_path?: string;
} | undefined;
getDefaultFormatUrl(): string;
getFormatOfTypeUrl(type: EMSFormatTypeStrings): string;
getCreatedAt(): string;
getApiUrl(): string;
private _getFormatUrl;
private _getFormatMeta;
private _getDefaultFormat;
private _getFormatOfType;
}