UNPKG

@finos/legend-graph

Version:
61 lines 4.78 kB
/** * 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 { EnumerationMapping } from '../metamodel/pure/packageableElements/mapping/EnumerationMapping.js'; import type { SetImplementation } from '../metamodel/pure/packageableElements/mapping/SetImplementation.js'; import type { Class } from '../metamodel/pure/packageableElements/domain/Class.js'; import type { Enumeration } from '../metamodel/pure/packageableElements/domain/Enumeration.js'; import type { Mapping } from '../metamodel/pure/packageableElements/mapping/Mapping.js'; import type { PropertyMapping } from '../metamodel/pure/packageableElements/mapping/PropertyMapping.js'; import { InstanceSetImplementation } from '../metamodel/pure/packageableElements/mapping/InstanceSetImplementation.js'; import { type EngineRuntime, type IdentifiedConnection } from '../metamodel/pure/packageableElements/runtime/Runtime.js'; import { OperationSetImplementation } from '../metamodel/pure/packageableElements/mapping/OperationSetImplementation.js'; import type { PackageableRuntime } from '../metamodel/pure/packageableElements/runtime/PackageableRuntime.js'; import { ObjectInputType } from '../metamodel/pure/packageableElements/mapping/DEPRECATED__MappingTest.js'; import type { AbstractProperty } from '..//metamodel/pure/packageableElements/domain/AbstractProperty.js'; /** * Get all included mappings, accounted for loop and duplication (which should be caught by compiler) */ export declare const getAllIncludedMappings: (mapping: Mapping) => Mapping[]; export declare const getAllClassMappings: (mapping: Mapping) => SetImplementation[]; export declare const getAllEnumerationMappings: (mapping: Mapping) => EnumerationMapping[]; export declare const extractClassMappingsFromAggregationAwareClassMappings: (mapping: Mapping) => SetImplementation[]; export declare const getOwnClassMappingById: (mapping: Mapping, id: string) => SetImplementation; export declare const getClassMappingById: (mapping: Mapping, id: string) => SetImplementation; export declare const getOwnClassMappingsByClass: (mapping: Mapping, _class: Class) => SetImplementation[]; export declare const getClassMappingsByClass: (mapping: Mapping, _class: Class) => SetImplementation[]; export declare const getEnumerationMappingsByEnumeration: (mapping: Mapping, enumeration: Enumeration) => EnumerationMapping[]; export declare const getAllSuperSetImplementations: (currentSetImpl: SetImplementation) => SetImplementation[]; export declare const findRootSetImplementation: (classMappingsWithSimilarTarget: SetImplementation[]) => SetImplementation | undefined; export declare const getRootSetImplementation: (mapping: Mapping, _class: Class) => SetImplementation | undefined; export declare const findPropertyMapping: (instanceSetImplementation: InstanceSetImplementation, propertyName: string, targetId: string | undefined) => PropertyMapping | undefined; /** * Get all child set implementation of an operation set implementation (including itself). * This takes into account loops and duplication. */ export declare const getAllChildSetImplementations: (operationSetImplementation: OperationSetImplementation) => SetImplementation[]; /** * Get all leaf set implementations (i.e. no operation) of an operation set implementation * This takes into account loops and duplication. */ export declare const getLeafSetImplementations: (operationSetImplementation: OperationSetImplementation) => SetImplementation[]; export declare const getObjectInputType: (type: string) => ObjectInputType; export declare const getMappingCompatibleClasses: (mapping: Mapping, classes: Class[]) => Class[]; export declare const getClassCompatibleMappings: (_class: Class, mappings: Mapping[]) => Mapping[]; export declare const findMappingLocalProperty: (mappings: Mapping[], propertyName: string) => AbstractProperty | undefined; export declare const getAllIdentifiedConnections: (runtime: EngineRuntime) => IdentifiedConnection[]; export declare const generateIdentifiedConnectionId: (runtime: EngineRuntime) => string; export declare const getMappingCompatibleRuntimes: (mapping: Mapping, runtimes: PackageableRuntime[]) => PackageableRuntime[]; //# sourceMappingURL=DSL_Mapping_Helper.d.ts.map