/**
 * Copyright (c) 2020-present, Goldman Sachs
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
import { type GeneratorFn, ActionState } from '@finos/legend-shared';
import type { TreeData } from '@finos/legend-art';
import type { EditorStore } from '../EditorStore.js';
import type { EditorState } from './EditorState.js';
import type { Entity } from '@finos/legend-storage';
import { type GenerationConfigurationDescription, type GenerationOutput, ArtifactGenerationExtensionResult } from '@finos/legend-graph';
import { ExternalFormatState } from './ExternalFormatState.js';
import { FileSystem_Directory, type FileSystemTreeNodeData, FileSystem_File, type FileResult } from '../utils/FileSystemTreeUtils.js';
export declare const DEFAULT_GENERATION_SPECIFICATION_NAME = "MyGenerationSpecification";
export type GenerationTypeOption = {
    value: string;
    label: string;
};
export declare class DEPREACTED_GlobalFileGenerationState {
    readonly graphGenerationState: GraphGenerationState;
    readonly editorStore: EditorStore;
    fileGenerationConfigurations: GenerationConfigurationDescription[];
    constructor(graphGenerationState: GraphGenerationState, editorStore: EditorStore);
    get fileGenerationConfigurationOptions(): GenerationTypeOption[];
    get supportedFileGenerationConfigurationsForCurrentElement(): GenerationConfigurationDescription[];
    /**
     * Generated file generations in the graph.
     * NOTE: This method does not update graph and application only the files are generated.
     */
    DEPREACTED_generateFiles(generationOutputIndex: Map<string, GenerationOutput[]>): GeneratorFn<void>;
    setFileGenerationConfigurations(fileGenerationConfigurations: GenerationConfigurationDescription[]): void;
    getFileGenerationConfiguration(type: string): GenerationConfigurationDescription;
    fetchAvailableFileGenerationDescriptions(): GeneratorFn<void>;
}
export declare class GraphGenerationState {
    editorStore: EditorStore;
    isRunningGlobalGenerate: boolean;
    generatedEntities: Map<string, Entity[]>;
    clearingGenerationEntitiesState: ActionState;
    externalFormatState: ExternalFormatState;
    globalFileGenerationState: DEPREACTED_GlobalFileGenerationState;
    rootFileDirectory: FileSystem_Directory;
    filesIndex: Map<string, FileSystem_File>;
    selectedNode?: FileSystemTreeNodeData | undefined;
    enableArtifactGeneration: boolean;
    constructor(editorStore: EditorStore);
    setEnableArtifactGeneration(val: boolean): void;
    findGenerationParentPath(genChildPath: string): string | undefined;
    /**
     * Global generation is tied to the generation specification of the project. Every time a generation element
     * is added, they will be added to the generation specification
     */
    globalGenerate(): GeneratorFn<void>;
    generateModels(): GeneratorFn<void>;
    /**
     * Generated artifacts generations in graph
     * NOTE: This method does not update graph and application only the files are generated.
     */
    generateArtifacts(): GeneratorFn<void>;
    processGenerationResult(artifacts: ArtifactGenerationExtensionResult, generationOutputIndex: Map<string, GenerationOutput[]>): void;
    reprocessGenerationFileState(editorState: EditorState): EditorState | undefined;
    reprocessNodeTree(generationResult: FileResult[], treeData: TreeData<FileSystemTreeNodeData>, openedNodeIds: string[]): TreeData<FileSystemTreeNodeData>;
    onTreeNodeSelect(node: FileSystemTreeNodeData, treeData: TreeData<FileSystemTreeNodeData>, reprocess?: boolean): void;
    setSelectedNode(node?: FileSystemTreeNodeData): void;
    emptyGeneratedArtifacts(): void;
    /**
     * Used to clear generation entities as well as the generation model
     */
    clearGenerations(): GeneratorFn<void>;
    /**
     * Method adds generation specification if
     * 1. no generation specification has been defined in graph
     * 2. there exists a generation element
     */
    possiblyAddMissingGenerationSpecifications(): GeneratorFn<void>;
}
//# sourceMappingURL=GraphGenerationState.d.ts.map