ts2famix 1.4.1 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (210) hide show
  1. package/LICENSE +1 -0
  2. package/README.md +30 -61
  3. package/dist/analyze.js +4 -2
  4. package/dist/analyze_functions/process_functions.js +285 -131
  5. package/dist/famix_functions/EntityDictionary.js +864 -231
  6. package/dist/famix_functions/helpers_creation.js +61 -10
  7. package/dist/fqn.js +160 -111
  8. package/dist/lib/famix/famix_JSON_exporter.js +55 -0
  9. package/dist/lib/famix/famix_base_element.js +18 -0
  10. package/dist/lib/famix/famix_repository.js +224 -0
  11. package/dist/lib/famix/{src/index.js → index.js} +1 -0
  12. package/dist/lib/famix/model/famix/access.js +40 -0
  13. package/dist/lib/famix/model/famix/accessor.js +17 -0
  14. package/dist/lib/famix/model/famix/alias.js +33 -0
  15. package/dist/lib/famix/model/famix/arrow_function.js +17 -0
  16. package/dist/lib/famix/model/famix/behavioral_entity.js +79 -0
  17. package/dist/lib/famix/model/famix/class.js +71 -0
  18. package/dist/lib/famix/model/famix/comment.js +39 -0
  19. package/dist/lib/famix/model/famix/concretisation.js +31 -0
  20. package/dist/lib/famix/model/famix/container_entity.js +126 -0
  21. package/dist/lib/famix/model/famix/decorator.js +32 -0
  22. package/dist/lib/famix/model/famix/entity.js +17 -0
  23. package/dist/lib/famix/model/famix/enum.js +31 -0
  24. package/dist/lib/famix/model/famix/enum_value.js +25 -0
  25. package/dist/lib/famix/model/famix/function.js +17 -0
  26. package/dist/lib/famix/model/famix/import_clause.js +41 -0
  27. package/dist/lib/famix/model/famix/index.js +86 -0
  28. package/dist/lib/famix/model/famix/indexed_file_anchor.js +38 -0
  29. package/dist/lib/famix/model/famix/inheritance.js +33 -0
  30. package/dist/lib/famix/model/famix/interface.js +64 -0
  31. package/dist/lib/famix/model/famix/invocation.js +54 -0
  32. package/dist/lib/famix/model/famix/method.js +67 -0
  33. package/dist/lib/famix/model/famix/module.js +60 -0
  34. package/dist/lib/famix/model/famix/named_entity.js +78 -0
  35. package/dist/lib/famix/model/famix/parameter.js +25 -0
  36. package/dist/lib/famix/model/famix/parameter_concretisation.js +44 -0
  37. package/dist/lib/famix/model/famix/parameter_type.js +45 -0
  38. package/dist/lib/famix/model/famix/parametric_arrow_function.js +31 -0
  39. package/dist/lib/famix/model/famix/parametric_class.js +44 -0
  40. package/dist/lib/famix/model/famix/parametric_function.js +31 -0
  41. package/dist/lib/famix/model/famix/parametric_interface.js +44 -0
  42. package/dist/lib/famix/model/famix/parametric_method.js +31 -0
  43. package/dist/lib/famix/model/famix/primitive_type.js +17 -0
  44. package/dist/lib/famix/model/famix/property.js +73 -0
  45. package/dist/lib/famix/model/famix/reference.js +33 -0
  46. package/dist/lib/famix/model/famix/scoping_entity.js +36 -0
  47. package/dist/lib/famix/model/famix/script_entity.js +29 -0
  48. package/dist/lib/famix/model/famix/source_anchor.js +27 -0
  49. package/dist/lib/famix/model/famix/source_language.js +35 -0
  50. package/dist/lib/famix/model/famix/sourced_entity.js +60 -0
  51. package/dist/lib/famix/model/famix/structural_entity.js +39 -0
  52. package/dist/lib/famix/model/famix/type.js +73 -0
  53. package/dist/lib/famix/model/famix/variable.js +24 -0
  54. package/dist/lib/ts-complex/cyclomatic-service.js +3 -3
  55. package/dist/refactorer/refactor-getter-setter.js +142 -0
  56. package/dist/ts2famix-cli-wrapper.js +42 -0
  57. package/dist/ts2famix-cli.js +8 -1
  58. package/dist/ts2famix-tsconfig.js +1 -0
  59. package/doc-uml/famix-typescript-model.puml +608 -0
  60. package/doc-uml/famix-typescript-model.svg +1 -0
  61. package/jest.config.json +2 -1
  62. package/package.json +13 -12
  63. package/src/analyze.ts +24 -23
  64. package/src/analyze_functions/process_functions.ts +310 -129
  65. package/src/famix_functions/EntityDictionary.ts +949 -271
  66. package/src/famix_functions/helpers_creation.ts +64 -6
  67. package/src/fqn.ts +169 -96
  68. package/{dist/lib/famix/src/famix_JSON_exporter.js → src/lib/famix/famix_JSON_exporter.ts} +16 -14
  69. package/src/lib/famix/famix_base_element.ts +22 -0
  70. package/{dist/lib/famix/src/famix_repository.js → src/lib/famix/famix_repository.ts} +96 -75
  71. package/src/lib/famix/model/famix/access.ts +50 -0
  72. package/src/lib/famix/model/famix/alias.ts +39 -0
  73. package/src/lib/famix/{src/model/famix/implicit_variable.ts → model/famix/arrow_function.ts} +3 -3
  74. package/src/lib/famix/model/famix/behavioral_entity.ts +97 -0
  75. package/src/lib/famix/model/famix/class.ts +85 -0
  76. package/src/lib/famix/model/famix/comment.ts +47 -0
  77. package/src/lib/famix/model/famix/concretisation.ts +40 -0
  78. package/src/lib/famix/model/famix/container_entity.ts +160 -0
  79. package/src/lib/famix/model/famix/decorator.ts +37 -0
  80. package/src/lib/famix/model/famix/enum.ts +30 -0
  81. package/src/lib/famix/model/famix/enum_value.ts +28 -0
  82. package/src/lib/famix/model/famix/import_clause.ts +51 -0
  83. package/src/lib/famix/{src/model → model}/famix/index.ts +8 -7
  84. package/src/lib/famix/model/famix/indexed_file_anchor.ts +46 -0
  85. package/src/lib/famix/model/famix/inheritance.ts +40 -0
  86. package/src/lib/famix/model/famix/interface.ts +75 -0
  87. package/src/lib/famix/model/famix/invocation.ts +65 -0
  88. package/src/lib/famix/model/famix/method.ts +89 -0
  89. package/src/lib/famix/model/famix/module.ts +71 -0
  90. package/src/lib/famix/model/famix/named_entity.ts +95 -0
  91. package/src/lib/famix/{src/model → model}/famix/parameter.ts +11 -12
  92. package/src/lib/famix/model/famix/parameter_concretisation.ts +51 -0
  93. package/src/lib/famix/model/famix/parameter_type.ts +58 -0
  94. package/src/lib/famix/model/famix/parametric_arrow_function.ts +32 -0
  95. package/src/lib/famix/model/famix/parametric_class.ts +49 -0
  96. package/src/lib/famix/model/famix/parametric_function.ts +32 -0
  97. package/src/lib/famix/model/famix/parametric_interface.ts +49 -0
  98. package/src/lib/famix/model/famix/parametric_method.ts +32 -0
  99. package/src/lib/famix/model/famix/primitive_type.ts +15 -0
  100. package/src/lib/famix/model/famix/property.ts +94 -0
  101. package/src/lib/famix/model/famix/reference.ts +40 -0
  102. package/src/lib/famix/model/famix/scoping_entity.ts +35 -0
  103. package/src/lib/famix/model/famix/script_entity.ts +34 -0
  104. package/src/lib/famix/model/famix/source_anchor.ts +30 -0
  105. package/src/lib/famix/model/famix/source_language.ts +35 -0
  106. package/src/lib/famix/model/famix/sourced_entity.ts +70 -0
  107. package/src/lib/famix/model/famix/structural_entity.ts +43 -0
  108. package/src/lib/famix/model/famix/type.ts +87 -0
  109. package/src/lib/famix/model/famix/variable.ts +27 -0
  110. package/src/lib/famix/package.json +1 -1
  111. package/src/lib/ts-complex/cyclomatic-service.ts +10 -10
  112. package/src/refactorer/refactor-getter-setter.ts +140 -0
  113. package/src/ts2famix-cli-wrapper.ts +21 -0
  114. package/src/ts2famix-cli.ts +8 -2
  115. package/tsconfig.check-tests.json +14 -0
  116. package/tsconfig.json +71 -69
  117. package/dist/famix2puml.js +0 -125
  118. package/dist/lib/famix/src/famix_base_element.js +0 -17
  119. package/dist/lib/famix/src/model/famix/access.js +0 -39
  120. package/dist/lib/famix/src/model/famix/accessor.js +0 -16
  121. package/dist/lib/famix/src/model/famix/alias.js +0 -32
  122. package/dist/lib/famix/src/model/famix/association.js +0 -36
  123. package/dist/lib/famix/src/model/famix/behavioral_entity.js +0 -81
  124. package/dist/lib/famix/src/model/famix/class.js +0 -70
  125. package/dist/lib/famix/src/model/famix/comment.js +0 -38
  126. package/dist/lib/famix/src/model/famix/container_entity.js +0 -125
  127. package/dist/lib/famix/src/model/famix/decorator.js +0 -31
  128. package/dist/lib/famix/src/model/famix/entity.js +0 -16
  129. package/dist/lib/famix/src/model/famix/enum.js +0 -30
  130. package/dist/lib/famix/src/model/famix/enum_value.js +0 -24
  131. package/dist/lib/famix/src/model/famix/function.js +0 -16
  132. package/dist/lib/famix/src/model/famix/implicit_variable.js +0 -16
  133. package/dist/lib/famix/src/model/famix/import_clause.js +0 -39
  134. package/dist/lib/famix/src/model/famix/index.js +0 -83
  135. package/dist/lib/famix/src/model/famix/indexed_file_anchor.js +0 -51
  136. package/dist/lib/famix/src/model/famix/inheritance.js +0 -32
  137. package/dist/lib/famix/src/model/famix/interface.js +0 -63
  138. package/dist/lib/famix/src/model/famix/invocation.js +0 -53
  139. package/dist/lib/famix/src/model/famix/method.js +0 -66
  140. package/dist/lib/famix/src/model/famix/module.js +0 -31
  141. package/dist/lib/famix/src/model/famix/named_entity.js +0 -77
  142. package/dist/lib/famix/src/model/famix/namespace.js +0 -24
  143. package/dist/lib/famix/src/model/famix/parameter.js +0 -24
  144. package/dist/lib/famix/src/model/famix/parameter_type.js +0 -24
  145. package/dist/lib/famix/src/model/famix/parameterizable_class.js +0 -30
  146. package/dist/lib/famix/src/model/famix/parameterizable_interface.js +0 -30
  147. package/dist/lib/famix/src/model/famix/parameterized_type.js +0 -36
  148. package/dist/lib/famix/src/model/famix/primitive_type.js +0 -16
  149. package/dist/lib/famix/src/model/famix/property.js +0 -44
  150. package/dist/lib/famix/src/model/famix/reference.js +0 -32
  151. package/dist/lib/famix/src/model/famix/scoping_entity.js +0 -35
  152. package/dist/lib/famix/src/model/famix/script_entity.js +0 -30
  153. package/dist/lib/famix/src/model/famix/source_anchor.js +0 -26
  154. package/dist/lib/famix/src/model/famix/source_language.js +0 -35
  155. package/dist/lib/famix/src/model/famix/sourced_entity.js +0 -59
  156. package/dist/lib/famix/src/model/famix/structural_entity.js +0 -38
  157. package/dist/lib/famix/src/model/famix/text_anchor.js +0 -37
  158. package/dist/lib/famix/src/model/famix/type.js +0 -71
  159. package/dist/lib/famix/src/model/famix/variable.js +0 -23
  160. package/doc-uml/metamodel-full.svg +0 -1
  161. package/doc-uml/metamodel.svg +0 -1
  162. package/jest.config-old.ts +0 -199
  163. package/plantuml.jar +0 -0
  164. package/src/famix2puml.ts +0 -119
  165. package/src/lib/famix/package-lock.json +0 -301
  166. package/src/lib/famix/readme.md +0 -5
  167. package/src/lib/famix/src/famix_JSON_exporter.ts +0 -56
  168. package/src/lib/famix/src/famix_base_element.ts +0 -22
  169. package/src/lib/famix/src/famix_repository.ts +0 -243
  170. package/src/lib/famix/src/model/famix/access.ts +0 -53
  171. package/src/lib/famix/src/model/famix/alias.ts +0 -41
  172. package/src/lib/famix/src/model/famix/association.ts +0 -44
  173. package/src/lib/famix/src/model/famix/behavioral_entity.ts +0 -107
  174. package/src/lib/famix/src/model/famix/class.ts +0 -86
  175. package/src/lib/famix/src/model/famix/comment.ts +0 -50
  176. package/src/lib/famix/src/model/famix/container_entity.ts +0 -165
  177. package/src/lib/famix/src/model/famix/decorator.ts +0 -39
  178. package/src/lib/famix/src/model/famix/enum.ts +0 -31
  179. package/src/lib/famix/src/model/famix/enum_value.ts +0 -29
  180. package/src/lib/famix/src/model/famix/import_clause.ts +0 -53
  181. package/src/lib/famix/src/model/famix/indexed_file_anchor.ts +0 -71
  182. package/src/lib/famix/src/model/famix/inheritance.ts +0 -42
  183. package/src/lib/famix/src/model/famix/interface.ts +0 -75
  184. package/src/lib/famix/src/model/famix/invocation.ts +0 -68
  185. package/src/lib/famix/src/model/famix/method.ts +0 -96
  186. package/src/lib/famix/src/model/famix/module.ts +0 -31
  187. package/src/lib/famix/src/model/famix/named_entity.ts +0 -98
  188. package/src/lib/famix/src/model/famix/namespace.ts +0 -28
  189. package/src/lib/famix/src/model/famix/parameter_type.ts +0 -33
  190. package/src/lib/famix/src/model/famix/parameterizable_class.ts +0 -31
  191. package/src/lib/famix/src/model/famix/parameterizable_interface.ts +0 -31
  192. package/src/lib/famix/src/model/famix/parameterized_type.ts +0 -40
  193. package/src/lib/famix/src/model/famix/primitive_type.ts +0 -15
  194. package/src/lib/famix/src/model/famix/property.ts +0 -54
  195. package/src/lib/famix/src/model/famix/reference.ts +0 -42
  196. package/src/lib/famix/src/model/famix/scoping_entity.ts +0 -35
  197. package/src/lib/famix/src/model/famix/script_entity.ts +0 -38
  198. package/src/lib/famix/src/model/famix/source_anchor.ts +0 -31
  199. package/src/lib/famix/src/model/famix/source_language.ts +0 -37
  200. package/src/lib/famix/src/model/famix/sourced_entity.ts +0 -73
  201. package/src/lib/famix/src/model/famix/structural_entity.ts +0 -44
  202. package/src/lib/famix/src/model/famix/text_anchor.ts +0 -49
  203. package/src/lib/famix/src/model/famix/type.ts +0 -88
  204. package/src/lib/famix/src/model/famix/variable.ts +0 -28
  205. package/src/lib/famix/tsconfig.json +0 -27
  206. package/src/lib/famix/tslint.json +0 -15
  207. /package/src/lib/famix/{src/index.ts → index.ts} +0 -0
  208. /package/src/lib/famix/{src/model → model}/famix/accessor.ts +0 -0
  209. /package/src/lib/famix/{src/model → model}/famix/entity.ts +0 -0
  210. /package/src/lib/famix/{src/model → model}/famix/function.ts +0 -0
@@ -1,35 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SourceLanguage = void 0;
4
- const famix_JSON_exporter_1 = require("../../famix_JSON_exporter");
5
- const entity_1 = require("./entity");
6
- class SourceLanguage extends entity_1.Entity {
7
- constructor() {
8
- super(...arguments);
9
- this.sourcedEntities = new Set();
10
- }
11
- // name of the source language
12
- get name() {
13
- return "TypeScript";
14
- }
15
- getSourcedEntities() {
16
- return this.sourcedEntities;
17
- }
18
- addSourcedEntity(sourcedEntity) {
19
- if (!this.sourcedEntities.has(sourcedEntity)) {
20
- this.sourcedEntities.add(sourcedEntity);
21
- sourcedEntity.setDeclaredSourceLanguage(this);
22
- }
23
- }
24
- getJSON() {
25
- const json = new famix_JSON_exporter_1.FamixJSONExporter("SourceLanguage", this);
26
- this.addPropertiesToExporter(json);
27
- return json.getJSON();
28
- }
29
- addPropertiesToExporter(exporter) {
30
- super.addPropertiesToExporter(exporter);
31
- exporter.addProperty("name", this.name);
32
- exporter.addProperty("sourcedEntities", this.getSourcedEntities());
33
- }
34
- }
35
- exports.SourceLanguage = SourceLanguage;
@@ -1,59 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SourcedEntity = void 0;
4
- const famix_JSON_exporter_1 = require("../../famix_JSON_exporter");
5
- const entity_1 = require("./entity");
6
- const analyze_1 = require("../../../../../analyze");
7
- class SourcedEntity extends entity_1.Entity {
8
- constructor() {
9
- super(...arguments);
10
- this.comments = new Set();
11
- }
12
- getIsStub() {
13
- return this.isStub;
14
- }
15
- setIsStub(isStub) {
16
- this.isStub = isStub;
17
- }
18
- getSourceAnchor() {
19
- return this.sourceAnchor;
20
- }
21
- setSourceAnchor(sourceAnchor) {
22
- if (this.sourceAnchor === undefined) {
23
- this.sourceAnchor = sourceAnchor;
24
- sourceAnchor.setElement(this);
25
- }
26
- }
27
- getComments() {
28
- return this.comments;
29
- }
30
- addComment(comment) {
31
- if (!this.comments.has(comment)) {
32
- this.comments.add(comment);
33
- comment.setContainer(this);
34
- }
35
- else {
36
- analyze_1.logger.warn("WARNING: adding comment that is already in comments: " + comment.getJSON() + " to " + this.getJSON());
37
- }
38
- }
39
- getDeclaredSourceLanguage() {
40
- return this.declaredSourceLanguage;
41
- }
42
- setDeclaredSourceLanguage(declaredSourceLanguage) {
43
- this.declaredSourceLanguage = declaredSourceLanguage;
44
- declaredSourceLanguage.addSourcedEntity(this);
45
- }
46
- getJSON() {
47
- const json = new famix_JSON_exporter_1.FamixJSONExporter("SourcedEntity", this);
48
- this.addPropertiesToExporter(json);
49
- return json.getJSON();
50
- }
51
- addPropertiesToExporter(exporter) {
52
- super.addPropertiesToExporter(exporter);
53
- exporter.addProperty("isStub", this.getIsStub());
54
- exporter.addProperty("sourceAnchor", this.getSourceAnchor());
55
- exporter.addProperty("comments", this.getComments());
56
- exporter.addProperty("declaredSourceLanguage", this.getDeclaredSourceLanguage());
57
- }
58
- }
59
- exports.SourcedEntity = SourcedEntity;
@@ -1,38 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.StructuralEntity = void 0;
4
- const famix_JSON_exporter_1 = require("../../famix_JSON_exporter");
5
- const named_entity_1 = require("./named_entity");
6
- class StructuralEntity extends named_entity_1.NamedEntity {
7
- constructor() {
8
- super(...arguments);
9
- this.incomingAccesses = new Set();
10
- }
11
- getIncomingAccesses() {
12
- return this.incomingAccesses;
13
- }
14
- addIncomingAccess(incomingAccess) {
15
- if (!this.incomingAccesses.has(incomingAccess)) {
16
- this.incomingAccesses.add(incomingAccess);
17
- incomingAccess.setVariable(this);
18
- }
19
- }
20
- getDeclaredType() {
21
- return this.declaredType;
22
- }
23
- setDeclaredType(declaredType) {
24
- this.declaredType = declaredType;
25
- declaredType.addStructureWithDeclaredType(this);
26
- }
27
- getJSON() {
28
- const json = new famix_JSON_exporter_1.FamixJSONExporter("StructuralEntity", this);
29
- this.addPropertiesToExporter(json);
30
- return json.getJSON();
31
- }
32
- addPropertiesToExporter(exporter) {
33
- super.addPropertiesToExporter(exporter);
34
- exporter.addProperty("incomingAccesses", this.getIncomingAccesses());
35
- exporter.addProperty("declaredType", this.getDeclaredType());
36
- }
37
- }
38
- exports.StructuralEntity = StructuralEntity;
@@ -1,37 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TextAnchor = void 0;
4
- const famix_JSON_exporter_1 = require("../../famix_JSON_exporter");
5
- const source_anchor_1 = require("./source_anchor");
6
- class TextAnchor extends source_anchor_1.SourceAnchor {
7
- getStartPos() {
8
- return this.startPos;
9
- }
10
- setStartPos(startPos) {
11
- this.startPos = startPos;
12
- }
13
- getEndPos() {
14
- return this.endPos;
15
- }
16
- setEndPos(endPos) {
17
- this.endPos = endPos;
18
- }
19
- getFileName() {
20
- return this.fileName;
21
- }
22
- setFileName(fileName) {
23
- this.fileName = fileName;
24
- }
25
- getJSON() {
26
- const json = new famix_JSON_exporter_1.FamixJSONExporter("TextAnchor", this);
27
- this.addPropertiesToExporter(json);
28
- return json.getJSON();
29
- }
30
- addPropertiesToExporter(exporter) {
31
- super.addPropertiesToExporter(exporter);
32
- exporter.addProperty("startPos", this.getStartPos());
33
- exporter.addProperty("endPos", this.getEndPos());
34
- exporter.addProperty("fileName", this.getFileName());
35
- }
36
- }
37
- exports.TextAnchor = TextAnchor;
@@ -1,71 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Type = void 0;
4
- const famix_JSON_exporter_1 = require("../../famix_JSON_exporter");
5
- const container_entity_1 = require("./container_entity");
6
- class Type extends container_entity_1.ContainerEntity {
7
- constructor() {
8
- super(...arguments);
9
- this.typeAliases = new Set();
10
- this.structuresWithDeclaredType = new Set();
11
- this.behavioralEntitiesWithDeclaredType = new Set();
12
- this.incomingReferences = new Set();
13
- }
14
- getContainer() {
15
- return this.container;
16
- }
17
- setContainer(container) {
18
- this.container = container;
19
- container.addType(this);
20
- }
21
- getTypeAliases() {
22
- return this.typeAliases;
23
- }
24
- addTypeAlias(typeAlias) {
25
- if (!this.typeAliases.has(typeAlias)) {
26
- this.typeAliases.add(typeAlias);
27
- typeAlias.setAliasedEntity(this);
28
- }
29
- }
30
- getStructuresWithDeclaredType() {
31
- return this.structuresWithDeclaredType;
32
- }
33
- addStructureWithDeclaredType(structureWithDeclaredType) {
34
- if (!this.structuresWithDeclaredType.has(structureWithDeclaredType)) {
35
- this.structuresWithDeclaredType.add(structureWithDeclaredType);
36
- structureWithDeclaredType.setDeclaredType(this);
37
- }
38
- }
39
- getBehavioralEntitiesWithDeclaredType() {
40
- return this.behavioralEntitiesWithDeclaredType;
41
- }
42
- addBehavioralEntityWithDeclaredType(behavioralEntityWithDeclaredType) {
43
- if (!this.behavioralEntitiesWithDeclaredType.has(behavioralEntityWithDeclaredType)) {
44
- this.behavioralEntitiesWithDeclaredType.add(behavioralEntityWithDeclaredType);
45
- behavioralEntityWithDeclaredType.setDeclaredType(this);
46
- }
47
- }
48
- getIncomingReferences() {
49
- return this.incomingReferences;
50
- }
51
- addIncomingReference(incomingReference) {
52
- if (!this.incomingReferences.has(incomingReference)) {
53
- this.incomingReferences.add(incomingReference);
54
- incomingReference.setTarget(this);
55
- }
56
- }
57
- getJSON() {
58
- const json = new famix_JSON_exporter_1.FamixJSONExporter("Type", this);
59
- this.addPropertiesToExporter(json);
60
- return json.getJSON();
61
- }
62
- addPropertiesToExporter(exporter) {
63
- super.addPropertiesToExporter(exporter);
64
- exporter.addProperty("container", this.getContainer());
65
- exporter.addProperty("typeAliases", this.getTypeAliases());
66
- exporter.addProperty("structuresWithDeclaredType", this.getStructuresWithDeclaredType());
67
- exporter.addProperty("behavioralEntitiesWithDeclaredType", this.getBehavioralEntitiesWithDeclaredType());
68
- exporter.addProperty("incomingReferences", this.getIncomingReferences());
69
- }
70
- }
71
- exports.Type = Type;
@@ -1,23 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Variable = void 0;
4
- const famix_JSON_exporter_1 = require("../../famix_JSON_exporter");
5
- const structural_entity_1 = require("./structural_entity");
6
- class Variable extends structural_entity_1.StructuralEntity {
7
- getParentContainerEntity() {
8
- return this.parentContainerEntity;
9
- }
10
- setParentContainerEntity(parentContainerEntity) {
11
- this.parentContainerEntity = parentContainerEntity;
12
- }
13
- getJSON() {
14
- const json = new famix_JSON_exporter_1.FamixJSONExporter("Variable", this);
15
- this.addPropertiesToExporter(json);
16
- return json.getJSON();
17
- }
18
- addPropertiesToExporter(exporter) {
19
- super.addPropertiesToExporter(exporter);
20
- exporter.addProperty("parentBehaviouralEntity", this.getParentContainerEntity());
21
- }
22
- }
23
- exports.Variable = Variable;
@@ -1 +0,0 @@
1
- <?xml version="1.0" encoding="us-ascii" standalone="no"?><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" contentStyleType="text/css" height="206px" preserveAspectRatio="none" style="width:303px;height:206px;background:#FFFFFF;" version="1.1" viewBox="0 0 303 206" width="303px" zoomAndPan="magnify"><defs/><g><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="261" x="5" y="19">Dot Executable: /opt/local/bin/dot</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="237" x="5" y="35.2969">Dot executable does not exist</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="291" x="5" y="51.5938">Cannot find Graphviz. You should try</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="67.8906">&#160;</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="79" x="5" y="84.1875">@startuml</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="57" x="5" y="100.4844">testdot</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="72" x="5" y="116.7813">@enduml</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="133.0781">&#160;</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="17" x="10" y="149.375">or</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="165.6719">&#160;</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="227" x="5" y="181.9688">java -jar plantuml.jar -testdot</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="198.2656">&#160;</text><!--SRC=[xHpBSjmsykwlu96koAuzRZ5RIicIx9eaihGUnJviRRau78p4DOUS9KYj5Dl_ldWsq423CtOYUX_nGHwYdsW0_G10Lat9UNRU3lNmaB7xWRLhdhqij_NzYvApyuPjMJja7vzaujztDspuSNdvEdzQP7pew_P6DvVhzLNVxLW_r8nVT-VtkwuVM9ypywFG32MfXGaETrszVlBvIQKKM7PZNx6Vo_PcB6yOA6BqqkAVSOMqLer2K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zjtMLhVYRo0xUfVVqEj3c4CvUBxWVTtMqeD88g4dQ-GN0LZZTrVu5RsaZsmzvVPxe-zlXfD_pxOV_WeMwxrNq7LGDD4Hxwr9PQLhuietSRTZzpInwoROoSGBbZkmBrkyaU9BC7TevKPcYx9iUwiMJ_v09bPMoyl3RX6qdv-KvbNCp0l_nAU7dQlLpnyjtUVi4L_92X6Y3xcIxldPQjniM6_sLuNHTQlP1M6R-ZwbwKEERI-tIlowVd9o_Hi0]--></g></svg>
@@ -1 +0,0 @@
1
- <?xml version="1.0" encoding="us-ascii" standalone="no"?><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" contentStyleType="text/css" height="206px" preserveAspectRatio="none" style="width:303px;height:206px;background:#FFFFFF;" version="1.1" viewBox="0 0 303 206" width="303px" zoomAndPan="magnify"><defs/><g><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="261" x="5" y="19">Dot Executable: /opt/local/bin/dot</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="237" x="5" y="35.2969">Dot executable does not exist</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="291" x="5" y="51.5938">Cannot find Graphviz. You should try</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="67.8906">&#160;</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="79" x="5" y="84.1875">@startuml</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="57" x="5" y="100.4844">testdot</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="72" x="5" y="116.7813">@enduml</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="133.0781">&#160;</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="17" x="10" y="149.375">or</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="165.6719">&#160;</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="227" x="5" y="181.9688">java -jar plantuml.jar -testdot</text><text fill="#33FF02" font-family="sans-serif" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="5" x="5" y="198.2656">&#160;</text><!--SRC=[xHpBSjouyUwlO6vqhUpACSLDQKkMPDVihYp5exKFgPIBmy58Z3daX20LARR_FNWsq423C_Qkw3pM1tc8Vg81z0C0-OUwhPfnpJB-eMxvS_FqV3TkcoTLKtAUdRT3FJnax7vWxPfdByjjVV-YvEoyOLlM3jd79vduzzqD6tvSNhxEdnOP7_gwlT7DvNfzrNSxrWyruzVT-VskwmVMvypyA3H3IMfXWiDTLw-VV3OABBknhzZFPNipbZSC535wQV7Fk49QgqOXgSYMRFZpqcjyEDOAjUMMOHM5vajCBJkHeXSTGisvB_cXo13GTkMHBNJQRTLGMDCW7Qo5QlxZygohYcpLTGqhMr1geG5IBmJY3XJI-lrwLdNjKDQjr1G91W6d5a7PDKRXFagAMoHIT3WQnrFT7fgOEqX0ETC0wPwSjDLjroScCDFBAML3izhI5hG8D9zP-xaEN4Ou3vV3kAAceModPw6218HeGd3Fm0KoTx36TQCpeu_40wGqqs0ogjLdV8vPYyVUdDHWwrGmWZ2wQSWDdy8kPoHapOI5UxR6ph08d2C8FIFHNRSn0KyI72PsfjbrmdbNrULGT-sqgsi5jF3HGRFN0Y8rYs3Sm29ID0gxdjtLtSXfvbS6cX80S9BDJ4PyBU8VtvML2wJBgji92TY4Ep7gxI11ShHz3DTTXw8cLep4CLAQvrpk2VNKzXzY3xP0TLitQw4m6CmiS7XsIzoXs4KU8WdbeIbNdE6nS4CocndwUZS4LY1dGJjkLwo_tFmipC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TTyNasoyqqQ7UvsjyvI5TSPUuoPZdlz22URUtfzwhPlj9HBFhZTnQLsDiYxwaWjuBnEYJ6ejsqnNPnqotUN9-i6yT1ogfjlD_Z6NZA_jzvZvMuNAQxxFWamwoyQeSRks2i6IGHsdsW2y5mgGGo7pHwhg2mtAKhMTiKuxDe44Uv3CsHzVU2MTptRrXJIcdkjGaBrUyQyO1gNMK-Qt2IScqpwkJJ0OArw1n7H5yEiq_q_G-K6YJPaYMuAQ4NncWT0UEd8DK7sLyzEU0DD95whqD3NuxTUQfKGuzg3NODJ2359Oe7EhrQJVgJCuhWPzH8mELng_9-cKL77F8lvfhM3bJp9z-YOAoqlKwJrJn2Bpp31JfehC3AU_5msAT8ryMpacQwak_u41prLi4SjlfZzBVRBf-MmxE3tmE-lXUVNQW2Iy3qQienBPkCHzkpHuQABU7YLUxJFRHgqw0p9KbawH1kG7afY2OfDKu0Q6NX-yR5RnK0pwGoKxomGai4BkASv8wg3XZykIdobntwtqgahw6uEBUKKixf-_UwmfDgNF21VRBljlQwbRy3MH7x_8RUdq8SoW7pnUyhzjQUX199FHaZVmY06lyxWg_efVqaQsdt7vlzFtDSFBlsVR3Ny5YlVSAkWwA9ZhYlJMfh7HDNFacxdRidYPstGGxcNZ1SWVsPOitKdm9vWwjtCXiKPPjRzNYoH_8nCfgUNdOBOBsyvFIl8gPUU6V-FImSxNw-QEb-vmzuYjP8KBq8LVIFJzRZPiDwyt-gZ2wRZMx86nJtwSqVSYnxULMYL_NJqwkVmC0]--></g></svg>
@@ -1,199 +0,0 @@
1
- /*
2
- * For a detailed explanation regarding each configuration property and type check, visit:
3
- * https://jestjs.io/docs/configuration
4
- */
5
-
6
- export default {
7
- // All imported modules in your tests should be mocked automatically
8
- // automock: false,
9
-
10
- // Stop running tests after `n` failures
11
- // bail: 0,
12
-
13
- // The directory where Jest should store its cached dependency information
14
- // cacheDirectory: "",
15
-
16
- // Automatically clear mock calls and instances between every test
17
- // clearMocks: false,
18
-
19
- // Indicates whether the coverage information should be collected while executing the test
20
- collectCoverage: false,
21
-
22
- // An array of glob patterns indicating a set of files for which coverage information should be collected
23
- // collectCoverageFrom: undefined,
24
-
25
- // The directory where Jest should output its coverage files
26
- coverageDirectory: "coverage",
27
-
28
- // An array of regexp pattern strings used to skip coverage collection
29
- // coveragePathIgnorePatterns: [
30
- // "\\\\node_modules\\\\"
31
- // ],
32
-
33
- // Indicates which provider should be used to instrument code for coverage
34
- coverageProvider: "babel",
35
-
36
- // A list of reporter names that Jest uses when writing coverage reports
37
- // coverageReporters: [
38
- // "json",
39
- // "text",
40
- // "lcov",
41
- // "clover"
42
- // ],
43
-
44
- // An object that configures minimum threshold enforcement for coverage results
45
- // coverageThreshold: undefined,
46
-
47
- // A path to a custom dependency extractor
48
- // dependencyExtractor: undefined,
49
-
50
- // Make calling deprecated APIs throw helpful error messages
51
- // errorOnDeprecated: false,
52
-
53
- // Force coverage collection from ignored files using an array of glob patterns
54
- // forceCoverageMatch: [],
55
-
56
- // A path to a module which exports an async function that is triggered once before all test suites
57
- // globalSetup: undefined,
58
-
59
- // A path to a module which exports an async function that is triggered once after all test suites
60
- // globalTeardown: undefined,
61
-
62
- // A set of global variables that need to be available in all test environments
63
- // globals: {},
64
-
65
- // The maximum amount of workers used to run your tests. Can be specified as % or a number. E.g. maxWorkers: 10% will use 10% of your CPU amount + 1 as the maximum worker number. maxWorkers: 2 will use a maximum of 2 workers.
66
- // maxWorkers: 1,
67
-
68
- // An array of directory names to be searched recursively up from the requiring module's location
69
- // moduleDirectories: [
70
- // "node_modules"
71
- // ],
72
-
73
- // An array of file extensions your modules use
74
- // moduleFileExtensions: [
75
- // "js",
76
- // "jsx",
77
- // "ts",
78
- // "tsx",
79
- // "json",
80
- // "node"
81
- // ],
82
-
83
- // A map from regular expressions to module names or to arrays of module names that allow to stub out resources with a single module
84
- // moduleNameMapper: {},
85
-
86
- // An array of regexp pattern strings, matched against all module paths before considered 'visible' to the module loader
87
- // modulePathIgnorePatterns: [],
88
-
89
- // Activates notifications for test results
90
- // notify: false,
91
-
92
- // An enum that specifies notification mode. Requires { notify: true }
93
- // notifyMode: "failure-change",
94
-
95
- // A preset that is used as a base for Jest's configuration
96
- // preset: undefined,
97
-
98
- // Run tests from one or more projects
99
- // projects: undefined,
100
-
101
- // Use this configuration option to add custom reporters to Jest
102
- // reporters: undefined,
103
-
104
- // Automatically reset mock state between every test
105
- // resetMocks: false,
106
-
107
- // Reset the module registry before running each individual test
108
- // resetModules: false,
109
-
110
- // A path to a custom resolver
111
- // resolver: undefined,
112
-
113
- // Automatically restore mock state between every test
114
- // restoreMocks: false,
115
-
116
- // The root directory that Jest should scan for tests and modules within
117
- // rootDir: undefined,
118
-
119
- // A list of paths to directories that Jest should use to search for files in
120
- // roots: [
121
- // "<rootDir>"
122
- // ],
123
-
124
- // Allows you to use a custom runner instead of Jest's default test runner
125
- // runner: "jest-runner",
126
-
127
- // The paths to modules that run some code to configure or set up the testing environment before each test
128
- // setupFiles: [],
129
-
130
- // A list of paths to modules that run some code to configure or set up the testing framework before each test
131
- // setupFilesAfterEnv: [],
132
-
133
- // The number of seconds after which a test is considered as slow and reported as such in the results.
134
- // slowTestThreshold: 5,
135
-
136
- // A list of paths to snapshot serializer modules Jest should use for snapshot testing
137
- // snapshotSerializers: [],
138
-
139
- // The test environment that will be used for testing
140
- testEnvironment: "jest-environment-node",
141
-
142
- // Options that will be passed to the testEnvironment
143
- // testEnvironmentOptions: {},
144
-
145
- // Adds a location field to test results
146
- // testLocationInResults: false,
147
-
148
- // The glob patterns Jest uses to detect test files
149
- // testMatch: [
150
- // "**/__tests__/**/*.[jt]s?(x)",
151
- // "**/?(*.)+(spec|test).[tj]s?(x)"
152
- // ],
153
-
154
- // An array of regexp pattern strings that are matched against all test paths, matched tests are skipped
155
- // testPathIgnorePatterns: [
156
- // "\\\\node_modules\\\\"
157
- // ],
158
-
159
- // The regexp pattern or array of patterns that Jest uses to detect test files
160
- // testRegex: [],
161
-
162
- // This option allows the use of a custom results processor
163
- // testResultsProcessor: undefined,
164
-
165
- // This option allows use of a custom test runner
166
- // testRunner: "jest-circus/runner",
167
-
168
- // This option sets the URL for the jsdom environment. It is reflected in properties such as location.href
169
- // testURL: "http://localhost",
170
-
171
- // Setting this value to "fake" allows the use of fake timers for functions such as "setTimeout"
172
- // timers: "real",
173
-
174
- // A map from regular expressions to paths to transformers
175
- // transform: undefined,
176
- transform: {
177
- "^.+\\.tsx?$": ["ts-jest", {
178
- isolatedModules: true
179
- }]
180
- },
181
-
182
- // An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation
183
- // transformIgnorePatterns: [
184
- // "\\\\node_modules\\\\",
185
- // "\\.pnp\\.[^\\\\]+$"
186
- // ],
187
-
188
- // An array of regexp pattern strings that are matched against all modules before the module loader will automatically return a mock for them
189
- // unmockedModulePathPatterns: undefined,
190
-
191
- // Indicates whether each individual test should be reported during the run
192
- verbose: true,
193
-
194
- // An array of regexp patterns that are matched against all source file paths before re-running tests in watch mode
195
- // watchPathIgnorePatterns: [],
196
-
197
- // Whether to use watchman for file crawling
198
- // watchman: true,
199
- };
package/plantuml.jar DELETED
Binary file
package/src/famix2puml.ts DELETED
@@ -1,119 +0,0 @@
1
- import * as fs from 'fs';
2
- import yargs from 'yargs';
3
-
4
- const argv = yargs
5
- .example('ts-node src/famix2puml.ts -i JSONModels/projectName.json -o PUMLModels/projectName.puml', 'creates a PlantUML class diagram from a JSON-format model of a typescript project')
6
- .alias('i', 'input')
7
- .nargs('i', 1)
8
- .alias('o', 'output')
9
- .nargs('o', 1)
10
- .demandOption('input').demandOption('output').parseSync();
11
-
12
- const INHERITANCE_LINK_COLOR = 'blue';
13
-
14
- // approximation for code completion
15
- interface FamixTypeScriptElement {
16
- FM3: string
17
- name: string
18
- id?: string
19
- }
20
-
21
- interface Association {
22
- from: string;
23
- to: string;
24
- name: string;
25
- }
26
-
27
- const jsonFileName = argv.input as string;
28
- const pumlFileName = (argv.output as string).substring((argv.output as string).indexOf("/")+1, (argv.output as string).lastIndexOf('.'));
29
- const parsedModel: Array<FamixTypeScriptElement> = JSON.parse(fs.readFileSync(jsonFileName, 'utf-8'));
30
- const classNameMap = new Map<string, string>();
31
- const associations = new Array<Association>();
32
-
33
- // maps all class names to their id
34
- parsedModel.forEach(element => {
35
- // map has id as key and unique (plantuml) class name
36
- classNameMap.set(element.id, uniqueElementName(element));
37
- const nameWithoutPrefix = element.FM3.split('.')[1];
38
- // special case association
39
- if (nameWithoutPrefix.endsWith('Inheritance')) {
40
- const subclass = element['subclass'].ref;
41
- const superclass = element['superclass'].ref;
42
- associations.push({ from: subclass, to: superclass, name: nameWithoutPrefix });
43
- }
44
- });
45
-
46
- // generates plantuml
47
- let plantUMLOutString = `@startuml ${pumlFileName}
48
- skinparam style strictuml
49
- title Object diagram for ${jsonFileName}
50
- `;
51
- parsedModel.forEach(element => {
52
- plantUMLOutString += `${toPlantUML(element)}\n`;
53
- });
54
-
55
- // creates associations
56
- associations.forEach(association => {
57
- // inheritance is a special case, show it in UML even though it doesn't make 100% sense in object diagrams
58
- const isInheritance = association.name.startsWith('Inheritance');
59
- if (isInheritance) {
60
- plantUMLOutString += `${classNameMap.get(association.from)} --|> ${classNameMap.get(association.to)} #line:${INHERITANCE_LINK_COLOR}\n`;
61
- } else {
62
- plantUMLOutString += `${classNameMap.get(association.from)} ..> "${association.name}" ${classNameMap.get(association.to)}\n`;
63
- }
64
- });
65
-
66
- plantUMLOutString += '@enduml';
67
-
68
- // writes to output file
69
- fs.writeFile(argv.output as string, plantUMLOutString, (err) => {
70
- if (err) { throw err; }
71
- });
72
-
73
- function uniqueElementName(element: FamixTypeScriptElement): string {
74
- return `${element.FM3}${element.id}`;
75
- }
76
-
77
- function toPlantUML(element: FamixTypeScriptElement) {
78
- let plantUMLString = '';
79
- const optionalName = element.name || '';
80
- const nameWithoutPrefix = element.FM3.split('.')[1];
81
- plantUMLString += `object "${optionalName}:${nameWithoutPrefix}" as ${uniqueElementName(element)} {\n`;
82
- plantUMLString += `id = ${element.id}\n`;
83
- plantUMLString += propertiesToPlantUML(element);
84
- plantUMLString += '}\n';
85
- return plantUMLString;
86
- }
87
-
88
- function propertiesToPlantUML(element: FamixTypeScriptElement) {
89
- let plantUMLString = '';
90
- for (const property in element) {
91
- const attribute = element[property];
92
- const isOneToManyReference = typeof attribute !== 'string' && attribute.length; // array but not a string
93
-
94
- switch (property) {
95
- // ignores these properties
96
- case 'subclass':
97
- case 'superclass':
98
- case 'FM3':
99
- case 'id':
100
- case 'name':
101
- break;
102
-
103
- default:
104
- if (isOneToManyReference) {
105
- attribute.forEach((composite, index) => {
106
- associations.push({ from: element.id, to: composite.ref, name: `${property}[${index}]` });
107
- });
108
- } else if (typeof attribute === 'object') {
109
- associations.push({ from: element.id, to: attribute.ref, name: property });
110
- } else { // typeof string, boolean, number, etc
111
- // treats it as a simple attribute
112
- plantUMLString += `${property} = ${element[property]}\n`;
113
- }
114
-
115
- break;
116
- }
117
- }
118
- return plantUMLString;
119
- }