-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.puml
94 lines (94 loc) · 3.45 KB
/
example.puml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
' This file was generated by tsplot (https://github.com/JanUnld/tsplot#readme)
@startuml
package tsplot {
interface ProjectFile {
+ source: ts.SourceFile
+ imports: Import[]
+ members: Member[]
}
interface ProjectViewOptionsWithFiles {
+ fileNames: string[]
+ compilerOptions: ts.CompilerOptions
}
interface ProjectViewOptionsWithTsConfigPath {
+ tsConfigPath: string
}
interface ProjectViewOptionsWithProgram {
+ program: ts.Program
}
interface ProjectViewOptions {
__ Type __
ProjectViewOptionsWithFiles | ProjectViewOptionsWithTsConfigPath | ProjectViewOptionsWithProgram
}
class ProjectView {
- _typeChecker: ts.TypeChecker
- _program: ts.Program
- _namespaces: Namespace[]
- _files: ProjectFile[]
- _members: Member[]
- _orphans: Member[]
+ filter: FilterSet<Member>
+ files: ProjectFile[]
+ members: Member[]
+ orphans: Member[]
+ namespaces: Namespace[]
+ getDependencyMembers(member: Member, options?: { depth?: number | undefined; }): Promise<Member[]>
+ getDependentMembers(member: Member, options?: { depth?: number | undefined; }): Promise<Member[]>
+ getMembersOfKind(kind: MemberKind): Member[]
+ getMemberByName(name: string, options?: { sourceFileName?: string | RegExp | undefined; }): Member | undefined
+ getFileOfMember(member: Member): ProjectFile | undefined
+ getFilesByPattern(...pattern: (string | RegExp)[]): ProjectFile[]
+ hasMember(memberOrName: string | Member): boolean
+ getExportedMembersOfFile(...filesOrPatterns: (string | RegExp | ProjectFile)[]): Member[]
+ getProgram(): ts.Program
- _initProjectFilesAndMembers(filters?: SourceFileFilterFn[]): void
- _initNamespacesAndOrphans(paths?: PathsLike): void
- _getDirectDeps(member: Member): Dependency[]
- _getUniqueName(member: Member): string
}
interface ProjectGraphOptions {
+ filter?: MemberFilterFn[] | FilterSet<Member>
+ members: Member[]
}
class ProjectGraph {
- _members: Member[]
+ filter: FilterSet<Member>
+ members: Member[]
+ edges: Edge[]
+ getEdgesOfMember(member: Member): Edge[]
+ {static} fromView(view: ProjectView, options?: { keepFilter?: boolean | undefined; filter?: MemberFilterFn[] | FilterSet<Member> | undefined; }): ProjectGraph
}
interface TemplateContext {
+ projectView: ProjectView
+ indentSize?: number
}
interface TemplateFileRenderer {
+ setBaseDir(): void
+ canRender(): boolean
+ render(): string
}
protocol render {
__ Function __
(templateName: KnownTemplate | string, options: RenderOptions) => string
}
interface RenderOptions {
+ target: string
+ context: TemplateContext
+ renderer?: TemplateFileRenderer
+ baseDir?: string
}
}
ProjectViewOptionsWithFiles..>ProjectViewOptions
ProjectViewOptionsWithTsConfigPath..>ProjectViewOptions
ProjectViewOptionsWithProgram..>ProjectViewOptions
ProjectViewOptions..>ProjectView
ProjectFile..>ProjectView
ProjectGraphOptions..>ProjectGraph
ProjectView-->ProjectGraph
ProjectView-->TemplateContext
TemplateContext..>TemplateFileRenderer
TemplateContext..>RenderOptions
TemplateFileRenderer..>RenderOptions
RenderOptions..>render
ProjectGraph-->render
@enduml