autouml
Version:
Autogenerate UML diagrams using d2
40 lines (39 loc) • 1.82 kB
TypeScript
import ts from "typescript";
import { autouml } from "../../typings/typings";
declare class FileMapper {
private map;
private currentScope;
private numconstructors;
private disallowNewFunctions;
private relations;
private tsoptions;
private umloptions;
constructor(tsoptions: ts.ParsedCommandLine, umloptions: autouml.cli.IOptions);
private getRelationsArray;
mapFiles(): [
autouml.mapping.IScope,
autouml.mapping.IConnector[]
];
getFiles(): Readonly<string[]>;
getTSOptions(): ts.ParsedCommandLine;
getUMLOptions(): autouml.cli.IOptions;
getRelations(): Map<string, Map<autouml.mapping.ConnectorType, Set<string>>>;
getCurrentFileName(): string;
/**
* Prevent the adding of new scopes. This is used to deal with
* inner functions. Note that each call to preventNewScope
* mostbe accompanied by a call to allowNewScopes
*/
preventNewFunctions(): void;
allowNewFunctions(): void;
startScope(name: string, type: autouml.mapping.ScopeType, scopeITSType?: autouml.mapping.ITSType): void;
endScope(): void;
getMapping(): autouml.mapping.IScope;
addEnumMember(name: string): void;
addPropertySignature(name: string, type: autouml.mapping.ITSType): void;
addPropertyDeclaration(name: string, access: Set<autouml.mapping.AccessModifier>, type: autouml.mapping.ITSType): void;
addMethod(name: string, access: Set<autouml.mapping.AccessModifier>, type: autouml.mapping.ITSType, parameters: autouml.mapping.IParam[], isConstructor?: boolean): void;
addRelation(src: autouml.mapping.ITSType, type: autouml.mapping.ConnectorType, dst: autouml.mapping.ITSType): void;
addCurrentScopeRelation(type: autouml.mapping.ConnectorType, dst: autouml.mapping.ITSType): void;
}
export { FileMapper };