import { SModelIndex , SModelElementSchema } from 'sprotty' ; import { DependencyGraphNodeSchema , DependencyGraphEdgeSchema } from './graph-model' ; export interface IGraphGenerator { readonly nodes : DependencyGraphNodeSchema [ ] ; readonly edges : DependencyGraphEdgeSchema [ ] ; readonly index : SModelIndex < SModelElementSchema > ; generateNode ( name , version ? ) : DependencyGraphNodeSchema ; resolveNode ( node ) : Promise < DependencyGraphNodeSchema [ ] > ; unresolveNode ( node ) : void ; toggleResolveNode ( node ) : Promise < DependencyGraphNodeSchema [ ] > ; addDependencies ( node , dependencies , optional ? ) : DependencyGraphNodeSchema [ ] ; } export const IGraphGenerator = Symbol ( 'IGraphGenerator' ) ;