@proteinjs/reflection-build 1.1.1 → 1.2.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.
- package/CHANGELOG.md +11 -0
- package/dist/src/codegen/writeGeneratedIndex.js +9 -0
- package/dist/src/codegen/writeGeneratedIndex.js.map +1 -1
- package/dist/test/examples/source-repository/a/generated/index.js +1 -1
- package/dist/test/examples/source-repository/a/generated/index.js.map +1 -1
- package/dist/test/examples/source-repository/b/generated/index.js +1 -1
- package/dist/test/examples/source-repository/b/generated/index.js.map +1 -1
- package/package.json +4 -5
- package/src/codegen/writeGeneratedIndex.ts +12 -0
- package/test/examples/source-repository/a/dist/codegen/writeGeneratedIndex.js +9 -0
- package/test/examples/source-repository/a/dist/codegen/writeGeneratedIndex.js.map +1 -1
- package/test/examples/source-repository/a/dist/generated/index.js +1 -1
- package/test/examples/source-repository/a/dist/generated/index.js.map +1 -1
- package/test/examples/source-repository/a/generated/index.ts +33 -38
- package/test/examples/source-repository/a/node_modules/.package-lock.json +59 -6
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/.eslintrc.js +20 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/.prettierignore +4 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/.prettierrc +8 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/CHANGELOG.md +58 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.d.ts +5 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.js +18 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.d.ts +19 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js +555 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/Loadable.d.ts +3 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/Loadable.js +5 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/Loadable.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepository.d.ts +45 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js +176 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.d.ts +11 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js +9 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.d.ts +13 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js +19 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/types.d.ts +221 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/types.js +234 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/src/types.js.map +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/index.ts +5 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/jest.config.js +9 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/package.json +42 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/FlattenedSourceGraph.ts +702 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/Loadable.ts +2 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/SourceRepository.ts +250 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/SourceRepositoryFilter.ts +15 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/sourceGraphTypes.ts +14 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/src/types.ts +236 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/tsconfig.json +19 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/types/@dagrejs/graphlib.d.ts +1 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/CHANGELOG.md +13 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/Fs.d.ts +23 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/Fs.js +67 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/Fs.js.map +1 -1
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/GitUtil.d.ts +297 -10
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/GitUtil.js +349 -112
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/GitUtil.js.map +1 -1
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/cmd.d.ts +10 -1
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/cmd.js +91 -48
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/dist/src/cmd.js.map +1 -1
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/package.json +2 -2
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/src/Fs.ts +75 -0
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/src/GitUtil.ts +248 -110
- package/test/examples/source-repository/a/node_modules/@proteinjs/util-node/src/cmd.ts +84 -59
- package/test/examples/source-repository/a/node_modules/bindings/LICENSE.md +22 -0
- package/test/examples/source-repository/a/node_modules/bindings/README.md +98 -0
- package/test/examples/source-repository/a/node_modules/bindings/bindings.js +221 -0
- package/test/examples/source-repository/a/node_modules/bindings/package.json +28 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/.travis.yml +30 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/History.md +21 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/LICENSE +20 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/README.md +74 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/index.d.ts +2 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/index.js +66 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/package.json +32 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/test/test.js +24 -0
- package/test/examples/source-repository/a/node_modules/file-uri-to-path/test/tests.json +13 -0
- package/test/examples/source-repository/a/node_modules/fsevents/LICENSE +22 -0
- package/test/examples/source-repository/a/node_modules/fsevents/README.md +89 -0
- package/test/examples/source-repository/a/node_modules/fsevents/fsevents.d.ts +46 -0
- package/test/examples/source-repository/a/node_modules/fsevents/fsevents.js +83 -0
- package/test/examples/source-repository/a/node_modules/fsevents/fsevents.node +0 -0
- package/test/examples/source-repository/a/node_modules/fsevents/package.json +62 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/.travis.yml +103 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/ISSUE_TEMPLATE.md +8 -0
- package/{LICENSE → test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/LICENSE} +6 -5
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/Readme.md +78 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/binding.gyp +21 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/.target.mk +53 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Makefile +352 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/.node.d +1 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/obj.target/fse/fsevents.o.d.raw +75 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/Release/.node +0 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/binding.Makefile +6 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/fse.target.mk +188 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/build/gyp-mac-tool +772 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/fsevents.cc +88 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/fsevents.js +106 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/install.js +13 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/package.json +34 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/async.cc +43 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/constants.cc +110 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/methods.cc +44 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/storage.cc +27 -0
- package/test/examples/source-repository/a/node_modules/glob-watcher/node_modules/fsevents/src/thread.cc +71 -0
- package/test/examples/source-repository/a/node_modules/nan/CHANGELOG.md +557 -0
- package/test/examples/source-repository/a/node_modules/nan/CMakeLists.txt +138 -0
- package/test/examples/source-repository/a/node_modules/nan/LICENSE.md +9 -0
- package/test/examples/source-repository/a/node_modules/nan/README.md +456 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/asyncworker.md +146 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/buffers.md +54 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/callback.md +76 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/converters.md +41 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/errors.md +226 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/json.md +62 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/maybe_types.md +583 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/methods.md +672 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/new.md +147 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/node_misc.md +123 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/object_wrappers.md +263 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/persistent.md +296 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/scopes.md +73 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/script.md +58 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/string_bytes.md +62 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/v8_internals.md +199 -0
- package/test/examples/source-repository/a/node_modules/nan/doc/v8_misc.md +85 -0
- package/test/examples/source-repository/a/node_modules/nan/include_dirs.js +1 -0
- package/test/examples/source-repository/a/node_modules/nan/nan.h +2958 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_callbacks.h +92 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_callbacks_12_inl.h +520 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_callbacks_pre_12_inl.h +520 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_converters.h +72 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_converters_43_inl.h +68 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_converters_pre_43_inl.h +42 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_define_own_property_helper.h +29 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_implementation_12_inl.h +430 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_implementation_pre_12_inl.h +263 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_json.h +166 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_maybe_43_inl.h +356 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_maybe_pre_43_inl.h +268 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_new.h +340 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_object_wrap.h +156 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_persistent_12_inl.h +132 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_persistent_pre_12_inl.h +242 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_private.h +73 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_scriptorigin.h +76 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_string_bytes.h +305 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_typedarray_contents.h +96 -0
- package/test/examples/source-repository/a/node_modules/nan/nan_weak.h +437 -0
- package/test/examples/source-repository/a/node_modules/nan/package.json +38 -0
- package/test/examples/source-repository/a/node_modules/nan/tools/1to2.js +412 -0
- package/test/examples/source-repository/a/node_modules/nan/tools/README.md +14 -0
- package/test/examples/source-repository/a/node_modules/nan/tools/package.json +19 -0
- package/test/examples/source-repository/a/package-lock.json +8 -8
- package/test/examples/source-repository/a/package.json +3 -3
- package/test/examples/source-repository/b/dist/codegen/writeGeneratedIndex.js +9 -0
- package/test/examples/source-repository/b/dist/codegen/writeGeneratedIndex.js.map +1 -1
- package/test/examples/source-repository/b/dist/generated/index.js +1 -1
- package/test/examples/source-repository/b/dist/generated/index.js.map +1 -1
- package/test/examples/source-repository/b/generated/index.ts +11 -10
- package/test/examples/source-repository/b/node_modules/.package-lock.json +57 -4
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/.eslintrc.js +20 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/.prettierignore +4 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/.prettierrc +8 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/CHANGELOG.md +58 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/index.d.ts +5 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/index.js +18 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/index.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.d.ts +19 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js +555 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/FlattenedSourceGraph.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/Loadable.d.ts +3 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/Loadable.js +5 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/Loadable.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepository.d.ts +45 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js +176 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepository.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.d.ts +11 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js +9 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/SourceRepositoryFilter.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.d.ts +13 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js +19 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/sourceGraphTypes.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/types.d.ts +221 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/types.js +234 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/dist/src/types.js.map +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/index.ts +5 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/jest.config.js +9 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/package.json +42 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/FlattenedSourceGraph.ts +702 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/Loadable.ts +2 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/SourceRepository.ts +250 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/SourceRepositoryFilter.ts +15 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/sourceGraphTypes.ts +14 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/src/types.ts +236 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/tsconfig.json +19 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/reflection/types/@dagrejs/graphlib.d.ts +1 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/CHANGELOG.md +13 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/Fs.d.ts +23 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/Fs.js +67 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/Fs.js.map +1 -1
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/GitUtil.d.ts +297 -10
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/GitUtil.js +349 -112
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/GitUtil.js.map +1 -1
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/cmd.d.ts +10 -1
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/cmd.js +91 -48
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/dist/src/cmd.js.map +1 -1
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/package.json +2 -2
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/src/Fs.ts +75 -0
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/src/GitUtil.ts +248 -110
- package/test/examples/source-repository/b/node_modules/@proteinjs/util-node/src/cmd.ts +84 -59
- package/test/examples/source-repository/b/node_modules/bindings/LICENSE.md +22 -0
- package/test/examples/source-repository/b/node_modules/bindings/README.md +98 -0
- package/test/examples/source-repository/b/node_modules/bindings/bindings.js +221 -0
- package/test/examples/source-repository/b/node_modules/bindings/package.json +28 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/.travis.yml +30 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/History.md +21 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/LICENSE +20 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/README.md +74 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/index.d.ts +2 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/index.js +66 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/package.json +32 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/test/test.js +24 -0
- package/test/examples/source-repository/b/node_modules/file-uri-to-path/test/tests.json +13 -0
- package/test/examples/source-repository/b/node_modules/fsevents/LICENSE +22 -0
- package/test/examples/source-repository/b/node_modules/fsevents/README.md +89 -0
- package/test/examples/source-repository/b/node_modules/fsevents/fsevents.d.ts +46 -0
- package/test/examples/source-repository/b/node_modules/fsevents/fsevents.js +83 -0
- package/test/examples/source-repository/b/node_modules/fsevents/fsevents.node +0 -0
- package/test/examples/source-repository/b/node_modules/fsevents/package.json +62 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/.travis.yml +103 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/ISSUE_TEMPLATE.md +8 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/LICENSE +22 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/Readme.md +78 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/binding.gyp +21 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/.target.mk +53 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Makefile +352 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/.node.d +1 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Release/.deps/Release/obj.target/fse/fsevents.o.d.raw +75 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/Release/.node +0 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/binding.Makefile +6 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/fse.target.mk +188 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/build/gyp-mac-tool +772 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/fsevents.cc +88 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/fsevents.js +106 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/install.js +13 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/package.json +34 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/async.cc +43 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/constants.cc +110 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/methods.cc +44 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/storage.cc +27 -0
- package/test/examples/source-repository/b/node_modules/glob-watcher/node_modules/fsevents/src/thread.cc +71 -0
- package/test/examples/source-repository/b/node_modules/nan/CHANGELOG.md +557 -0
- package/test/examples/source-repository/b/node_modules/nan/CMakeLists.txt +138 -0
- package/test/examples/source-repository/b/node_modules/nan/LICENSE.md +9 -0
- package/test/examples/source-repository/b/node_modules/nan/README.md +456 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/asyncworker.md +146 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/buffers.md +54 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/callback.md +76 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/converters.md +41 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/errors.md +226 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/json.md +62 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/maybe_types.md +583 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/methods.md +672 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/new.md +147 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/node_misc.md +123 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/object_wrappers.md +263 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/persistent.md +296 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/scopes.md +73 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/script.md +58 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/string_bytes.md +62 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/v8_internals.md +199 -0
- package/test/examples/source-repository/b/node_modules/nan/doc/v8_misc.md +85 -0
- package/test/examples/source-repository/b/node_modules/nan/include_dirs.js +1 -0
- package/test/examples/source-repository/b/node_modules/nan/nan.h +2958 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_callbacks.h +92 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_callbacks_12_inl.h +520 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_callbacks_pre_12_inl.h +520 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_converters.h +72 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_converters_43_inl.h +68 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_converters_pre_43_inl.h +42 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_define_own_property_helper.h +29 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_implementation_12_inl.h +430 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_implementation_pre_12_inl.h +263 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_json.h +166 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_maybe_43_inl.h +356 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_maybe_pre_43_inl.h +268 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_new.h +340 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_object_wrap.h +156 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_persistent_12_inl.h +132 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_persistent_pre_12_inl.h +242 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_private.h +73 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_scriptorigin.h +76 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_string_bytes.h +305 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_typedarray_contents.h +96 -0
- package/test/examples/source-repository/b/node_modules/nan/nan_weak.h +437 -0
- package/test/examples/source-repository/b/node_modules/nan/package.json +38 -0
- package/test/examples/source-repository/b/node_modules/nan/tools/1to2.js +412 -0
- package/test/examples/source-repository/b/node_modules/nan/tools/README.md +14 -0
- package/test/examples/source-repository/b/node_modules/nan/tools/package.json +19 -0
- package/test/examples/source-repository/b/package-lock.json +6 -6
- package/test/examples/source-repository/b/package.json +3 -3
|
@@ -0,0 +1,58 @@
|
|
|
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
|
|
@@ -0,0 +1,18 @@
|
|
|
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
|
package/test/examples/source-repository/a/node_modules/@proteinjs/reflection/dist/index.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,iDAA+B;AAC/B,8CAA4B;AAC5B,yDAAuC;AACvC,yDAAuC;AACvC,+DAA6C"}
|
|
@@ -0,0 +1,19 @@
|
|
|
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;
|
|
@@ -0,0 +1,555 @@
|
|
|
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
|