/**
 * 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 { TreeNodeData, TreeData } from '@finos/legend-art';
import { ActionState, type GeneratorFn } from '@finos/legend-shared';
import { type AbstractProperty, type Type, type MappingModelCoverageAnalysisResult, type MappedEntity, AbstractPropertyExpression, Class, Multiplicity, EntityMappedProperty } from '@finos/legend-graph';
import type { QueryBuilderState } from '../QueryBuilderState.js';
import { type QueryBuilderPreviewData } from '../QueryBuilderPreviewDataHelper.js';
import { QueryBuilderPropertySearchState } from './QueryBuilderPropertySearchState.js';
export declare enum QUERY_BUILDER_EXPLORER_TREE_DND_TYPE {
    ROOT = "ROOT",
    CLASS_PROPERTY = "CLASS_PROPERTY",
    ENUM_PROPERTY = "ENUM_PROPERTY",
    PRIMITIVE_PROPERTY = "PRIMITIVE_PROPERTY"
}
export declare const generateExplorerTreePropertyNodeID: (parentId: string, propertyName: string) => string;
export declare const generateExplorerTreeSubtypeNodeID: (parentId: string, subClassPath: string) => string;
export interface QueryBuilderExplorerTreeDragSource {
    node: QueryBuilderExplorerTreePropertyNodeData;
}
export declare abstract class QueryBuilderExplorerTreeNodeData implements TreeNodeData {
    isSelected?: boolean | undefined;
    isOpen?: boolean | undefined;
    isHighlighting?: boolean | undefined;
    id: string;
    label: string;
    dndText: string;
    childrenIds: string[];
    isPartOfDerivedPropertyBranch: boolean;
    type: Type;
    mappingData: QueryBuilderExplorerTreeNodeMappingData;
    elementRef: React.RefObject<HTMLDivElement | null>;
    constructor(id: string, label: string, dndText: string, isPartOfDerivedPropertyBranch: boolean, type: Type, mappingData: QueryBuilderExplorerTreeNodeMappingData, childrenIds?: string[] | undefined);
    setIsSelected(val: boolean | undefined): void;
    setIsOpen(val: boolean | undefined): void;
    setIsHighlighting(val: boolean | undefined): void;
}
export type QueryBuilderExplorerTreeNodeMappingData = {
    mapped: boolean;
    mappedEntity?: MappedEntity | undefined;
    entityMappedProperty?: EntityMappedProperty | undefined;
};
export declare class QueryBuilderExplorerTreeRootNodeData extends QueryBuilderExplorerTreeNodeData {
}
export declare class QueryBuilderExplorerTreePropertyNodeData extends QueryBuilderExplorerTreeNodeData {
    property: AbstractProperty;
    parentId: string;
    constructor(id: string, label: string, dndText: string, property: AbstractProperty, parentId: string, isPartOfDerivedPropertyBranch: boolean, mappingData: QueryBuilderExplorerTreeNodeMappingData, type?: Type | undefined, childrenIds?: string[]);
}
export declare class QueryBuilderExplorerTreeSubTypeNodeData extends QueryBuilderExplorerTreeNodeData {
    subclass: Class;
    parentId: string;
    multiplicity: Multiplicity;
    constructor(id: string, label: string, dndText: string, subclass: Class, parentId: string, isPartOfDerivedPropertyBranch: boolean, mappingData: QueryBuilderExplorerTreeNodeMappingData, multiplicity: Multiplicity, childrenIds?: string[]);
}
export declare const buildPropertyExpressionFromExplorerTreeNodeData: (node: QueryBuilderExplorerTreePropertyNodeData, explorerState: QueryBuilderExplorerState, lambdaParameterName?: string) => AbstractPropertyExpression;
export declare const generatePropertyNodeMappingData: (property: AbstractProperty, parentMappingData: QueryBuilderExplorerTreeNodeMappingData, modelCoverageAnalysisResult: MappingModelCoverageAnalysisResult) => QueryBuilderExplorerTreeNodeMappingData;
export declare const generateSubtypeNodeMappingData: (subclass: Class, parentMappingData: QueryBuilderExplorerTreeNodeMappingData, modelCoverageAnalysisResult: MappingModelCoverageAnalysisResult) => QueryBuilderExplorerTreeNodeMappingData;
export declare const getRootMappingData: (_class: Class, modelCoverageAnalysisResult: MappingModelCoverageAnalysisResult) => QueryBuilderExplorerTreeNodeMappingData;
export declare const getQueryBuilderPropertyNodeData: (property: AbstractProperty, parentNode: QueryBuilderExplorerTreeNodeData, modelCoverageAnalysisResult: MappingModelCoverageAnalysisResult) => QueryBuilderExplorerTreePropertyNodeData | undefined;
export declare const getQueryBuilderSubTypeNodeData: (subclass: Class, parentNode: QueryBuilderExplorerTreeNodeData, modelCoverageAnalysisResult: MappingModelCoverageAnalysisResult) => QueryBuilderExplorerTreeSubTypeNodeData;
export declare const cloneQueryBuilderExplorerTreeNodeData: (node: QueryBuilderExplorerTreeNodeData) => QueryBuilderExplorerTreeNodeData;
export declare class QueryBuilderExplorerPreviewDataState {
    isGeneratingPreviewData: boolean;
    propertyName: string;
    previewData?: QueryBuilderPreviewData | undefined;
    previewDataAbortController?: AbortController | undefined;
    constructor();
    setPropertyName(val: string): void;
    setIsGeneratingPreviewData(val: boolean): void;
    setPreviewData(val: QueryBuilderPreviewData | undefined): void;
    setPreviewDataAbortController(val: AbortController | undefined): void;
}
export declare class QueryBuilderExplorerState {
    readonly queryBuilderState: QueryBuilderState;
    readonly previewDataState: QueryBuilderExplorerPreviewDataState;
    readonly propertySearchState: QueryBuilderPropertySearchState;
    treeData?: TreeData<QueryBuilderExplorerTreeNodeData> | undefined;
    humanizePropertyName: boolean;
    showUnmappedProperties: boolean;
    highlightUsedProperties: boolean;
    mappingModelCoverageAnalysisState: ActionState;
    mappingModelCoverageAnalysisResult?: MappingModelCoverageAnalysisResult;
    constructor(queryBuilderState: QueryBuilderState);
    get nonNullableTreeData(): TreeData<QueryBuilderExplorerTreeNodeData>;
    setTreeData(val: TreeData<QueryBuilderExplorerTreeNodeData> | undefined): void;
    refreshTree(): void;
    setHumanizePropertyName(val: boolean): void;
    setShowUnmappedProperties(val: boolean): void;
    setHighlightUsedProperties(val: boolean): void;
    refreshTreeData(): void;
    generateOpenNodeChildren(node: QueryBuilderExplorerTreeNodeData): void;
    highlightTreeNode(nodeId: string): void;
    analyzeMappingModelCoverage(): GeneratorFn<void>;
    previewData(node: QueryBuilderExplorerTreePropertyNodeData): GeneratorFn<void>;
}
//# sourceMappingURL=QueryBuilderExplorerState.d.ts.map