@proteinjs/reflection-build 1.2.1 → 1.4.0

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 (293) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/{test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/LICENSE → LICENSE} +5 -6
  3. package/dist/src/build.js +31 -15
  4. package/dist/src/build.js.map +1 -1
  5. package/dist/src/codegen/writeGeneratedIndex.d.ts +10 -1
  6. package/dist/src/codegen/writeGeneratedIndex.js +43 -12
  7. package/dist/src/codegen/writeGeneratedIndex.js.map +1 -1
  8. package/dist/src/parser/createSourceGraph.d.ts +1 -1
  9. package/dist/src/parser/createSourceGraph.js +36 -22
  10. package/dist/src/parser/createSourceGraph.js.map +1 -1
  11. package/dist/test/examples/source-repository/a/generated/index.js +1 -1
  12. package/dist/test/examples/source-repository/a/generated/index.js.map +1 -1
  13. package/dist/test/examples/source-repository/b/generated/index.js +1 -1
  14. package/dist/test/examples/source-repository/b/generated/index.js.map +1 -1
  15. package/package.json +4 -3
  16. package/src/build.ts +52 -14
  17. package/src/codegen/writeGeneratedIndex.ts +60 -7
  18. package/src/parser/createSourceGraph.ts +21 -12
  19. package/test/examples/source-repository/a/dist/build.js +31 -15
  20. package/test/examples/source-repository/a/dist/build.js.map +1 -1
  21. package/test/examples/source-repository/a/dist/codegen/writeGeneratedIndex.d.ts +10 -1
  22. package/test/examples/source-repository/a/dist/codegen/writeGeneratedIndex.js +43 -12
  23. package/test/examples/source-repository/a/dist/codegen/writeGeneratedIndex.js.map +1 -1
  24. package/test/examples/source-repository/a/dist/generated/index.js +1 -1
  25. package/test/examples/source-repository/a/dist/generated/index.js.map +1 -1
  26. package/test/examples/source-repository/a/dist/parser/createSourceGraph.d.ts +1 -1
  27. package/test/examples/source-repository/a/dist/parser/createSourceGraph.js +36 -22
  28. package/test/examples/source-repository/a/dist/parser/createSourceGraph.js.map +1 -1
  29. package/test/examples/source-repository/a/generated/index.ts +38 -33
  30. package/test/examples/source-repository/a/node_modules/.package-lock.json +0 -53
  31. package/test/examples/source-repository/a/package.json +1 -1
  32. package/test/examples/source-repository/b/dist/build.js +31 -15
  33. package/test/examples/source-repository/b/dist/build.js.map +1 -1
  34. package/test/examples/source-repository/b/dist/codegen/writeGeneratedIndex.d.ts +10 -1
  35. package/test/examples/source-repository/b/dist/codegen/writeGeneratedIndex.js +43 -12
  36. package/test/examples/source-repository/b/dist/codegen/writeGeneratedIndex.js.map +1 -1
  37. package/test/examples/source-repository/b/dist/generated/index.js +1 -1
  38. package/test/examples/source-repository/b/dist/generated/index.js.map +1 -1
  39. package/test/examples/source-repository/b/dist/parser/createSourceGraph.d.ts +1 -1
  40. package/test/examples/source-repository/b/dist/parser/createSourceGraph.js +36 -22
  41. package/test/examples/source-repository/b/dist/parser/createSourceGraph.js.map +1 -1
  42. package/test/examples/source-repository/b/generated/index.ts +10 -11
  43. package/test/examples/source-repository/b/node_modules/.package-lock.json +0 -53
  44. package/test/examples/source-repository/b/package.json +1 -1
  45. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/.eslintrc.js +0 -20
  46. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/.prettierignore +0 -4
  47. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/.prettierrc +0 -8
  48. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/CHANGELOG.md +0 -58
  49. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.d.ts +0 -5
  50. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.js +0 -18
  51. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.js.map +0 -1
  52. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.d.ts +0 -19
  53. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js +0 -555
  54. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js.map +0 -1
  55. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/Loadable.d.ts +0 -3
  56. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/Loadable.js +0 -5
  57. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/Loadable.js.map +0 -1
  58. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepository.d.ts +0 -45
  59. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js +0 -176
  60. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js.map +0 -1
  61. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.d.ts +0 -11
  62. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js +0 -9
  63. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js.map +0 -1
  64. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.d.ts +0 -13
  65. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js +0 -19
  66. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js.map +0 -1
  67. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/types.d.ts +0 -221
  68. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/types.js +0 -234
  69. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/types.js.map +0 -1
  70. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/index.ts +0 -5
  71. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/jest.config.js +0 -9
  72. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/package.json +0 -42
  73. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/FlattenedSourceGraph.ts +0 -702
  74. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/Loadable.ts +0 -2
  75. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/SourceRepository.ts +0 -250
  76. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/SourceRepositoryFilter.ts +0 -15
  77. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/sourceGraphTypes.ts +0 -14
  78. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/types.ts +0 -236
  79. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/tsconfig.json +0 -19
  80. package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/types/@dagrejs/graphlib.d.ts +0 -1
  81. package/test/examples/source-repository/a/node_modules/bindings/LICENSE.md +0 -22
  82. package/test/examples/source-repository/a/node_modules/bindings/README.md +0 -98
  83. package/test/examples/source-repository/a/node_modules/bindings/bindings.js +0 -221
  84. package/test/examples/source-repository/a/node_modules/bindings/package.json +0 -28
  85. package/test/examples/source-repository/a/node_modules/file-uri-to-path/.travis.yml +0 -30
  86. package/test/examples/source-repository/a/node_modules/file-uri-to-path/History.md +0 -21
  87. package/test/examples/source-repository/a/node_modules/file-uri-to-path/LICENSE +0 -20
  88. package/test/examples/source-repository/a/node_modules/file-uri-to-path/README.md +0 -74
  89. package/test/examples/source-repository/a/node_modules/file-uri-to-path/index.d.ts +0 -2
  90. package/test/examples/source-repository/a/node_modules/file-uri-to-path/index.js +0 -66
  91. package/test/examples/source-repository/a/node_modules/file-uri-to-path/package.json +0 -32
  92. package/test/examples/source-repository/a/node_modules/file-uri-to-path/test/test.js +0 -24
  93. package/test/examples/source-repository/a/node_modules/file-uri-to-path/test/tests.json +0 -13
  94. package/test/examples/source-repository/a/node_modules/fsevents/LICENSE +0 -22
  95. package/test/examples/source-repository/a/node_modules/fsevents/README.md +0 -89
  96. package/test/examples/source-repository/a/node_modules/fsevents/fsevents.d.ts +0 -46
  97. package/test/examples/source-repository/a/node_modules/fsevents/fsevents.js +0 -83
  98. package/test/examples/source-repository/a/node_modules/fsevents/fsevents.node +0 -0
  99. package/test/examples/source-repository/a/node_modules/fsevents/package.json +0 -62
  100. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/.travis.yml +0 -103
  101. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/ISSUE_TEMPLATE.md +0 -8
  102. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/Readme.md +0 -78
  103. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/binding.gyp +0 -21
  104. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/.target.mk +0 -53
  105. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Makefile +0 -352
  106. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/.node.d +0 -1
  107. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/obj.target/fse/fsevents.o.d.raw +0 -75
  108. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Release/.node +0 -0
  109. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/binding.Makefile +0 -6
  110. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/fse.target.mk +0 -188
  111. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/gyp-mac-tool +0 -772
  112. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/fsevents.cc +0 -88
  113. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/fsevents.js +0 -106
  114. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/install.js +0 -13
  115. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/package.json +0 -34
  116. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/async.cc +0 -43
  117. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/constants.cc +0 -110
  118. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/methods.cc +0 -44
  119. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/storage.cc +0 -27
  120. package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/thread.cc +0 -71
  121. package/test/examples/source-repository/a/node_modules/nan/CHANGELOG.md +0 -557
  122. package/test/examples/source-repository/a/node_modules/nan/CMakeLists.txt +0 -138
  123. package/test/examples/source-repository/a/node_modules/nan/LICENSE.md +0 -9
  124. package/test/examples/source-repository/a/node_modules/nan/README.md +0 -456
  125. package/test/examples/source-repository/a/node_modules/nan/doc/asyncworker.md +0 -146
  126. package/test/examples/source-repository/a/node_modules/nan/doc/buffers.md +0 -54
  127. package/test/examples/source-repository/a/node_modules/nan/doc/callback.md +0 -76
  128. package/test/examples/source-repository/a/node_modules/nan/doc/converters.md +0 -41
  129. package/test/examples/source-repository/a/node_modules/nan/doc/errors.md +0 -226
  130. package/test/examples/source-repository/a/node_modules/nan/doc/json.md +0 -62
  131. package/test/examples/source-repository/a/node_modules/nan/doc/maybe_types.md +0 -583
  132. package/test/examples/source-repository/a/node_modules/nan/doc/methods.md +0 -672
  133. package/test/examples/source-repository/a/node_modules/nan/doc/new.md +0 -147
  134. package/test/examples/source-repository/a/node_modules/nan/doc/node_misc.md +0 -123
  135. package/test/examples/source-repository/a/node_modules/nan/doc/object_wrappers.md +0 -263
  136. package/test/examples/source-repository/a/node_modules/nan/doc/persistent.md +0 -296
  137. package/test/examples/source-repository/a/node_modules/nan/doc/scopes.md +0 -73
  138. package/test/examples/source-repository/a/node_modules/nan/doc/script.md +0 -58
  139. package/test/examples/source-repository/a/node_modules/nan/doc/string_bytes.md +0 -62
  140. package/test/examples/source-repository/a/node_modules/nan/doc/v8_internals.md +0 -199
  141. package/test/examples/source-repository/a/node_modules/nan/doc/v8_misc.md +0 -85
  142. package/test/examples/source-repository/a/node_modules/nan/include_dirs.js +0 -1
  143. package/test/examples/source-repository/a/node_modules/nan/nan.h +0 -2958
  144. package/test/examples/source-repository/a/node_modules/nan/nan_callbacks.h +0 -92
  145. package/test/examples/source-repository/a/node_modules/nan/nan_callbacks_12_inl.h +0 -520
  146. package/test/examples/source-repository/a/node_modules/nan/nan_callbacks_pre_12_inl.h +0 -520
  147. package/test/examples/source-repository/a/node_modules/nan/nan_converters.h +0 -72
  148. package/test/examples/source-repository/a/node_modules/nan/nan_converters_43_inl.h +0 -68
  149. package/test/examples/source-repository/a/node_modules/nan/nan_converters_pre_43_inl.h +0 -42
  150. package/test/examples/source-repository/a/node_modules/nan/nan_define_own_property_helper.h +0 -29
  151. package/test/examples/source-repository/a/node_modules/nan/nan_implementation_12_inl.h +0 -430
  152. package/test/examples/source-repository/a/node_modules/nan/nan_implementation_pre_12_inl.h +0 -263
  153. package/test/examples/source-repository/a/node_modules/nan/nan_json.h +0 -166
  154. package/test/examples/source-repository/a/node_modules/nan/nan_maybe_43_inl.h +0 -356
  155. package/test/examples/source-repository/a/node_modules/nan/nan_maybe_pre_43_inl.h +0 -268
  156. package/test/examples/source-repository/a/node_modules/nan/nan_new.h +0 -340
  157. package/test/examples/source-repository/a/node_modules/nan/nan_object_wrap.h +0 -156
  158. package/test/examples/source-repository/a/node_modules/nan/nan_persistent_12_inl.h +0 -132
  159. package/test/examples/source-repository/a/node_modules/nan/nan_persistent_pre_12_inl.h +0 -242
  160. package/test/examples/source-repository/a/node_modules/nan/nan_private.h +0 -73
  161. package/test/examples/source-repository/a/node_modules/nan/nan_scriptorigin.h +0 -76
  162. package/test/examples/source-repository/a/node_modules/nan/nan_string_bytes.h +0 -305
  163. package/test/examples/source-repository/a/node_modules/nan/nan_typedarray_contents.h +0 -96
  164. package/test/examples/source-repository/a/node_modules/nan/nan_weak.h +0 -437
  165. package/test/examples/source-repository/a/node_modules/nan/package.json +0 -38
  166. package/test/examples/source-repository/a/node_modules/nan/tools/1to2.js +0 -412
  167. package/test/examples/source-repository/a/node_modules/nan/tools/README.md +0 -14
  168. package/test/examples/source-repository/a/node_modules/nan/tools/package.json +0 -19
  169. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/.eslintrc.js +0 -20
  170. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/.prettierignore +0 -4
  171. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/.prettierrc +0 -8
  172. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/CHANGELOG.md +0 -58
  173. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/index.d.ts +0 -5
  174. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/index.js +0 -18
  175. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/index.js.map +0 -1
  176. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.d.ts +0 -19
  177. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js +0 -555
  178. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js.map +0 -1
  179. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/Loadable.d.ts +0 -3
  180. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/Loadable.js +0 -5
  181. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/Loadable.js.map +0 -1
  182. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepository.d.ts +0 -45
  183. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js +0 -176
  184. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js.map +0 -1
  185. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.d.ts +0 -11
  186. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js +0 -9
  187. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js.map +0 -1
  188. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.d.ts +0 -13
  189. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js +0 -19
  190. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js.map +0 -1
  191. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/types.d.ts +0 -221
  192. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/types.js +0 -234
  193. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/types.js.map +0 -1
  194. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/index.ts +0 -5
  195. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/jest.config.js +0 -9
  196. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/package.json +0 -42
  197. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/FlattenedSourceGraph.ts +0 -702
  198. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/Loadable.ts +0 -2
  199. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/SourceRepository.ts +0 -250
  200. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/SourceRepositoryFilter.ts +0 -15
  201. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/sourceGraphTypes.ts +0 -14
  202. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/types.ts +0 -236
  203. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/tsconfig.json +0 -19
  204. package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/types/@dagrejs/graphlib.d.ts +0 -1
  205. package/test/examples/source-repository/b/node_modules/bindings/LICENSE.md +0 -22
  206. package/test/examples/source-repository/b/node_modules/bindings/README.md +0 -98
  207. package/test/examples/source-repository/b/node_modules/bindings/bindings.js +0 -221
  208. package/test/examples/source-repository/b/node_modules/bindings/package.json +0 -28
  209. package/test/examples/source-repository/b/node_modules/file-uri-to-path/.travis.yml +0 -30
  210. package/test/examples/source-repository/b/node_modules/file-uri-to-path/History.md +0 -21
  211. package/test/examples/source-repository/b/node_modules/file-uri-to-path/LICENSE +0 -20
  212. package/test/examples/source-repository/b/node_modules/file-uri-to-path/README.md +0 -74
  213. package/test/examples/source-repository/b/node_modules/file-uri-to-path/index.d.ts +0 -2
  214. package/test/examples/source-repository/b/node_modules/file-uri-to-path/index.js +0 -66
  215. package/test/examples/source-repository/b/node_modules/file-uri-to-path/package.json +0 -32
  216. package/test/examples/source-repository/b/node_modules/file-uri-to-path/test/test.js +0 -24
  217. package/test/examples/source-repository/b/node_modules/file-uri-to-path/test/tests.json +0 -13
  218. package/test/examples/source-repository/b/node_modules/fsevents/LICENSE +0 -22
  219. package/test/examples/source-repository/b/node_modules/fsevents/README.md +0 -89
  220. package/test/examples/source-repository/b/node_modules/fsevents/fsevents.d.ts +0 -46
  221. package/test/examples/source-repository/b/node_modules/fsevents/fsevents.js +0 -83
  222. package/test/examples/source-repository/b/node_modules/fsevents/fsevents.node +0 -0
  223. package/test/examples/source-repository/b/node_modules/fsevents/package.json +0 -62
  224. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/.travis.yml +0 -103
  225. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/ISSUE_TEMPLATE.md +0 -8
  226. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/LICENSE +0 -22
  227. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/Readme.md +0 -78
  228. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/binding.gyp +0 -21
  229. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/.target.mk +0 -53
  230. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Makefile +0 -352
  231. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/.node.d +0 -1
  232. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/obj.target/fse/fsevents.o.d.raw +0 -75
  233. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Release/.node +0 -0
  234. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/binding.Makefile +0 -6
  235. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/fse.target.mk +0 -188
  236. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/gyp-mac-tool +0 -772
  237. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/fsevents.cc +0 -88
  238. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/fsevents.js +0 -106
  239. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/install.js +0 -13
  240. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/package.json +0 -34
  241. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/async.cc +0 -43
  242. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/constants.cc +0 -110
  243. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/methods.cc +0 -44
  244. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/storage.cc +0 -27
  245. package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/thread.cc +0 -71
  246. package/test/examples/source-repository/b/node_modules/nan/CHANGELOG.md +0 -557
  247. package/test/examples/source-repository/b/node_modules/nan/CMakeLists.txt +0 -138
  248. package/test/examples/source-repository/b/node_modules/nan/LICENSE.md +0 -9
  249. package/test/examples/source-repository/b/node_modules/nan/README.md +0 -456
  250. package/test/examples/source-repository/b/node_modules/nan/doc/asyncworker.md +0 -146
  251. package/test/examples/source-repository/b/node_modules/nan/doc/buffers.md +0 -54
  252. package/test/examples/source-repository/b/node_modules/nan/doc/callback.md +0 -76
  253. package/test/examples/source-repository/b/node_modules/nan/doc/converters.md +0 -41
  254. package/test/examples/source-repository/b/node_modules/nan/doc/errors.md +0 -226
  255. package/test/examples/source-repository/b/node_modules/nan/doc/json.md +0 -62
  256. package/test/examples/source-repository/b/node_modules/nan/doc/maybe_types.md +0 -583
  257. package/test/examples/source-repository/b/node_modules/nan/doc/methods.md +0 -672
  258. package/test/examples/source-repository/b/node_modules/nan/doc/new.md +0 -147
  259. package/test/examples/source-repository/b/node_modules/nan/doc/node_misc.md +0 -123
  260. package/test/examples/source-repository/b/node_modules/nan/doc/object_wrappers.md +0 -263
  261. package/test/examples/source-repository/b/node_modules/nan/doc/persistent.md +0 -296
  262. package/test/examples/source-repository/b/node_modules/nan/doc/scopes.md +0 -73
  263. package/test/examples/source-repository/b/node_modules/nan/doc/script.md +0 -58
  264. package/test/examples/source-repository/b/node_modules/nan/doc/string_bytes.md +0 -62
  265. package/test/examples/source-repository/b/node_modules/nan/doc/v8_internals.md +0 -199
  266. package/test/examples/source-repository/b/node_modules/nan/doc/v8_misc.md +0 -85
  267. package/test/examples/source-repository/b/node_modules/nan/include_dirs.js +0 -1
  268. package/test/examples/source-repository/b/node_modules/nan/nan.h +0 -2958
  269. package/test/examples/source-repository/b/node_modules/nan/nan_callbacks.h +0 -92
  270. package/test/examples/source-repository/b/node_modules/nan/nan_callbacks_12_inl.h +0 -520
  271. package/test/examples/source-repository/b/node_modules/nan/nan_callbacks_pre_12_inl.h +0 -520
  272. package/test/examples/source-repository/b/node_modules/nan/nan_converters.h +0 -72
  273. package/test/examples/source-repository/b/node_modules/nan/nan_converters_43_inl.h +0 -68
  274. package/test/examples/source-repository/b/node_modules/nan/nan_converters_pre_43_inl.h +0 -42
  275. package/test/examples/source-repository/b/node_modules/nan/nan_define_own_property_helper.h +0 -29
  276. package/test/examples/source-repository/b/node_modules/nan/nan_implementation_12_inl.h +0 -430
  277. package/test/examples/source-repository/b/node_modules/nan/nan_implementation_pre_12_inl.h +0 -263
  278. package/test/examples/source-repository/b/node_modules/nan/nan_json.h +0 -166
  279. package/test/examples/source-repository/b/node_modules/nan/nan_maybe_43_inl.h +0 -356
  280. package/test/examples/source-repository/b/node_modules/nan/nan_maybe_pre_43_inl.h +0 -268
  281. package/test/examples/source-repository/b/node_modules/nan/nan_new.h +0 -340
  282. package/test/examples/source-repository/b/node_modules/nan/nan_object_wrap.h +0 -156
  283. package/test/examples/source-repository/b/node_modules/nan/nan_persistent_12_inl.h +0 -132
  284. package/test/examples/source-repository/b/node_modules/nan/nan_persistent_pre_12_inl.h +0 -242
  285. package/test/examples/source-repository/b/node_modules/nan/nan_private.h +0 -73
  286. package/test/examples/source-repository/b/node_modules/nan/nan_scriptorigin.h +0 -76
  287. package/test/examples/source-repository/b/node_modules/nan/nan_string_bytes.h +0 -305
  288. package/test/examples/source-repository/b/node_modules/nan/nan_typedarray_contents.h +0 -96
  289. package/test/examples/source-repository/b/node_modules/nan/nan_weak.h +0 -437
  290. package/test/examples/source-repository/b/node_modules/nan/package.json +0 -38
  291. package/test/examples/source-repository/b/node_modules/nan/tools/1to2.js +0 -412
  292. package/test/examples/source-repository/b/node_modules/nan/tools/README.md +0 -14
  293. package/test/examples/source-repository/b/node_modules/nan/tools/package.json +0 -19
@@ -1,8 +0,0 @@
1
- {
2
- "trailingComma": "es5",
3
- "tabWidth": 2,
4
- "semi": true,
5
- "singleQuote": true,
6
- "jsxSingleQuote": true,
7
- "printWidth": 120
8
- }
@@ -1,58 +0,0 @@
1
- # Change Log
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- ## [1.1.3](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.1.2...@proteinjs/reflection@1.1.3) (2024-05-10)
7
-
8
-
9
- ### Bug Fixes
10
-
11
- * add .md file type to lint ignore files ([d7bdf6b](https://github.com/proteinjs/reflection/commit/d7bdf6baa50f93781e71abac3c2732e87cb21999))
12
-
13
-
14
-
15
-
16
-
17
- ## [1.1.2](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.1.1...@proteinjs/reflection@1.1.2) (2024-05-10)
18
-
19
-
20
- ### Bug Fixes
21
-
22
- * add linter and lint files ([5d39eef](https://github.com/proteinjs/reflection/commit/5d39eef78a5a1d8ab24b188d23ff9220b595e885))
23
-
24
-
25
-
26
-
27
-
28
- ## [1.1.1](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.1.0...@proteinjs/reflection@1.1.1) (2024-05-08)
29
-
30
- ### Bug Fixes
31
-
32
- - `SourceRepository.filterObjects` should omit objects for which any filter returns `false`, not `true`; this is inline with general filter semantics ([5f2f4c1](https://github.com/proteinjs/reflection/commit/5f2f4c133f47e447d08bc061f2b7177a767e977b))
33
-
34
- # [1.1.0](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.0.7...@proteinjs/reflection@1.1.0) (2024-05-08)
35
-
36
- ### Features
37
-
38
- - added `SourceRepositoryTypeFilter` to optionally filter out `Loadable`s from dependencies ([6cc0cda](https://github.com/proteinjs/reflection/commit/6cc0cdada9bb5e0d8fe8281582722bfb8aa7de64))
39
-
40
- ## [1.0.6](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.0.5...@proteinjs/reflection@1.0.6) (2024-04-23)
41
-
42
- ### Bug Fixes
43
-
44
- - continue to fix to work for a runtime with multiple [dependency] copies of reflection ([6fea790](https://github.com/proteinjs/reflection/commit/6fea79006a60bd2719272cd061e373d3cdba1c49))
45
-
46
- ## [1.0.3](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.0.2...@proteinjs/reflection@1.0.3) (2024-04-21)
47
-
48
- ### Bug Fixes
49
-
50
- - `SourceRepository` to store singleton in global memory so its truly a singleton even if multiple copies of @proteinjs/reflection exist at runtime ([36b5d09](https://github.com/proteinjs/reflection/commit/36b5d09139d337550f68f694d10b94cfd3c8b317))
51
-
52
- ## [1.0.2](https://github.com/proteinjs/reflection/compare/@proteinjs/reflection@1.0.1...@proteinjs/reflection@1.0.2) (2024-04-12)
53
-
54
- **Note:** Version bump only for package @proteinjs/reflection
55
-
56
- ## 1.0.1 (2024-04-12)
57
-
58
- **Note:** Version bump only for package @proteinjs/reflection
@@ -1,5 +0,0 @@
1
- export * from './src/Loadable';
2
- export * from './src/types';
3
- export * from './src/sourceGraphTypes';
4
- export * from './src/SourceRepository';
5
- export * from './src/SourceRepositoryFilter';
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
- }) : (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- o[k2] = m[k];
8
- }));
9
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
- for (var p in m) if (p !== "default" && !exports.hasOwnProperty(p)) __createBinding(exports, m, p);
11
- };
12
- Object.defineProperty(exports, "__esModule", { value: true });
13
- __exportStar(require("./src/Loadable"), exports);
14
- __exportStar(require("./src/types"), exports);
15
- __exportStar(require("./src/sourceGraphTypes"), exports);
16
- __exportStar(require("./src/SourceRepository"), exports);
17
- __exportStar(require("./src/SourceRepositoryFilter"), exports);
18
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,iDAA+B;AAC/B,8CAA4B;AAC5B,yDAAuC;AACvC,yDAAuC;AACvC,+DAA6C"}
@@ -1,19 +0,0 @@
1
- import { Graph } from '@dagrejs/graphlib';
2
- import { Variable, TypeAlias, Class, Interface } from './types';
3
- export declare type FlattenedSourceGraph = {
4
- variables: {
5
- [qualifiedName: string]: Variable;
6
- };
7
- typeAliases: {
8
- [qualifiedName: string]: TypeAlias;
9
- };
10
- classes: {
11
- [qualifiedName: string]: Class;
12
- };
13
- interfaces: {
14
- [qualifiedName: string]: Interface;
15
- };
16
- };
17
- export declare function flattenSourceGraph(sourceGraph: Graph, sourceLinks: {
18
- [qualifiedName: string]: any;
19
- }): FlattenedSourceGraph;
@@ -1,555 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.flattenSourceGraph = void 0;
4
- var graphlib_1 = require("@dagrejs/graphlib");
5
- var types_1 = require("./types");
6
- var util_1 = require("@proteinjs/util");
7
- var Loadable_1 = require("./Loadable");
8
- var SourceRepositoryFilter_1 = require("./SourceRepositoryFilter");
9
- var sourceGraphTypes_1 = require("./sourceGraphTypes");
10
- function flattenSourceGraph(sourceGraph, sourceLinks) {
11
- var flattenedSourceGraph = {
12
- variables: {},
13
- typeAliases: {},
14
- classes: {},
15
- interfaces: {},
16
- };
17
- var loadableInterfaceDeclaration = new types_1.InterfaceDeclaration('@proteinjs/reflection', 'Loadable', [], [], [], []);
18
- sourceGraph.setNode(Loadable_1.LOADABLE_QUALIFIED_NAME, loadableInterfaceDeclaration);
19
- if (!sourceGraph.hasNode(SourceRepositoryFilter_1.SOURCE_REPOSITORY_FILTER_QUALIFIED_NAME)) {
20
- sourceGraph.setNode(SourceRepositoryFilter_1.SOURCE_REPOSITORY_FILTER_QUALIFIED_NAME, new types_1.InterfaceDeclaration('@proteinjs/reflection', 'SourceRepositoryFilter', [], [], [], [loadableInterfaceDeclaration]));
21
- sourceGraph.setEdge(SourceRepositoryFilter_1.SOURCE_REPOSITORY_FILTER_QUALIFIED_NAME, Loadable_1.LOADABLE_QUALIFIED_NAME, sourceGraphTypes_1.SourceRelationship.extendsInterface);
22
- }
23
- flattenParents(sourceGraph, sourceLinks, flattenedSourceGraph);
24
- flattenChildren(sourceGraph, sourceLinks, flattenedSourceGraph);
25
- addTypeParameters(flattenedSourceGraph, sourceGraph);
26
- pruneNonLoadables(flattenedSourceGraph);
27
- return flattenedSourceGraph;
28
- }
29
- exports.flattenSourceGraph = flattenSourceGraph;
30
- function flattenParents(sourceGraph, sourceLinks, flattenedSourceGraph) {
31
- for (var _i = 0, _a = graphlib_1.alg.topsort(sourceGraph).reverse(); _i < _a.length; _i++) {
32
- var nodeName = _a[_i];
33
- var node = sourceGraph.node(nodeName);
34
- if (!node) {
35
- continue;
36
- }
37
- if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
38
- loadInterfaceAndParents(node, sourceGraph, sourceLinks, flattenedSourceGraph);
39
- }
40
- else if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
41
- loadTypeAliasAndParents(node, sourceGraph, sourceLinks, flattenedSourceGraph);
42
- }
43
- else if (util_1.isInstanceOf(node, types_1.ClassDeclaration)) {
44
- loadClassAndParents(node, sourceGraph, sourceLinks, flattenedSourceGraph);
45
- }
46
- else if (util_1.isInstanceOf(node, types_1.VariableDeclaration)) {
47
- loadVariableAndParents(node, sourceGraph, sourceLinks, flattenedSourceGraph);
48
- }
49
- }
50
- }
51
- function flattenChildren(sourceGraph, sourceLinks, flattenedSourceGraph) {
52
- for (var _i = 0, _a = graphlib_1.alg.topsort(sourceGraph); _i < _a.length; _i++) {
53
- var nodeName = _a[_i];
54
- var node = sourceGraph.node(nodeName);
55
- if (!node) {
56
- continue;
57
- }
58
- if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
59
- loadTypeAliasAndChildren(node, sourceGraph, flattenedSourceGraph);
60
- }
61
- else if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
62
- loadInterfaceAndChildren(node, sourceGraph, flattenedSourceGraph);
63
- }
64
- else if (util_1.isInstanceOf(node, types_1.ClassDeclaration)) {
65
- loadClassAndChildren(node, sourceGraph, sourceLinks, flattenedSourceGraph);
66
- }
67
- else if (util_1.isInstanceOf(node, types_1.VariableDeclaration)) {
68
- getOrCreateVariable(node, sourceLinks, flattenedSourceGraph);
69
- }
70
- }
71
- }
72
- function isRootParent(type) {
73
- if (Object.keys(type.directParents).length === 0 && type.directParents.constructor === Object) {
74
- return true;
75
- }
76
- if (type.directParents[Loadable_1.LOADABLE_QUALIFIED_NAME]) {
77
- return true;
78
- }
79
- return false;
80
- }
81
- function loadTypeAliasAndParents(typeAliasDeclaration, sourceGraph, sourceLinks, flattenedSourceGraph) {
82
- if (!flattenedSourceGraph.typeAliases[typeAliasDeclaration.qualifiedName]) {
83
- flattenedSourceGraph.typeAliases[typeAliasDeclaration.qualifiedName] = new types_1.TypeAlias(typeAliasDeclaration.packageName, typeAliasDeclaration.name, typeAliasDeclaration.filePath);
84
- }
85
- var typeAlias = flattenedSourceGraph.typeAliases[typeAliasDeclaration.qualifiedName];
86
- var outEdges = sourceGraph.outEdges(typeAliasDeclaration.qualifiedName);
87
- if (outEdges) {
88
- for (var _i = 0, outEdges_1 = outEdges; _i < outEdges_1.length; _i++) {
89
- var outEdge = outEdges_1[_i];
90
- var node = sourceGraph.node(outEdge.w);
91
- if (!node) {
92
- continue;
93
- }
94
- if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
95
- var parentTypeAlias = flattenedSourceGraph.typeAliases[outEdge.w];
96
- if (!parentTypeAlias) {
97
- continue;
98
- }
99
- typeAlias.directParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
100
- typeAlias.allParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
101
- typeAlias.allParents = Object.assign(typeAlias.allParents, parentTypeAlias.allParents);
102
- if (isRootParent(parentTypeAlias)) {
103
- typeAlias.rootParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
104
- }
105
- else {
106
- typeAlias.rootParents = Object.assign(typeAlias.rootParents, parentTypeAlias.rootParents);
107
- }
108
- }
109
- else if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
110
- var parentInterface = flattenedSourceGraph.interfaces[outEdge.w];
111
- if (!parentInterface) {
112
- continue;
113
- }
114
- typeAlias.directParents[parentInterface.qualifiedName] = parentInterface;
115
- typeAlias.allParents[parentInterface.qualifiedName] = parentInterface;
116
- typeAlias.allParents = Object.assign(typeAlias.allParents, parentInterface.allParents);
117
- if (isRootParent(parentInterface)) {
118
- typeAlias.rootParents[parentInterface.qualifiedName] = parentInterface;
119
- }
120
- else {
121
- typeAlias.rootParents = Object.assign(typeAlias.rootParents, parentInterface.rootParents);
122
- }
123
- }
124
- }
125
- }
126
- }
127
- function loadInterfaceAndParents(interfaceDeclaration, sourceGraph, sourceLinks, flattenedSourceGraph) {
128
- if (!flattenedSourceGraph.interfaces[interfaceDeclaration.qualifiedName]) {
129
- flattenedSourceGraph.interfaces[interfaceDeclaration.qualifiedName] = new types_1.Interface(interfaceDeclaration.packageName, interfaceDeclaration.name, interfaceDeclaration.properties, interfaceDeclaration.methods, interfaceDeclaration.filePath);
130
- }
131
- var _interface = flattenedSourceGraph.interfaces[interfaceDeclaration.qualifiedName];
132
- var outEdges = sourceGraph.outEdges(interfaceDeclaration.qualifiedName);
133
- if (outEdges) {
134
- for (var _i = 0, outEdges_2 = outEdges; _i < outEdges_2.length; _i++) {
135
- var outEdge = outEdges_2[_i];
136
- var node = sourceGraph.node(outEdge.w);
137
- if (!node) {
138
- continue;
139
- }
140
- if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
141
- var parentInterface = flattenedSourceGraph.interfaces[outEdge.w];
142
- if (!parentInterface) {
143
- continue;
144
- }
145
- _interface.directParents[parentInterface.qualifiedName] = parentInterface;
146
- _interface.allParents[parentInterface.qualifiedName] = parentInterface;
147
- _interface.allParents = Object.assign(_interface.allParents, parentInterface.allParents);
148
- if (isRootParent(parentInterface)) {
149
- _interface.rootParents[parentInterface.qualifiedName] = parentInterface;
150
- }
151
- else {
152
- _interface.rootParents = Object.assign(_interface.rootParents, parentInterface.rootParents);
153
- }
154
- }
155
- else if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
156
- var parentTypeAlias = flattenedSourceGraph.typeAliases[outEdge.w];
157
- if (!parentTypeAlias) {
158
- continue;
159
- }
160
- _interface.directParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
161
- _interface.allParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
162
- _interface.allParents = Object.assign(_interface.allParents, parentTypeAlias.allParents);
163
- if (isRootParent(parentTypeAlias)) {
164
- _interface.rootParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
165
- }
166
- else {
167
- _interface.rootParents = Object.assign(_interface.rootParents, parentTypeAlias.rootParents);
168
- }
169
- }
170
- }
171
- }
172
- }
173
- function loadClassAndParents(classDeclaration, sourceGraph, sourceLinks, flattenedSourceGraph) {
174
- if (!flattenedSourceGraph.classes[classDeclaration.qualifiedName]) {
175
- flattenedSourceGraph.classes[classDeclaration.qualifiedName] = new types_1.Class(classDeclaration.packageName, classDeclaration.name, classDeclaration.filePath, classDeclaration.isAbstract, classDeclaration.isStatic, classDeclaration.visibility, classDeclaration.properties, classDeclaration.methods, sourceLinks[classDeclaration.qualifiedName]);
176
- }
177
- var _class = flattenedSourceGraph.classes[classDeclaration.qualifiedName];
178
- var outEdges = sourceGraph.outEdges(classDeclaration.qualifiedName);
179
- if (outEdges) {
180
- for (var _i = 0, outEdges_3 = outEdges; _i < outEdges_3.length; _i++) {
181
- var outEdge = outEdges_3[_i];
182
- var node = sourceGraph.node(outEdge.w);
183
- if (!node) {
184
- continue;
185
- }
186
- if (util_1.isInstanceOf(node, types_1.ClassDeclaration)) {
187
- var parentClass = flattenedSourceGraph.classes[outEdge.w];
188
- if (!parentClass) {
189
- continue;
190
- }
191
- _class.directParents[parentClass.qualifiedName] = parentClass;
192
- _class.allParents[parentClass.qualifiedName] = parentClass;
193
- _class.allParents = Object.assign(_class.allParents, parentClass.allParents);
194
- if (isRootParent(parentClass)) {
195
- _class.rootParents[parentClass.qualifiedName] = parentClass;
196
- }
197
- else {
198
- _class.rootParents = Object.assign(_class.rootParents, parentClass.rootParents);
199
- }
200
- }
201
- else if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
202
- var parentInterface = flattenedSourceGraph.interfaces[outEdge.w];
203
- if (!parentInterface) {
204
- continue;
205
- }
206
- _class.directParents[parentInterface.qualifiedName] = parentInterface;
207
- _class.allParents[parentInterface.qualifiedName] = parentInterface;
208
- _class.allParents = Object.assign(_class.allParents, parentInterface.allParents);
209
- if (isRootParent(parentInterface)) {
210
- _class.rootParents[parentInterface.qualifiedName] = parentInterface;
211
- }
212
- else {
213
- _class.rootParents = Object.assign(_class.rootParents, parentInterface.rootParents);
214
- }
215
- }
216
- else if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
217
- var parentTypeAlias = flattenedSourceGraph.typeAliases[outEdge.w];
218
- if (!parentTypeAlias) {
219
- continue;
220
- }
221
- _class.directParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
222
- _class.allParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
223
- _class.allParents = Object.assign(_class.allParents, parentTypeAlias.allParents);
224
- if (isRootParent(parentTypeAlias)) {
225
- _class.rootParents[parentTypeAlias.qualifiedName] = parentTypeAlias;
226
- }
227
- else {
228
- _class.rootParents = Object.assign(_class.rootParents, parentTypeAlias.rootParents);
229
- }
230
- }
231
- }
232
- }
233
- }
234
- function loadVariableAndParents(variableDeclaration, sourceGraph, sourceLinks, flattenedSourceGraph) {
235
- var variable = getOrCreateVariable(variableDeclaration, sourceLinks, flattenedSourceGraph);
236
- var outEdges = sourceGraph.outEdges(variableDeclaration.qualifiedName);
237
- if (outEdges) {
238
- for (var _i = 0, outEdges_4 = outEdges; _i < outEdges_4.length; _i++) {
239
- var outEdge = outEdges_4[_i];
240
- var node = sourceGraph.node(outEdge.w);
241
- if (!node) {
242
- continue;
243
- }
244
- if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
245
- var parentTypeAlias = flattenedSourceGraph.typeAliases[outEdge.w];
246
- if (!parentTypeAlias) {
247
- continue;
248
- }
249
- variable.directParentTypes[parentTypeAlias.qualifiedName] = parentTypeAlias;
250
- variable.allParentTypes[parentTypeAlias.qualifiedName] = parentTypeAlias;
251
- variable.allParentTypes = Object.assign(variable.allParentTypes, parentTypeAlias.allParents);
252
- if (isRootParent(parentTypeAlias)) {
253
- variable.rootParentTypes[parentTypeAlias.qualifiedName] = parentTypeAlias;
254
- }
255
- else {
256
- variable.rootParentTypes = Object.assign(variable.rootParentTypes, parentTypeAlias.rootParents);
257
- }
258
- }
259
- else if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
260
- var parentInterface = flattenedSourceGraph.interfaces[outEdge.w];
261
- if (!parentInterface) {
262
- continue;
263
- }
264
- variable.directParentTypes[parentInterface.qualifiedName] = parentInterface;
265
- variable.allParentTypes[parentInterface.qualifiedName] = parentInterface;
266
- variable.allParentTypes = Object.assign(variable.allParentTypes, parentInterface.allParents);
267
- if (isRootParent(parentInterface)) {
268
- variable.rootParentTypes[parentInterface.qualifiedName] = parentInterface;
269
- }
270
- else {
271
- variable.rootParentTypes = Object.assign(variable.rootParentTypes, parentInterface.rootParents);
272
- }
273
- }
274
- }
275
- }
276
- }
277
- function getOrCreateVariable(variableDeclaration, sourceLinks, flattenedSourceGraph) {
278
- if (flattenedSourceGraph.variables[variableDeclaration.qualifiedName]) {
279
- return flattenedSourceGraph.variables[variableDeclaration.qualifiedName];
280
- }
281
- var variable = new types_1.Variable(variableDeclaration.packageName, variableDeclaration.name, variableDeclaration.filePath, variableDeclaration.isExported, variableDeclaration.isConst, sourceLinks[variableDeclaration.qualifiedName]);
282
- flattenedSourceGraph.variables[variableDeclaration.qualifiedName] = variable;
283
- return variable;
284
- }
285
- function loadTypeAliasAndChildren(typeAliasDeclaration, sourceGraph, flattenedSourceGraph) {
286
- if (!flattenedSourceGraph.typeAliases[typeAliasDeclaration.qualifiedName]) {
287
- flattenedSourceGraph.typeAliases[typeAliasDeclaration.qualifiedName] = new types_1.TypeAlias(typeAliasDeclaration.packageName, typeAliasDeclaration.name, typeAliasDeclaration.filePath);
288
- }
289
- var typeAlias = flattenedSourceGraph.typeAliases[typeAliasDeclaration.qualifiedName];
290
- var inEdges = sourceGraph.inEdges(typeAliasDeclaration.qualifiedName);
291
- if (inEdges) {
292
- for (var _i = 0, inEdges_1 = inEdges; _i < inEdges_1.length; _i++) {
293
- var inEdge = inEdges_1[_i];
294
- var node = sourceGraph.node(inEdge.v);
295
- if (!node) {
296
- continue;
297
- }
298
- if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
299
- var childTypeAlias = flattenedSourceGraph.typeAliases[node.qualifiedName];
300
- if (!childTypeAlias) {
301
- continue;
302
- }
303
- typeAlias.directChildren[childTypeAlias.qualifiedName] = childTypeAlias;
304
- typeAlias.allChildren[childTypeAlias.qualifiedName] = childTypeAlias;
305
- typeAlias.allChildren = Object.assign(typeAlias.allChildren, childTypeAlias.allChildren);
306
- if (Object.keys(childTypeAlias.directChildren).length === 0 &&
307
- childTypeAlias.directChildren.constructor === Object) {
308
- typeAlias.baseChildren[childTypeAlias.qualifiedName] = childTypeAlias;
309
- }
310
- else {
311
- typeAlias.baseChildren = Object.assign(typeAlias.baseChildren, childTypeAlias.baseChildren);
312
- }
313
- }
314
- else if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
315
- var childInterface = flattenedSourceGraph.interfaces[node.qualifiedName];
316
- if (!childInterface) {
317
- continue;
318
- }
319
- typeAlias.directChildren[childInterface.qualifiedName] = childInterface;
320
- typeAlias.allChildren[childInterface.qualifiedName] = childInterface;
321
- typeAlias.allChildren = Object.assign(typeAlias.allChildren, childInterface.allChildren);
322
- if (Object.keys(childInterface.directChildren).length === 0 &&
323
- childInterface.directChildren.constructor === Object) {
324
- typeAlias.baseChildren[childInterface.qualifiedName] = childInterface;
325
- }
326
- else {
327
- typeAlias.baseChildren = Object.assign(typeAlias.baseChildren, childInterface.baseChildren);
328
- }
329
- }
330
- else if (util_1.isInstanceOf(node, types_1.VariableDeclaration)) {
331
- var childVariable = flattenedSourceGraph.variables[node.qualifiedName];
332
- if (!childVariable) {
333
- continue;
334
- }
335
- typeAlias.directChildren[childVariable.qualifiedName] = childVariable;
336
- typeAlias.allChildren[childVariable.qualifiedName] = childVariable;
337
- typeAlias.baseChildren[childVariable.qualifiedName] = childVariable;
338
- }
339
- else if (util_1.isInstanceOf(node, types_1.ClassDeclaration)) {
340
- var childClass = flattenedSourceGraph.classes[node.qualifiedName];
341
- if (!childClass) {
342
- continue;
343
- }
344
- typeAlias.directChildren[childClass.qualifiedName] = childClass;
345
- typeAlias.allChildren[childClass.qualifiedName] = childClass;
346
- typeAlias.baseChildren[childClass.qualifiedName] = childClass;
347
- }
348
- }
349
- }
350
- }
351
- function loadInterfaceAndChildren(interfaceDeclaration, sourceGraph, flattenedSourceGraph) {
352
- if (!flattenedSourceGraph.interfaces[interfaceDeclaration.qualifiedName]) {
353
- flattenedSourceGraph.interfaces[interfaceDeclaration.qualifiedName] = new types_1.Interface(interfaceDeclaration.packageName, interfaceDeclaration.name, interfaceDeclaration.properties, interfaceDeclaration.methods, interfaceDeclaration.filePath);
354
- }
355
- var _interface = flattenedSourceGraph.interfaces[interfaceDeclaration.qualifiedName];
356
- var inEdges = sourceGraph.inEdges(interfaceDeclaration.qualifiedName);
357
- if (inEdges) {
358
- for (var _i = 0, inEdges_2 = inEdges; _i < inEdges_2.length; _i++) {
359
- var inEdge = inEdges_2[_i];
360
- var node = sourceGraph.node(inEdge.v);
361
- if (!node) {
362
- continue;
363
- }
364
- if (util_1.isInstanceOf(node, types_1.InterfaceDeclaration)) {
365
- var childInterface = flattenedSourceGraph.interfaces[node.qualifiedName];
366
- if (!childInterface) {
367
- continue;
368
- }
369
- _interface.directChildren[childInterface.qualifiedName] = childInterface;
370
- _interface.allChildren[childInterface.qualifiedName] = childInterface;
371
- _interface.allChildren = Object.assign(_interface.allChildren, childInterface.allChildren);
372
- if (Object.keys(childInterface.directChildren).length === 0 &&
373
- childInterface.directChildren.constructor === Object) {
374
- _interface.baseChildren[childInterface.qualifiedName] = childInterface;
375
- }
376
- else {
377
- _interface.baseChildren = Object.assign(_interface.baseChildren, childInterface.baseChildren);
378
- }
379
- }
380
- else if (util_1.isInstanceOf(node, types_1.TypeAliasDeclaration)) {
381
- var childTypeAlias = flattenedSourceGraph.typeAliases[node.qualifiedName];
382
- if (!childTypeAlias) {
383
- continue;
384
- }
385
- _interface.directChildren[childTypeAlias.qualifiedName] = childTypeAlias;
386
- _interface.allChildren[childTypeAlias.qualifiedName] = childTypeAlias;
387
- _interface.allChildren = Object.assign(_interface.allChildren, childTypeAlias.allChildren);
388
- if (Object.keys(childTypeAlias.directChildren).length === 0 &&
389
- childTypeAlias.directChildren.constructor === Object) {
390
- _interface.baseChildren[childTypeAlias.qualifiedName] = childTypeAlias;
391
- }
392
- else {
393
- _interface.baseChildren = Object.assign(_interface.baseChildren, childTypeAlias.baseChildren);
394
- }
395
- }
396
- else if (util_1.isInstanceOf(node, types_1.ClassDeclaration)) {
397
- var childClass = flattenedSourceGraph.classes[node.qualifiedName];
398
- if (!childClass) {
399
- continue;
400
- }
401
- _interface.directChildren[childClass.qualifiedName] = childClass;
402
- _interface.allChildren[childClass.qualifiedName] = childClass;
403
- _interface.allChildren = Object.assign(_interface.allChildren, childClass.allChildren);
404
- if (Object.keys(childClass.directChildren).length === 0 && childClass.directChildren.constructor === Object) {
405
- _interface.baseChildren[childClass.qualifiedName] = childClass;
406
- }
407
- else {
408
- _interface.baseChildren = Object.assign(_interface.baseChildren, childClass.baseChildren);
409
- }
410
- }
411
- else if (util_1.isInstanceOf(node, types_1.VariableDeclaration)) {
412
- var childVariable = flattenedSourceGraph.variables[node.qualifiedName];
413
- if (!childVariable) {
414
- continue;
415
- }
416
- _interface.directChildren[childVariable.qualifiedName] = childVariable;
417
- _interface.allChildren[childVariable.qualifiedName] = childVariable;
418
- _interface.baseChildren[childVariable.qualifiedName] = childVariable;
419
- }
420
- }
421
- }
422
- }
423
- function loadClassAndChildren(classDeclaration, sourceGraph, sourceLinks, flattenedSourceGraph) {
424
- if (!flattenedSourceGraph.classes[classDeclaration.qualifiedName]) {
425
- flattenedSourceGraph.classes[classDeclaration.qualifiedName] = new types_1.Class(classDeclaration.packageName, classDeclaration.name, classDeclaration.filePath, classDeclaration.isAbstract, classDeclaration.isStatic, classDeclaration.visibility, classDeclaration.properties, classDeclaration.methods, sourceLinks[classDeclaration.qualifiedName]);
426
- }
427
- var _class = flattenedSourceGraph.classes[classDeclaration.qualifiedName];
428
- var inEdges = sourceGraph.inEdges(classDeclaration.qualifiedName);
429
- if (inEdges) {
430
- for (var _i = 0, inEdges_3 = inEdges; _i < inEdges_3.length; _i++) {
431
- var inEdge = inEdges_3[_i];
432
- var node = sourceGraph.node(inEdge.v);
433
- if (!node) {
434
- continue;
435
- }
436
- if (util_1.isInstanceOf(node, types_1.ClassDeclaration)) {
437
- var childClass = flattenedSourceGraph.classes[node.qualifiedName];
438
- if (!childClass) {
439
- continue;
440
- }
441
- _class.directChildren[childClass.qualifiedName] = childClass;
442
- _class.allChildren[childClass.qualifiedName] = childClass;
443
- _class.allChildren = Object.assign(_class.allChildren, childClass.allChildren);
444
- if (Object.keys(childClass.directChildren).length === 0 && childClass.directChildren.constructor === Object) {
445
- _class.baseChildren[childClass.qualifiedName] = childClass;
446
- }
447
- else {
448
- _class.baseChildren = Object.assign(_class.baseChildren, childClass.baseChildren);
449
- }
450
- }
451
- }
452
- }
453
- }
454
- function addTypeParameters(flattenedSourceGraph, sourceGraph) {
455
- for (var _i = 0, _a = Object.keys(flattenedSourceGraph.typeAliases); _i < _a.length; _i++) {
456
- var typeAliasName = _a[_i];
457
- var typeAlias = flattenedSourceGraph.typeAliases[typeAliasName];
458
- var typeAliasDeclaration = sourceGraph.node(typeAliasName);
459
- if (!typeAliasDeclaration) {
460
- continue;
461
- }
462
- if (!typeAliasDeclaration.directParents) {
463
- continue;
464
- }
465
- addTypeParametersToSource(typeAlias, typeAliasDeclaration.directParents, flattenedSourceGraph);
466
- }
467
- for (var _b = 0, _c = Object.keys(flattenedSourceGraph.interfaces); _b < _c.length; _b++) {
468
- var interfaceName = _c[_b];
469
- var _interface = flattenedSourceGraph.interfaces[interfaceName];
470
- var interfaceDeclaration = sourceGraph.node(interfaceName);
471
- if (!interfaceDeclaration) {
472
- continue;
473
- }
474
- addTypeParametersToSource(_interface, interfaceDeclaration.directParents, flattenedSourceGraph);
475
- }
476
- for (var _d = 0, _e = Object.keys(flattenedSourceGraph.classes); _d < _e.length; _d++) {
477
- var className = _e[_d];
478
- var _class = flattenedSourceGraph.classes[className];
479
- var classDeclaration = sourceGraph.node(className);
480
- if (!classDeclaration) {
481
- continue;
482
- }
483
- addTypeParametersToSource(_class, classDeclaration.directParentClasses, flattenedSourceGraph);
484
- addTypeParametersToSource(_class, classDeclaration.directParentInterfaces, flattenedSourceGraph);
485
- }
486
- for (var _f = 0, _g = Object.keys(flattenedSourceGraph.variables); _f < _g.length; _f++) {
487
- var variableName = _g[_f];
488
- var variable = flattenedSourceGraph.variables[variableName];
489
- var variableDeclaration = sourceGraph.node(variableName);
490
- if (!variableDeclaration) {
491
- continue;
492
- }
493
- if (!variableDeclaration.type) {
494
- continue;
495
- }
496
- if (!variableDeclaration.type.directParents) {
497
- continue;
498
- }
499
- addTypeParametersToSource(variable, variableDeclaration.type.directParents, flattenedSourceGraph);
500
- }
501
- }
502
- function addTypeParametersToSource(source, parentDeclarations, flattenedSourceGraph) {
503
- if (!parentDeclarations) {
504
- return;
505
- }
506
- for (var _i = 0, parentDeclarations_1 = parentDeclarations; _i < parentDeclarations_1.length; _i++) {
507
- var parentDeclaration = parentDeclarations_1[_i];
508
- if (!parentDeclaration.typeParameters) {
509
- continue;
510
- }
511
- for (var _a = 0, _b = parentDeclaration.typeParameters; _a < _b.length; _a++) {
512
- var typeParameter = _b[_a];
513
- if (!source.typeParameters[parentDeclaration.qualifiedName]) {
514
- source.typeParameters[parentDeclaration.qualifiedName] = [];
515
- }
516
- if (flattenedSourceGraph.typeAliases[typeParameter]) {
517
- source.typeParameters[parentDeclaration.qualifiedName].push(flattenedSourceGraph.typeAliases[typeParameter]);
518
- }
519
- else if (flattenedSourceGraph.interfaces[typeParameter]) {
520
- source.typeParameters[parentDeclaration.qualifiedName].push(flattenedSourceGraph.interfaces[typeParameter]);
521
- }
522
- }
523
- }
524
- }
525
- function pruneNonLoadables(flattenedSourceGraph) {
526
- for (var _i = 0, _a = Object.keys(flattenedSourceGraph.variables); _i < _a.length; _i++) {
527
- var variableQualifiedName = _a[_i];
528
- var variable = flattenedSourceGraph.variables[variableQualifiedName];
529
- if (!variable.allParentTypes[Loadable_1.LOADABLE_QUALIFIED_NAME]) {
530
- delete flattenedSourceGraph.variables[variableQualifiedName];
531
- }
532
- }
533
- for (var _b = 0, _c = Object.keys(flattenedSourceGraph.typeAliases); _b < _c.length; _b++) {
534
- var qualifiedName = _c[_b];
535
- var typeAlias = flattenedSourceGraph.typeAliases[qualifiedName];
536
- if (!typeAlias.allParents[Loadable_1.LOADABLE_QUALIFIED_NAME]) {
537
- delete flattenedSourceGraph.typeAliases[qualifiedName];
538
- }
539
- }
540
- for (var _d = 0, _e = Object.keys(flattenedSourceGraph.classes); _d < _e.length; _d++) {
541
- var qualifiedName = _e[_d];
542
- var _class = flattenedSourceGraph.classes[qualifiedName];
543
- if (!_class.allParents[Loadable_1.LOADABLE_QUALIFIED_NAME]) {
544
- delete flattenedSourceGraph.classes[qualifiedName];
545
- }
546
- }
547
- for (var _f = 0, _g = Object.keys(flattenedSourceGraph.interfaces); _f < _g.length; _f++) {
548
- var qualifiedName = _g[_f];
549
- var _interface = flattenedSourceGraph.interfaces[qualifiedName];
550
- if (!_interface.allParents[Loadable_1.LOADABLE_QUALIFIED_NAME] && qualifiedName != Loadable_1.LOADABLE_QUALIFIED_NAME) {
551
- delete flattenedSourceGraph.interfaces[qualifiedName];
552
- }
553
- }
554
- }
555
- //# sourceMappingURL=FlattenedSourceGraph.js.map