/**
 * @param {JQuery} $element Element.
 * @param {angular.IQService} $q Angular $q service.
 * @param {angular.IScope} $scope Angular scope.
 * @param {angular.ITimeoutService} $timeout Angular timeout service.
 * @param {angular.gettext.gettextCatalog} gettextCatalog Gettext catalog.
 * @param {import('gmf/editing/EditFeature').EditingEditFeature} gmfEditFeature Gmf edit feature service.
 * @param {import('gmf/editing/Snapping').EditingSnappingService} gmfSnapping The gmf snapping service.
 * @param {import('gmf/editing/XSDAttributes').EditingXSDAttributeService} gmfXSDAttributes The gmf
 *    XSDAttributes service.
 * @param {import('ngeo/misc/EventHelper').EventHelper} ngeoEventHelper Ngeo Event Helper.
 * @param {import('ngeo/misc/FeatureHelper').FeatureHelper} ngeoFeatureHelper Ngeo feature helper service.
 * @param {import('ngeo/map/LayerHelper').LayerHelper} ngeoLayerHelper Ngeo Layer Helper.
 * @param {import('ngeo/misc/ToolActivateMgr').ToolActivateMgr} ngeoToolActivateMgr Ngeo ToolActivate
 *    manager service.
 * @param {import('gmf/options').gmfEditFeatureOptions} gmfEditFeatureOptions The options.
 * @class
 * @hidden
 * @ngdoc controller
 * @ngname GmfEditfeatureController
 */
export function Controller($element: JQuery, $q: angular.IQService, $scope: angular.IScope, $timeout: angular.ITimeoutService, gettextCatalog: angular.gettext.gettextCatalog, gmfEditFeature: import("gmf/editing/EditFeature").EditingEditFeature, gmfSnapping: import("gmf/editing/Snapping").EditingSnappingService, gmfXSDAttributes: import("gmf/editing/XSDAttributes").EditingXSDAttributeService, ngeoEventHelper: import("ngeo/misc/EventHelper").EventHelper, ngeoFeatureHelper: import("ngeo/misc/FeatureHelper").FeatureHelper, ngeoLayerHelper: import("ngeo/map/LayerHelper").LayerHelper, ngeoToolActivateMgr: import("ngeo/misc/ToolActivateMgr").ToolActivateMgr, gmfEditFeatureOptions: import("gmf/options").gmfEditFeatureOptions): void;
export class Controller {
    /**
     * @param {JQuery} $element Element.
     * @param {angular.IQService} $q Angular $q service.
     * @param {angular.IScope} $scope Angular scope.
     * @param {angular.ITimeoutService} $timeout Angular timeout service.
     * @param {angular.gettext.gettextCatalog} gettextCatalog Gettext catalog.
     * @param {import('gmf/editing/EditFeature').EditingEditFeature} gmfEditFeature Gmf edit feature service.
     * @param {import('gmf/editing/Snapping').EditingSnappingService} gmfSnapping The gmf snapping service.
     * @param {import('gmf/editing/XSDAttributes').EditingXSDAttributeService} gmfXSDAttributes The gmf
     *    XSDAttributes service.
     * @param {import('ngeo/misc/EventHelper').EventHelper} ngeoEventHelper Ngeo Event Helper.
     * @param {import('ngeo/misc/FeatureHelper').FeatureHelper} ngeoFeatureHelper Ngeo feature helper service.
     * @param {import('ngeo/map/LayerHelper').LayerHelper} ngeoLayerHelper Ngeo Layer Helper.
     * @param {import('ngeo/misc/ToolActivateMgr').ToolActivateMgr} ngeoToolActivateMgr Ngeo ToolActivate
     *    manager service.
     * @param {import('gmf/options').gmfEditFeatureOptions} gmfEditFeatureOptions The options.
     * @class
     * @hidden
     * @ngdoc controller
     * @ngname GmfEditfeatureController
     */
    constructor($element: JQuery, $q: angular.IQService, $scope: angular.IScope, $timeout: angular.ITimeoutService, gettextCatalog: angular.gettext.gettextCatalog, gmfEditFeature: import("gmf/editing/EditFeature").EditingEditFeature, gmfSnapping: import("gmf/editing/Snapping").EditingSnappingService, gmfXSDAttributes: import("gmf/editing/XSDAttributes").EditingXSDAttributeService, ngeoEventHelper: import("ngeo/misc/EventHelper").EventHelper, ngeoFeatureHelper: import("ngeo/misc/FeatureHelper").FeatureHelper, ngeoLayerHelper: import("ngeo/map/LayerHelper").LayerHelper, ngeoToolActivateMgr: import("ngeo/misc/ToolActivateMgr").ToolActivateMgr, gmfEditFeatureOptions: import("gmf/options").gmfEditFeatureOptions);
    /**
     * Flag that is toggled as soon as the feature changes, i.e. if any of its
     * properties change, which includes the geometry.
     *
     * @type {boolean}
     */
    dirty: boolean;
    /**
     * @type {?import('ngeo/layertree/Controller').LayertreeController}
     */
    editableTreeCtrl: import("ngeo/layertree/Controller").LayertreeController | null;
    /**
     * @type {?import('ol/Map').default}
     */
    map: import("ol/Map").default | null;
    /**
     * The state property shared with the `gmf-editfeatureselector` directive.
     * For more info, see in that directive.
     *
     * @type {string}
     */
    state: string;
    /**
     * @type {number}
     */
    tolerance: number;
    /**
     * @type {?import('ol/layer/Vector').default<import('ol/source/Vector').default<import('ol/geom/Geometry').default>>}
     */
    vectorLayer: import("ol/layer/Vector").default<import("ol/source/Vector").default<import("ol/geom/Geometry").default>> | null;
    /**
     * @type {boolean}
     * @export
     */
    closeAfterSave: boolean;
    /**
     * @type {JQuery}
     */
    element_: JQuery;
    /**
     * @type {angular.IQService}
     */
    q_: angular.IQService;
    /**
     * @type {angular.IScope}
     */
    scope_: angular.IScope;
    /**
     * @type {angular.ITimeoutService}
     */
    timeout_: angular.ITimeoutService;
    /**
     * @type {angular.gettext.gettextCatalog}
     */
    gettextCatalog_: angular.gettext.gettextCatalog;
    /**
     * @type {import('gmf/editing/EditFeature').EditingEditFeature}
     */
    gmfEditFeature_: import("gmf/editing/EditFeature").EditingEditFeature;
    /**
     * @type {import('gmf/editing/Snapping').EditingSnappingService}
     */
    gmfSnapping_: import("gmf/editing/Snapping").EditingSnappingService;
    /**
     * @type {import('gmf/editing/XSDAttributes').EditingXSDAttributeService}
     */
    gmfXSDAttributes_: import("gmf/editing/XSDAttributes").EditingXSDAttributeService;
    /**
     * @type {import('ngeo/misc/EventHelper').EventHelper}
     */
    ngeoEventHelper_: import("ngeo/misc/EventHelper").EventHelper;
    /**
     * @type {import('ngeo/misc/FeatureHelper').FeatureHelper}
     */
    ngeoFeatureHelper_: import("ngeo/misc/FeatureHelper").FeatureHelper;
    /**
     * @type {import('ngeo/map/LayerHelper').LayerHelper}
     */
    ngeoLayerHelper_: import("ngeo/map/LayerHelper").LayerHelper;
    /**
     * @type {import('ngeo/misc/ToolActivateMgr').ToolActivateMgr}
     */
    ngeoToolActivateMgr_: import("ngeo/misc/ToolActivateMgr").ToolActivateMgr;
    /**
     * @type {?import('gmf/themes').GmfLayer}
     */
    editableNode_: import("gmf/themes").GmfLayer | null;
    /**
     * @type {?import('ol/layer/Image').default<import('ol/source/Image').default>|import('ol/layer/WebGLTile').default<import('ol/source/Tile').default>}
     */
    editableWMSLayer_: (import("ol/layer/Image").default<import("ol/source/Image").default> | import("ol/layer/WebGLTile").default<import("ol/source/Tile").default>) | null;
    /**
     * A deferred object resolved after the confirm modal "continue w/o saving" or
     * "save" buttons are clicked.
     *
     * @type {?angular.IDeferred<never>}
     */
    confirmDeferred_: angular.IDeferred<never> | null;
    /**
     * Flag that controls the visibility of the modal that manages unsaved
     * modifications.
     *
     * @type {boolean}
     */
    unsavedModificationsModalShown: boolean;
    /**
     * Flag that is toggled while a request is pending, either one to get
     * features when a map is clicked or when saving
     */
    pending: boolean;
    /**
     * @type {boolean}
     */
    active: boolean;
    /**
     * @type {boolean}
     */
    createActive: boolean;
    /**
     * @type {import('ngeo/misc/ToolActivate').default}
     */
    createToolActivate: import("ngeo/misc/ToolActivate").default;
    /**
     * @type {boolean}
     */
    mapSelectActive: boolean;
    /**
     * @type {import('ngeo/misc/ToolActivate').default}
     */
    mapSelectToolActivate: import("ngeo/misc/ToolActivate").default;
    /**
     * @type {?olFeature<import('ol/geom/Geometry').default>}
     */
    feature: olFeature<import("ol/geom/Geometry").default> | null;
    /**
     * @type {number|string|undefined}
     */
    featureId: number | string | undefined;
    /**
     * @type {?import('ol/Collection').default<olFeature<import('ol/geom/Geometry').default>>}
     */
    features: import("ol/Collection").default<olFeature<import("ol/geom/Geometry").default>> | null;
    /**
     * @type {?import('ol/layer/Vector').default<import('ol/source/Vector').default<import('ol/geom/Geometry').default>>}
     */
    highlightVectorLayer_: import("ol/layer/Vector").default<import("ol/source/Vector").default<import("ol/geom/Geometry").default>> | null;
    /**
     * @type {?import('ol/Collection').default<olFeature<import('ol/geom/Geometry').default>>}
     */
    highlightedFeatures_: import("ol/Collection").default<olFeature<import("ol/geom/Geometry").default>> | null;
    /**
     * @type {import('ol/Collection').default<import('ol/interaction/Interaction').default>}
     */
    interactions_: import("ol/Collection").default<import("ol/interaction/Interaction").default>;
    /**
     * @type {?import('ol/interaction/Modify').default}
     */
    modify_: import("ol/interaction/Modify").default | null;
    /**
     * @type {?import('ngeo/misc/ToolActivate').default}
     */
    modifyToolActivate: import("ngeo/misc/ToolActivate").default | null;
    /**
     * @type {import('ngeo/Menu').default}
     */
    menu_: import("ngeo/Menu").default;
    /**
     * @type {import('ngeo/Menu').default}
     */
    menuVertex_: import("ngeo/Menu").default;
    /**
     * @type {import('gmf/menu/MenuMultiFeature').default}
     */
    menuMultiple_: import("gmf/menu/MenuMultiFeature").default;
    /**
     * @type {?import('ngeo/interaction/Translate').default}
     */
    translate_: import("ngeo/interaction/Translate").default | null;
    /**
     * @type {?import('ngeo/interaction/Rotate').default}
     */
    rotate_: import("ngeo/interaction/Rotate").default | null;
    /**
     * @type {?import('ngeo/misc/ToolActivate').default}
     */
    rotateToolActivate: import("ngeo/misc/ToolActivate").default | null;
    /**
     * @type {?import('ngeo/misc/ToolActivate').default}
     */
    translateToolActivate: import("ngeo/misc/ToolActivate").default | null;
    /**
     * @type {import('ol/events').EventsKey[]}
     */
    listenerKeys_: import("ol/events").EventsKey[];
    /**
     * @type {import('ol/events').EventsKey[]}
     */
    geomListenerKeys_: import("ol/events").EventsKey[];
    /**
     * @type {import('ol/events').EventsKey[]}
     */
    mapListenerKeys_: import("ol/events").EventsKey[];
    /**
     * @type {import('ol/events').EventsKey[]}
     */
    menuMultipleListenerKeys_: import("ol/events").EventsKey[];
    /**
     * @type {?import('ngeo/format/Attribute').Attribute[]}
     */
    attributes: import("ngeo/format/Attribute").Attribute[] | null;
    /**
     * @type {?string}
     */
    geomType: string | null;
    /**
     * @type {boolean}
     */
    showServerError: boolean;
    /**
     * @type {?string}
     */
    serverErrorMessage: string | null;
    /**
     * @type {?string}
     */
    serverErrorType: string | null;
    /**
     * @type {?number[]}
     */
    vertexInfo_: number[] | null;
    /**
     * @type {import('gmf/options').gmfEditFeatureOptions}
     */
    options_: import("gmf/options").gmfEditFeatureOptions;
    /**
     * Called on initialization of the controller.
     */
    $onInit(): void;
    hightlightedFeatures_: olCollection<import("ol/geom/Geometry").default>;
    /**
     * Save the currently selected feature modifications.
     */
    save(): void;
    /**
     */
    cancel(): void;
    /**
     * Check if there are unsaved modifications. If there aren't, then cancel.
     * Used by the 'cancel' button in the template.
     *
     * @returns {angular.IPromise<void>} The promise attached to the confirm deferred object.
     */
    confirmCancel(): angular.IPromise<void>;
    /**
     * Check if there's a feature selected and if it contains modifications
     * (a.k.a. is dirty), then the confirmation modal is shown.
     *
     * @param {boolean} [scopeApply] Whether to force scope to refresh or not.
     *     when the confirm modal is not dismissed.
     * @returns {angular.IPromise<void>} The promise attached to the confirm deferred
     *     object.
     */
    checkForModifications_(scopeApply?: boolean): angular.IPromise<void>;
    /**
     */
    continueWithoutSaving(): void;
    /**
     */
    delete(): void;
    /**
     * Called when the modal 'save' button is clicked. Do as if the user had
     * clicked on the 'save' input button in the form, which allows the form
     * to be validated.
     */
    submit(): void;
    /**
     * Called after an insert, update or delete request.
     *
     * @param {angular.IHttpResponse<ArrayBuffer|Document|Node|string>} resp Ajax response.
     */
    handleEditFeature_(resp: angular.IHttpResponse<ArrayBuffer | Document | Node | string>): void;
    /**
     * @param {import('ngeo/format/Attribute').Attribute[]} attributes Attributes.
     */
    setAttributes_(attributes: import("ngeo/format/Attribute").Attribute[]): void;
    /**
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleFeatureAdd_(evt: Event | import("ol/events/Event").default): void;
    /**
     * Activate or deactivate this directive.
     *
     * @param {boolean} active Whether to activate this directive or not.
     */
    toggle_(active: boolean): void;
    /**
     * Called when the mapSelectActive property changes.
     *
     * @param {boolean} active Whether the map select is active or not.
     */
    handleMapSelectActiveChange_(active: boolean): void;
    /**
     * Called when the map is clicked.
     *
     * (1) If a vector feature was clicked, don't do anything (i.e. allow the
     *     interactions to do their bindings without selecting a new feature).
     *
     * (2) Otherwise, if there is a feature being edited and has unsaved
     *     modifications, show the confirmation modal asking the user what to do
     *     about it.
     *
     * (3) If there's no feature selected or we have one without unsaved
     *     modifications or with modifications that were canceled, launch a query
     *     to fetch the features at the clicked location.
     *
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleMapClick_(evt: Event | import("ol/events/Event").default): void;
    /**
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleMapContextMenu_(evt: Event | import("ol/events/Event").default): void;
    /**
     *@param {?olFeature<import('ol/geom/Geometry').default>} feature The feature to edit.
     */
    setFeature_(feature: olFeature<import("ol/geom/Geometry").default> | null): void;
    /**
     * @param {number[]} coordinate The click coordinates.
     * @param {olFeature<import('ol/geom/Geometry').default>[]} features Features.
     */
    handleGetFeatures_(coordinate: number[], features: olFeature<import("ol/geom/Geometry").default>[]): void;
    /**
     *@param {number[]} coordinate The click coordinates.
     *@param {olFeature<import('ol/geom/Geometry').default>[]} features Features.
     */
    openFeatureMenu_(coordinate: number[], features: olFeature<import("ol/geom/Geometry").default>[]): void;
    /**
     * Initialize interactions by setting them inactive and decorating them
     */
    initializeInteractions_(): void;
    /**
     * Register interactions by adding them to the map
     */
    registerInteractions_(): void;
    /**
     * Unregister interactions, i.e. set them inactive and remove them from the map
     */
    unregisterInteractions_(): void;
    /**
     * @param {?olFeature<import('ol/geom/Geometry').default>} newFeature The new feature.
     * @param {?olFeature<import('ol/geom/Geometry').default>} oldFeature The old feature.
     */
    handleFeatureChange_(newFeature: olFeature<import("ol/geom/Geometry").default> | null, oldFeature: olFeature<import("ol/geom/Geometry").default> | null): void;
    handleFeaturePropertyChange_(): void;
    handleFeatureGeometryChange_(): void;
    /**
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleMenuActionClick_(evt: Event | import("ol/events/Event").default): void;
    /**
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleMenuVertexActionClick_(evt: Event | import("ol/events/Event").default): void;
    /**
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleTranslateEnd_(evt: Event | import("ol/events/Event").default): void;
    /**
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleRotateEnd_(evt: Event | import("ol/events/Event").default): void;
    handleDestroy_(): void;
    /**
     * Handles the click on element in the feature menu
     * In the call the parameters are in inverse order!
     *
     * @param {olFeature<import('ol/geom/Geometry').default>[]} features Features.
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleMenuMultipleActionClick_(features: olFeature<import("ol/geom/Geometry").default>[], evt: Event | import("ol/events/Event").default): void;
    /**
     * Handles mouse entering a menu item of the multiple feature menu
     *
     * @param {olFeature<import('ol/geom/Geometry').default>[]} features Features.
     * @param {Event|import('ol/events/Event').default} evt Event.
     */
    handleMultiMenuActionMouseEnter_(features: olFeature<import("ol/geom/Geometry").default>[], evt: Event | import("ol/events/Event").default): void;
    /**
     * Handles mouse leaving a menu item of the multiple feature menu
     */
    handleMultiMenuActionMouseOut_(): void;
}
export namespace Controller {
    let $inject: string[];
}
/**
 * *
 */
export type EditingState = string;
export namespace EditingState {
    let IDLE: string;
    let DEACTIVATE_EXECUTE: string;
    let DEACTIVATE_PENDING: string;
    let STOP_EDITING_EXECUTE: string;
    let STOP_EDITING_PENDING: string;
}
export default myModule;
import angular from 'angular';
import olFeature from 'ol/Feature';
import olCollection from 'ol/Collection';
/**
 * @type {angular.IModule}
 * @hidden
 */
declare const myModule: angular.IModule;
