@weavelogic/knowledge-graph-agent 0.3.0 → 0.6.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.
- package/README.md +374 -427
- package/dist/_virtual/ExpiringCache.js +5 -0
- package/dist/_virtual/ExpiringCache.js.map +1 -0
- package/dist/_virtual/___vite-browser-external.js +7 -0
- package/dist/_virtual/___vite-browser-external.js.map +1 -0
- package/dist/_virtual/__vite-browser-external.js +5 -0
- package/dist/_virtual/__vite-browser-external.js.map +1 -0
- package/dist/_virtual/_commonjs-dynamic-modules.js +7 -0
- package/dist/_virtual/_commonjs-dynamic-modules.js.map +1 -0
- package/dist/_virtual/_commonjsHelpers.js +27 -0
- package/dist/_virtual/_commonjsHelpers.js.map +1 -1
- package/dist/_virtual/assert-valid-pattern.js +5 -0
- package/dist/_virtual/assert-valid-pattern.js.map +1 -0
- package/dist/_virtual/ast-converter.js +5 -0
- package/dist/_virtual/ast-converter.js.map +1 -0
- package/dist/_virtual/ast-spec.js +5 -0
- package/dist/_virtual/ast-spec.js.map +1 -0
- package/dist/_virtual/ast.js +5 -0
- package/dist/_virtual/ast.js.map +1 -0
- package/dist/_virtual/brace-expressions.js +5 -0
- package/dist/_virtual/brace-expressions.js.map +1 -0
- package/dist/_virtual/browser.js +6 -0
- package/dist/_virtual/browser.js.map +1 -0
- package/dist/_virtual/browser2.js +5 -0
- package/dist/_virtual/browser2.js.map +1 -0
- package/dist/_virtual/candidateTSConfigRootDirs.js +5 -0
- package/dist/_virtual/candidateTSConfigRootDirs.js.map +1 -0
- package/dist/_virtual/check-modifiers.js +5 -0
- package/dist/_virtual/check-modifiers.js.map +1 -0
- package/dist/_virtual/clear-caches.js +5 -0
- package/dist/_virtual/clear-caches.js.map +1 -0
- package/dist/_virtual/compilerOptions.js +5 -0
- package/dist/_virtual/compilerOptions.js.map +1 -0
- package/dist/_virtual/convert-comments.js +5 -0
- package/dist/_virtual/convert-comments.js.map +1 -0
- package/dist/_virtual/convert.js +5 -0
- package/dist/_virtual/convert.js.map +1 -0
- package/dist/_virtual/createIsolatedProgram.js +5 -0
- package/dist/_virtual/createIsolatedProgram.js.map +1 -0
- package/dist/_virtual/createParseSettings.js +5 -0
- package/dist/_virtual/createParseSettings.js.map +1 -0
- package/dist/_virtual/createParserServices.js +5 -0
- package/dist/_virtual/createParserServices.js.map +1 -0
- package/dist/_virtual/createProjectProgram.js +5 -0
- package/dist/_virtual/createProjectProgram.js.map +1 -0
- package/dist/_virtual/createProjectProgramError.js +5 -0
- package/dist/_virtual/createProjectProgramError.js.map +1 -0
- package/dist/_virtual/createProjectService.js +5 -0
- package/dist/_virtual/createProjectService.js.map +1 -0
- package/dist/_virtual/createSourceFile.js +5 -0
- package/dist/_virtual/createSourceFile.js.map +1 -0
- package/dist/_virtual/describeFilePath.js +5 -0
- package/dist/_virtual/describeFilePath.js.map +1 -0
- package/dist/_virtual/escape.js +5 -0
- package/dist/_virtual/escape.js.map +1 -0
- package/dist/_virtual/eslint-visitor-keys.js +5 -0
- package/dist/_virtual/eslint-visitor-keys.js.map +1 -0
- package/dist/_virtual/estree-to-ts-node-types.js +5 -0
- package/dist/_virtual/estree-to-ts-node-types.js.map +1 -0
- package/dist/_virtual/get-keys.js +5 -0
- package/dist/_virtual/get-keys.js.map +1 -0
- package/dist/_virtual/getModifiers.js +5 -0
- package/dist/_virtual/getModifiers.js.map +1 -0
- package/dist/_virtual/getParsedConfigFile.js +5 -0
- package/dist/_virtual/getParsedConfigFile.js.map +1 -0
- package/dist/_virtual/getParsedConfigFileFromTSServer.js +5 -0
- package/dist/_virtual/getParsedConfigFileFromTSServer.js.map +1 -0
- package/dist/_virtual/getProjectConfigFiles.js +5 -0
- package/dist/_virtual/getProjectConfigFiles.js.map +1 -0
- package/dist/_virtual/getScriptKind.js +5 -0
- package/dist/_virtual/getScriptKind.js.map +1 -0
- package/dist/_virtual/getWatchProgramsForProjects.js +5 -0
- package/dist/_virtual/getWatchProgramsForProjects.js.map +1 -0
- package/dist/_virtual/global-ponyfill.js +9 -0
- package/dist/_virtual/global-ponyfill.js.map +1 -0
- package/dist/_virtual/global-ponyfill2.js +5 -0
- package/dist/_virtual/global-ponyfill2.js.map +1 -0
- package/dist/_virtual/index.js +2 -4
- package/dist/_virtual/index.js.map +1 -1
- package/dist/_virtual/index10.js +2 -2
- package/dist/_virtual/index11.js +2 -2
- package/dist/_virtual/index2.js +2 -2
- package/dist/_virtual/index3.js +2 -2
- package/dist/_virtual/index4.js +2 -2
- package/dist/_virtual/index5.js +2 -2
- package/dist/_virtual/index6.js +2 -2
- package/dist/_virtual/index7.js +2 -2
- package/dist/_virtual/index8.js +2 -2
- package/dist/_virtual/index9.js +2 -2
- package/dist/_virtual/inferSingleRun.js +5 -0
- package/dist/_virtual/inferSingleRun.js.map +1 -0
- package/dist/_virtual/lib.js +5 -0
- package/dist/_virtual/lib.js.map +1 -0
- package/dist/_virtual/node-utils.js +5 -0
- package/dist/_virtual/node-utils.js.map +1 -0
- package/dist/_virtual/parser-options.js +5 -0
- package/dist/_virtual/parser-options.js.map +1 -0
- package/dist/_virtual/parser.js +5 -0
- package/dist/_virtual/parser.js.map +1 -0
- package/dist/_virtual/re.js +5 -0
- package/dist/_virtual/re.js.map +1 -0
- package/dist/_virtual/resolveProjectList.js +5 -0
- package/dist/_virtual/resolveProjectList.js.map +1 -0
- package/dist/_virtual/semantic-or-syntactic-errors.js +5 -0
- package/dist/_virtual/semantic-or-syntactic-errors.js.map +1 -0
- package/dist/_virtual/shared.js +5 -0
- package/dist/_virtual/shared.js.map +1 -0
- package/dist/_virtual/simple-traverse.js +5 -0
- package/dist/_virtual/simple-traverse.js.map +1 -0
- package/dist/_virtual/source-files.js +5 -0
- package/dist/_virtual/source-files.js.map +1 -0
- package/dist/_virtual/ts-estree.js +5 -0
- package/dist/_virtual/ts-estree.js.map +1 -0
- package/dist/_virtual/ts-nodes.js +5 -0
- package/dist/_virtual/ts-nodes.js.map +1 -0
- package/dist/_virtual/tsserverlibrary.js +5 -0
- package/dist/_virtual/tsserverlibrary.js.map +1 -0
- package/dist/_virtual/typescript.js +5 -0
- package/dist/_virtual/typescript.js.map +1 -0
- package/dist/_virtual/unescape.js +5 -0
- package/dist/_virtual/unescape.js.map +1 -0
- package/dist/_virtual/useProgramFromProjectService.js +5 -0
- package/dist/_virtual/useProgramFromProjectService.js.map +1 -0
- package/dist/_virtual/useProvidedPrograms.js +5 -0
- package/dist/_virtual/useProvidedPrograms.js.map +1 -0
- package/dist/_virtual/utils.js +5 -0
- package/dist/_virtual/utils.js.map +1 -0
- package/dist/_virtual/validateDefaultProjectForFilesGlob.js +5 -0
- package/dist/_virtual/validateDefaultProjectForFilesGlob.js.map +1 -0
- package/dist/_virtual/version-check.js +5 -0
- package/dist/_virtual/version-check.js.map +1 -0
- package/dist/_virtual/version.js +5 -0
- package/dist/_virtual/version.js.map +1 -0
- package/dist/_virtual/visitor-keys.js +5 -0
- package/dist/_virtual/visitor-keys.js.map +1 -0
- package/dist/_virtual/warnAboutTSVersion.js +5 -0
- package/dist/_virtual/warnAboutTSVersion.js.map +1 -0
- package/dist/_virtual/withoutProjectParserOptions.js +5 -0
- package/dist/_virtual/withoutProjectParserOptions.js.map +1 -0
- package/dist/_virtual/xhtml-entities.js +5 -0
- package/dist/_virtual/xhtml-entities.js.map +1 -0
- package/dist/audit/config.d.ts +150 -0
- package/dist/audit/config.d.ts.map +1 -0
- package/dist/audit/config.js +111 -0
- package/dist/audit/config.js.map +1 -0
- package/dist/audit/index.d.ts +38 -0
- package/dist/audit/index.d.ts.map +1 -0
- package/dist/audit/services/audit-chain.d.ts +276 -0
- package/dist/audit/services/audit-chain.d.ts.map +1 -0
- package/dist/audit/services/audit-chain.js +502 -0
- package/dist/audit/services/audit-chain.js.map +1 -0
- package/dist/audit/services/index.d.ts +11 -0
- package/dist/audit/services/index.d.ts.map +1 -0
- package/dist/audit/services/syndication.d.ts +334 -0
- package/dist/audit/services/syndication.d.ts.map +1 -0
- package/dist/audit/services/syndication.js +589 -0
- package/dist/audit/services/syndication.js.map +1 -0
- package/dist/audit/types.d.ts +453 -0
- package/dist/audit/types.d.ts.map +1 -0
- package/dist/cli/commands/audit.d.ts +21 -0
- package/dist/cli/commands/audit.d.ts.map +1 -0
- package/dist/cli/commands/audit.js +621 -0
- package/dist/cli/commands/audit.js.map +1 -0
- package/dist/cli/commands/dashboard.d.ts +14 -0
- package/dist/cli/commands/dashboard.d.ts.map +1 -0
- package/dist/cli/commands/dashboard.js +271 -0
- package/dist/cli/commands/dashboard.js.map +1 -0
- package/dist/cli/commands/plugin.d.ts +14 -0
- package/dist/cli/commands/plugin.d.ts.map +1 -0
- package/dist/cli/commands/plugin.js +784 -0
- package/dist/cli/commands/plugin.js.map +1 -0
- package/dist/cli/commands/serve.d.ts +15 -0
- package/dist/cli/commands/serve.d.ts.map +1 -0
- package/dist/cli/commands/serve.js +252 -0
- package/dist/cli/commands/serve.js.map +1 -0
- package/dist/cli/commands/vector.d.ts +14 -0
- package/dist/cli/commands/vector.d.ts.map +1 -0
- package/dist/cli/commands/vector.js +429 -0
- package/dist/cli/commands/vector.js.map +1 -0
- package/dist/cli/commands/workflow.d.ts +12 -0
- package/dist/cli/commands/workflow.d.ts.map +1 -0
- package/dist/cli/commands/workflow.js +471 -0
- package/dist/cli/commands/workflow.js.map +1 -0
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +54 -1
- package/dist/cli/index.js.map +1 -1
- package/dist/config/manager.js +325 -0
- package/dist/config/manager.js.map +1 -0
- package/dist/dashboard-server/index.d.ts +31 -0
- package/dist/dashboard-server/index.d.ts.map +1 -0
- package/dist/dashboard-server/server.d.ts +205 -0
- package/dist/dashboard-server/server.d.ts.map +1 -0
- package/dist/dashboard-server/server.js +651 -0
- package/dist/dashboard-server/server.js.map +1 -0
- package/dist/database/schemas/index.d.ts +85 -0
- package/dist/database/schemas/index.d.ts.map +1 -0
- package/dist/graphql/context.d.ts +154 -0
- package/dist/graphql/context.d.ts.map +1 -0
- package/dist/graphql/context.js +168 -0
- package/dist/graphql/context.js.map +1 -0
- package/dist/graphql/index.d.ts +12 -0
- package/dist/graphql/index.d.ts.map +1 -0
- package/dist/graphql/pubsub.d.ts +282 -0
- package/dist/graphql/pubsub.d.ts.map +1 -0
- package/dist/graphql/resolvers/index.d.ts +519 -0
- package/dist/graphql/resolvers/index.d.ts.map +1 -0
- package/dist/graphql/resolvers/mutations.d.ts +255 -0
- package/dist/graphql/resolvers/mutations.d.ts.map +1 -0
- package/dist/graphql/resolvers/queries.d.ts +451 -0
- package/dist/graphql/resolvers/queries.d.ts.map +1 -0
- package/dist/graphql/resolvers/subscriptions.d.ts +399 -0
- package/dist/graphql/resolvers/subscriptions.d.ts.map +1 -0
- package/dist/graphql/scalars.d.ts +89 -0
- package/dist/graphql/scalars.d.ts.map +1 -0
- package/dist/graphql/scalars.js +242 -0
- package/dist/graphql/scalars.js.map +1 -0
- package/dist/graphql/server.d.ts +122 -0
- package/dist/graphql/server.d.ts.map +1 -0
- package/dist/graphql/server.js +368 -0
- package/dist/graphql/server.js.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +115 -0
- package/dist/index.js.map +1 -1
- package/dist/mcp-server/handlers/index.js +1 -1
- package/dist/mcp-server/server.js +2 -2
- package/dist/mcp-server/tools/audit/checkpoint.d.ts +58 -0
- package/dist/mcp-server/tools/audit/checkpoint.d.ts.map +1 -0
- package/dist/mcp-server/tools/audit/checkpoint.js +73 -0
- package/dist/mcp-server/tools/audit/checkpoint.js.map +1 -0
- package/dist/mcp-server/tools/audit/index.d.ts +53 -0
- package/dist/mcp-server/tools/audit/index.d.ts.map +1 -0
- package/dist/mcp-server/tools/audit/index.js +12 -0
- package/dist/mcp-server/tools/audit/index.js.map +1 -0
- package/dist/mcp-server/tools/audit/query.d.ts +58 -0
- package/dist/mcp-server/tools/audit/query.d.ts.map +1 -0
- package/dist/mcp-server/tools/audit/query.js +125 -0
- package/dist/mcp-server/tools/audit/query.js.map +1 -0
- package/dist/mcp-server/tools/audit/sync.d.ts +58 -0
- package/dist/mcp-server/tools/audit/sync.d.ts.map +1 -0
- package/dist/mcp-server/tools/audit/sync.js +126 -0
- package/dist/mcp-server/tools/audit/sync.js.map +1 -0
- package/dist/mcp-server/tools/index.d.ts +3 -0
- package/dist/mcp-server/tools/index.d.ts.map +1 -1
- package/dist/mcp-server/tools/registry.js +90 -0
- package/dist/mcp-server/tools/registry.js.map +1 -1
- package/dist/mcp-server/tools/vector/index.d.ts +12 -0
- package/dist/mcp-server/tools/vector/index.d.ts.map +1 -0
- package/dist/mcp-server/tools/vector/index.js +12 -0
- package/dist/mcp-server/tools/vector/index.js.map +1 -0
- package/dist/mcp-server/tools/vector/search.d.ts +41 -0
- package/dist/mcp-server/tools/vector/search.d.ts.map +1 -0
- package/dist/mcp-server/tools/vector/search.js +224 -0
- package/dist/mcp-server/tools/vector/search.js.map +1 -0
- package/dist/mcp-server/tools/vector/trajectory.d.ts +39 -0
- package/dist/mcp-server/tools/vector/trajectory.d.ts.map +1 -0
- package/dist/mcp-server/tools/vector/trajectory.js +170 -0
- package/dist/mcp-server/tools/vector/trajectory.js.map +1 -0
- package/dist/mcp-server/tools/vector/upsert.d.ts +44 -0
- package/dist/mcp-server/tools/vector/upsert.d.ts.map +1 -0
- package/dist/mcp-server/tools/vector/upsert.js +175 -0
- package/dist/mcp-server/tools/vector/upsert.js.map +1 -0
- package/dist/mcp-server/tools/workflow/index.d.ts +29 -0
- package/dist/mcp-server/tools/workflow/index.d.ts.map +1 -0
- package/dist/mcp-server/tools/workflow/index.js +12 -0
- package/dist/mcp-server/tools/workflow/index.js.map +1 -0
- package/dist/mcp-server/tools/workflow/list.d.ts +41 -0
- package/dist/mcp-server/tools/workflow/list.d.ts.map +1 -0
- package/dist/mcp-server/tools/workflow/list.js +195 -0
- package/dist/mcp-server/tools/workflow/list.js.map +1 -0
- package/dist/mcp-server/tools/workflow/start.d.ts +40 -0
- package/dist/mcp-server/tools/workflow/start.d.ts.map +1 -0
- package/dist/mcp-server/tools/workflow/start.js +165 -0
- package/dist/mcp-server/tools/workflow/start.js.map +1 -0
- package/dist/mcp-server/tools/workflow/status.d.ts +38 -0
- package/dist/mcp-server/tools/workflow/status.d.ts.map +1 -0
- package/dist/mcp-server/tools/workflow/status.js +97 -0
- package/dist/mcp-server/tools/workflow/status.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/create.js +31 -0
- package/dist/node_modules/@envelop/core/esm/create.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/document-string-map.js +5 -0
- package/dist/node_modules/@envelop/core/esm/document-string-map.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/orchestrator.js +407 -0
- package/dist/node_modules/@envelop/core/esm/orchestrator.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/plugins/use-engine.js +29 -0
- package/dist/node_modules/@envelop/core/esm/plugins/use-engine.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/plugins/use-extend-context.js +10 -0
- package/dist/node_modules/@envelop/core/esm/plugins/use-extend-context.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/plugins/use-masked-errors.js +86 -0
- package/dist/node_modules/@envelop/core/esm/plugins/use-masked-errors.js.map +1 -0
- package/dist/node_modules/@envelop/core/esm/utils.js +129 -0
- package/dist/node_modules/@envelop/core/esm/utils.js.map +1 -0
- package/dist/node_modules/@envelop/instrumentation/esm/instrumentation.js +51 -0
- package/dist/node_modules/@envelop/instrumentation/esm/instrumentation.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/coerceError.js +26 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/coerceError.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/execute.js +1101 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/execute.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/flattenAsyncIterable.js +72 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/flattenAsyncIterable.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/invariant.js +9 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/invariant.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/normalizedExecutor.js +22 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/normalizedExecutor.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/promiseForObject.js +26 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/promiseForObject.js.map +1 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/values.js +73 -0
- package/dist/node_modules/@graphql-tools/executor/esm/execution/values.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/extensions.js +46 -0
- package/dist/node_modules/@graphql-tools/merge/esm/extensions.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/links.js +142 -0
- package/dist/node_modules/@graphql-tools/merge/esm/links.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/merge-resolvers.js +27 -0
- package/dist/node_modules/@graphql-tools/merge/esm/merge-resolvers.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/arguments.js +23 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/arguments.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/directives.js +113 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/directives.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/enum-values.js +39 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/enum-values.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/enum.js +23 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/enum.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/fields.js +74 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/fields.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/input-type.js +27 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/input-type.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/interface.js +29 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/interface.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/merge-named-type-array.js +15 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/merge-named-type-array.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/merge-nodes.js +81 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/merge-nodes.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/merge-typedefs.js +142 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/merge-typedefs.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/scalar.js +21 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/scalar.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/schema-def.js +36 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/schema-def.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/type.js +29 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/type.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/union.js +24 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/union.js.map +1 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/utils.js +67 -0
- package/dist/node_modules/@graphql-tools/merge/esm/typedefs-mergers/utils.js.map +1 -0
- package/dist/node_modules/@graphql-tools/schema/esm/addResolversToSchema.js +287 -0
- package/dist/node_modules/@graphql-tools/schema/esm/addResolversToSchema.js.map +1 -0
- package/dist/node_modules/@graphql-tools/schema/esm/assertResolversPresent.js +42 -0
- package/dist/node_modules/@graphql-tools/schema/esm/assertResolversPresent.js.map +1 -0
- package/dist/node_modules/@graphql-tools/schema/esm/checkForResolveTypeResolver.js +22 -0
- package/dist/node_modules/@graphql-tools/schema/esm/checkForResolveTypeResolver.js.map +1 -0
- package/dist/node_modules/@graphql-tools/schema/esm/extendResolversFromInterfaces.js +34 -0
- package/dist/node_modules/@graphql-tools/schema/esm/extendResolversFromInterfaces.js.map +1 -0
- package/dist/node_modules/@graphql-tools/schema/esm/makeExecutableSchema.js +50 -0
- package/dist/node_modules/@graphql-tools/schema/esm/makeExecutableSchema.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/AccumulatorMap.js +17 -0
- package/dist/node_modules/@graphql-tools/utils/esm/AccumulatorMap.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/Interfaces.js +32 -0
- package/dist/node_modules/@graphql-tools/utils/esm/Interfaces.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/Path.js +21 -0
- package/dist/node_modules/@graphql-tools/utils/esm/Path.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/astFromType.js +31 -0
- package/dist/node_modules/@graphql-tools/utils/esm/astFromType.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/astFromValue.js +70 -0
- package/dist/node_modules/@graphql-tools/utils/esm/astFromValue.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/astFromValueUntyped.js +56 -0
- package/dist/node_modules/@graphql-tools/utils/esm/astFromValueUntyped.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/collectFields.js +137 -0
- package/dist/node_modules/@graphql-tools/utils/esm/collectFields.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/comments.js +337 -0
- package/dist/node_modules/@graphql-tools/utils/esm/comments.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/descriptionFromObject.js +20 -0
- package/dist/node_modules/@graphql-tools/utils/esm/descriptionFromObject.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/directives.js +46 -0
- package/dist/node_modules/@graphql-tools/utils/esm/directives.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/errors.js +52 -0
- package/dist/node_modules/@graphql-tools/utils/esm/errors.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/forEachDefaultValue.js +28 -0
- package/dist/node_modules/@graphql-tools/utils/esm/forEachDefaultValue.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/forEachField.js +18 -0
- package/dist/node_modules/@graphql-tools/utils/esm/forEachField.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/get-directives.js +12 -0
- package/dist/node_modules/@graphql-tools/utils/esm/get-directives.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/getArgumentValues.js +61 -0
- package/dist/node_modules/@graphql-tools/utils/esm/getArgumentValues.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/getDirectiveExtensions.js +76 -0
- package/dist/node_modules/@graphql-tools/utils/esm/getDirectiveExtensions.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/getObjectTypeFromTypeMap.js +13 -0
- package/dist/node_modules/@graphql-tools/utils/esm/getObjectTypeFromTypeMap.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/heal.js +120 -0
- package/dist/node_modules/@graphql-tools/utils/esm/heal.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/helpers.js +42 -0
- package/dist/node_modules/@graphql-tools/utils/esm/helpers.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/isAsyncIterable.js +7 -0
- package/dist/node_modules/@graphql-tools/utils/esm/isAsyncIterable.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/isDocumentNode.js +8 -0
- package/dist/node_modules/@graphql-tools/utils/esm/isDocumentNode.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/jsutils.js +26 -0
- package/dist/node_modules/@graphql-tools/utils/esm/jsutils.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/mapSchema.js +439 -0
- package/dist/node_modules/@graphql-tools/utils/esm/mapSchema.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/memoize.js +104 -0
- package/dist/node_modules/@graphql-tools/utils/esm/memoize.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/mergeDeep.js +86 -0
- package/dist/node_modules/@graphql-tools/utils/esm/mergeDeep.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/print-schema-with-directives.js +370 -0
- package/dist/node_modules/@graphql-tools/utils/esm/print-schema-with-directives.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/rewire.js +155 -0
- package/dist/node_modules/@graphql-tools/utils/esm/rewire.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/rootTypes.js +33 -0
- package/dist/node_modules/@graphql-tools/utils/esm/rootTypes.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/stub.js +32 -0
- package/dist/node_modules/@graphql-tools/utils/esm/stub.js.map +1 -0
- package/dist/node_modules/@graphql-tools/utils/esm/transformInputValue.js +47 -0
- package/dist/node_modules/@graphql-tools/utils/esm/transformInputValue.js.map +1 -0
- package/dist/node_modules/@graphql-yoga/logger/esm/index.js +42 -0
- package/dist/node_modules/@graphql-yoga/logger/esm/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/project-service/dist/createProjectService.js +126 -0
- package/dist/node_modules/@typescript-eslint/project-service/dist/createProjectService.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/project-service/dist/getParsedConfigFileFromTSServer.js +25 -0
- package/dist/node_modules/@typescript-eslint/project-service/dist/getParsedConfigFileFromTSServer.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/project-service/dist/index.js +32 -0
- package/dist/node_modules/@typescript-eslint/project-service/dist/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/tsconfig-utils/dist/compilerOptions.js +20 -0
- package/dist/node_modules/@typescript-eslint/tsconfig-utils/dist/compilerOptions.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/tsconfig-utils/dist/getParsedConfigFile.js +87 -0
- package/dist/node_modules/@typescript-eslint/tsconfig-utils/dist/getParsedConfigFile.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/tsconfig-utils/dist/index.js +34 -0
- package/dist/node_modules/@typescript-eslint/tsconfig-utils/dist/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js +201 -0
- package/dist/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/types/dist/index.js +45 -0
- package/dist/node_modules/@typescript-eslint/types/dist/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/types/dist/lib.js +12 -0
- package/dist/node_modules/@typescript-eslint/types/dist/lib.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/types/dist/parser-options.js +12 -0
- package/dist/node_modules/@typescript-eslint/types/dist/parser-options.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/types/dist/ts-estree.js +52 -0
- package/dist/node_modules/@typescript-eslint/types/dist/ts-estree.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ast-converter.js +54 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ast-converter.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/check-modifiers.js +207 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/check-modifiers.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.js +34 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/convert-comments.js +81 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/convert-comments.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/convert.js +2438 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/convert.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createIsolatedProgram.js +117 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createIsolatedProgram.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.js +33 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgramError.js +82 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgramError.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createSourceFile.js +84 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createSourceFile.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.js +31 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getScriptKind.js +90 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getScriptKind.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.js +292 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js +134 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/useProvidedPrograms.js +91 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/useProvidedPrograms.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/validateDefaultProjectForFilesGlob.js +35 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/create-program/validateDefaultProjectForFilesGlob.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/createParserServices.js +39 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/createParserServices.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/getModifiers.js +88 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/getModifiers.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/index.js +90 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/jsx/xhtml-entities.js +268 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/jsx/xhtml-entities.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/node-utils.js +533 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/node-utils.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.js +50 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/candidateTSConfigRootDirs.js +38 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/candidateTSConfigRootDirs.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.js +216 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.js +87 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/inferSingleRun.js +53 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/inferSingleRun.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.js +89 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/warnAboutTSVersion.js +92 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/warnAboutTSVersion.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parser.js +132 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/parser.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/semantic-or-syntactic-errors.js +124 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/semantic-or-syntactic-errors.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/simple-traverse.js +64 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/simple-traverse.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/source-files.js +63 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/source-files.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/estree-to-ts-node-types.js +12 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/estree-to-ts-node-types.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/index.js +46 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/ts-nodes.js +12 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/ts-nodes.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/useProgramFromProjectService.js +205 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/useProgramFromProjectService.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/version-check.js +75 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/version-check.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/version.js +15 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/version.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/withoutProjectParserOptions.js +17 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/dist/withoutProjectParserOptions.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/assert-valid-pattern.js +23 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/assert-valid-pattern.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/ast.js +495 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/ast.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/brace-expressions.js +121 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/brace-expressions.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/escape.js +17 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/escape.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/index.js +763 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/unescape.js +17 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/node_modules/minimatch/dist/commonjs/unescape.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/package.json.js +9 -0
- package/dist/node_modules/@typescript-eslint/typescript-estree/package.json.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/visitor-keys/dist/get-keys.js +16 -0
- package/dist/node_modules/@typescript-eslint/visitor-keys/dist/get-keys.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/visitor-keys/dist/index.js +25 -0
- package/dist/node_modules/@typescript-eslint/visitor-keys/dist/index.js.map +1 -0
- package/dist/node_modules/@typescript-eslint/visitor-keys/dist/visitor-keys.js +187 -0
- package/dist/node_modules/@typescript-eslint/visitor-keys/dist/visitor-keys.js.map +1 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/AsyncDisposableStack.js +72 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/AsyncDisposableStack.js.map +1 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/SupressedError.js +16 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/SupressedError.js.map +1 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/index.js +6 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/index.js.map +1 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/symbols.js +12 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/symbols.js.map +1 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/utils.js +12 -0
- package/dist/node_modules/@whatwg-node/disposablestack/esm/utils.js.map +1 -0
- package/dist/node_modules/@whatwg-node/fetch/dist/global-ponyfill.js +33 -0
- package/dist/node_modules/@whatwg-node/fetch/dist/global-ponyfill.js.map +1 -0
- package/dist/node_modules/@whatwg-node/promise-helpers/esm/index.js +241 -0
- package/dist/node_modules/@whatwg-node/promise-helpers/esm/index.js.map +1 -0
- package/dist/node_modules/@whatwg-node/server/esm/createServerAdapter.js +333 -0
- package/dist/node_modules/@whatwg-node/server/esm/createServerAdapter.js.map +1 -0
- package/dist/node_modules/@whatwg-node/server/esm/plugins/useCors.js +106 -0
- package/dist/node_modules/@whatwg-node/server/esm/plugins/useCors.js.map +1 -0
- package/dist/node_modules/@whatwg-node/server/esm/utils.js +476 -0
- package/dist/node_modules/@whatwg-node/server/esm/utils.js.map +1 -0
- package/dist/node_modules/@whatwg-node/server/esm/uwebsockets.js +232 -0
- package/dist/node_modules/@whatwg-node/server/esm/uwebsockets.js.map +1 -0
- package/dist/node_modules/balanced-match/index.js +62 -0
- package/dist/node_modules/balanced-match/index.js.map +1 -0
- package/dist/node_modules/brace-expansion/index.js +156 -0
- package/dist/node_modules/brace-expansion/index.js.map +1 -0
- package/dist/node_modules/cross-inspect/esm/index.js +89 -0
- package/dist/node_modules/cross-inspect/esm/index.js.map +1 -0
- package/dist/node_modules/debug/src/browser.js +178 -0
- package/dist/node_modules/debug/src/browser.js.map +1 -0
- package/dist/node_modules/debug/src/common.js +183 -0
- package/dist/node_modules/debug/src/common.js.map +1 -0
- package/dist/node_modules/eslint-visitor-keys/dist/eslint-visitor-keys.js +353 -0
- package/dist/node_modules/eslint-visitor-keys/dist/eslint-visitor-keys.js.map +1 -0
- package/dist/node_modules/fdir/dist/index.js +540 -0
- package/dist/node_modules/fdir/dist/index.js.map +1 -0
- package/dist/node_modules/graphql/error/GraphQLError.js +154 -0
- package/dist/node_modules/graphql/error/GraphQLError.js.map +1 -0
- package/dist/node_modules/graphql/error/locatedError.js +23 -0
- package/dist/node_modules/graphql/error/locatedError.js.map +1 -0
- package/dist/node_modules/graphql/error/syntaxError.js +11 -0
- package/dist/node_modules/graphql/error/syntaxError.js.map +1 -0
- package/dist/node_modules/graphql/execution/collectFields.js +128 -0
- package/dist/node_modules/graphql/execution/collectFields.js.map +1 -0
- package/dist/node_modules/graphql/execution/execute.js +606 -0
- package/dist/node_modules/graphql/execution/execute.js.map +1 -0
- package/dist/node_modules/graphql/execution/mapAsyncIterator.js +46 -0
- package/dist/node_modules/graphql/execution/mapAsyncIterator.js.map +1 -0
- package/dist/node_modules/graphql/execution/subscribe.js +121 -0
- package/dist/node_modules/graphql/execution/subscribe.js.map +1 -0
- package/dist/node_modules/graphql/execution/values.js +184 -0
- package/dist/node_modules/graphql/execution/values.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/Path.js +21 -0
- package/dist/node_modules/graphql/jsutils/Path.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/devAssert.js +10 -0
- package/dist/node_modules/graphql/jsutils/devAssert.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/didYouMean.js +24 -0
- package/dist/node_modules/graphql/jsutils/didYouMean.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/groupBy.js +17 -0
- package/dist/node_modules/graphql/jsutils/groupBy.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/identityFunc.js +7 -0
- package/dist/node_modules/graphql/jsutils/identityFunc.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/inspect.js +85 -0
- package/dist/node_modules/graphql/jsutils/inspect.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/instanceOf.js +42 -0
- package/dist/node_modules/graphql/jsutils/instanceOf.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/invariant.js +12 -0
- package/dist/node_modules/graphql/jsutils/invariant.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/isAsyncIterable.js +7 -0
- package/dist/node_modules/graphql/jsutils/isAsyncIterable.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/isIterableObject.js +7 -0
- package/dist/node_modules/graphql/jsutils/isIterableObject.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/isObjectLike.js +7 -0
- package/dist/node_modules/graphql/jsutils/isObjectLike.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/isPromise.js +7 -0
- package/dist/node_modules/graphql/jsutils/isPromise.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/keyMap.js +11 -0
- package/dist/node_modules/graphql/jsutils/keyMap.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/keyValMap.js +11 -0
- package/dist/node_modules/graphql/jsutils/keyValMap.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/mapValue.js +11 -0
- package/dist/node_modules/graphql/jsutils/mapValue.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/memoize3.js +28 -0
- package/dist/node_modules/graphql/jsutils/memoize3.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/naturalCompare.js +47 -0
- package/dist/node_modules/graphql/jsutils/naturalCompare.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/printPathArray.js +9 -0
- package/dist/node_modules/graphql/jsutils/printPathArray.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/promiseForObject.js +13 -0
- package/dist/node_modules/graphql/jsutils/promiseForObject.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/promiseReduce.js +12 -0
- package/dist/node_modules/graphql/jsutils/promiseReduce.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/suggestionList.js +94 -0
- package/dist/node_modules/graphql/jsutils/suggestionList.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/toError.js +15 -0
- package/dist/node_modules/graphql/jsutils/toError.js.map +1 -0
- package/dist/node_modules/graphql/jsutils/toObjMap.js +17 -0
- package/dist/node_modules/graphql/jsutils/toObjMap.js.map +1 -0
- package/dist/node_modules/graphql/language/ast.js +189 -0
- package/dist/node_modules/graphql/language/ast.js.map +1 -0
- package/dist/node_modules/graphql/language/blockString.js +60 -0
- package/dist/node_modules/graphql/language/blockString.js.map +1 -0
- package/dist/node_modules/graphql/language/characterClasses.js +24 -0
- package/dist/node_modules/graphql/language/characterClasses.js.map +1 -0
- package/dist/node_modules/graphql/language/directiveLocation.js +26 -0
- package/dist/node_modules/graphql/language/directiveLocation.js.map +1 -0
- package/dist/node_modules/graphql/language/kinds.js +55 -0
- package/dist/node_modules/graphql/language/kinds.js.map +1 -0
- package/dist/node_modules/graphql/language/lexer.js +543 -0
- package/dist/node_modules/graphql/language/lexer.js.map +1 -0
- package/dist/node_modules/graphql/language/location.js +22 -0
- package/dist/node_modules/graphql/language/location.js.map +1 -0
- package/dist/node_modules/graphql/language/parser.js +1343 -0
- package/dist/node_modules/graphql/language/parser.js.map +1 -0
- package/dist/node_modules/graphql/language/predicates.js +28 -0
- package/dist/node_modules/graphql/language/predicates.js.map +1 -0
- package/dist/node_modules/graphql/language/printLocation.js +51 -0
- package/dist/node_modules/graphql/language/printLocation.js.map +1 -0
- package/dist/node_modules/graphql/language/printString.js +178 -0
- package/dist/node_modules/graphql/language/printString.js.map +1 -0
- package/dist/node_modules/graphql/language/printer.js +269 -0
- package/dist/node_modules/graphql/language/printer.js.map +1 -0
- package/dist/node_modules/graphql/language/source.js +33 -0
- package/dist/node_modules/graphql/language/source.js.map +1 -0
- package/dist/node_modules/graphql/language/tokenKind.js +30 -0
- package/dist/node_modules/graphql/language/tokenKind.js.map +1 -0
- package/dist/node_modules/graphql/language/visitor.js +192 -0
- package/dist/node_modules/graphql/language/visitor.js.map +1 -0
- package/dist/node_modules/graphql/type/assertName.js +34 -0
- package/dist/node_modules/graphql/type/assertName.js.map +1 -0
- package/dist/node_modules/graphql/type/definition.js +648 -0
- package/dist/node_modules/graphql/type/definition.js.map +1 -0
- package/dist/node_modules/graphql/type/directives.js +137 -0
- package/dist/node_modules/graphql/type/directives.js.map +1 -0
- package/dist/node_modules/graphql/type/introspection.js +506 -0
- package/dist/node_modules/graphql/type/introspection.js.map +1 -0
- package/dist/node_modules/graphql/type/scalars.js +248 -0
- package/dist/node_modules/graphql/type/scalars.js.map +1 -0
- package/dist/node_modules/graphql/type/schema.js +223 -0
- package/dist/node_modules/graphql/type/schema.js.map +1 -0
- package/dist/node_modules/graphql/type/validate.js +461 -0
- package/dist/node_modules/graphql/type/validate.js.map +1 -0
- package/dist/node_modules/graphql/utilities/TypeInfo.js +257 -0
- package/dist/node_modules/graphql/utilities/TypeInfo.js.map +1 -0
- package/dist/node_modules/graphql/utilities/astFromValue.js +111 -0
- package/dist/node_modules/graphql/utilities/astFromValue.js.map +1 -0
- package/dist/node_modules/graphql/utilities/buildASTSchema.js +65 -0
- package/dist/node_modules/graphql/utilities/buildASTSchema.js.map +1 -0
- package/dist/node_modules/graphql/utilities/coerceInputValue.js +154 -0
- package/dist/node_modules/graphql/utilities/coerceInputValue.js.map +1 -0
- package/dist/node_modules/graphql/utilities/extendSchema.js +456 -0
- package/dist/node_modules/graphql/utilities/extendSchema.js.map +1 -0
- package/dist/node_modules/graphql/utilities/getOperationAST.js +22 -0
- package/dist/node_modules/graphql/utilities/getOperationAST.js.map +1 -0
- package/dist/node_modules/graphql/utilities/sortValueNode.js +30 -0
- package/dist/node_modules/graphql/utilities/sortValueNode.js.map +1 -0
- package/dist/node_modules/graphql/utilities/typeComparators.js +58 -0
- package/dist/node_modules/graphql/utilities/typeComparators.js.map +1 -0
- package/dist/node_modules/graphql/utilities/typeFromAST.js +20 -0
- package/dist/node_modules/graphql/utilities/typeFromAST.js.map +1 -0
- package/dist/node_modules/graphql/utilities/valueFromAST.js +109 -0
- package/dist/node_modules/graphql/utilities/valueFromAST.js.map +1 -0
- package/dist/node_modules/graphql/utilities/valueFromASTUntyped.js +32 -0
- package/dist/node_modules/graphql/utilities/valueFromASTUntyped.js.map +1 -0
- package/dist/node_modules/graphql/validation/ValidationContext.js +171 -0
- package/dist/node_modules/graphql/validation/ValidationContext.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/ExecutableDefinitionsRule.js +24 -0
- package/dist/node_modules/graphql/validation/rules/ExecutableDefinitionsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/FieldsOnCorrectTypeRule.js +80 -0
- package/dist/node_modules/graphql/validation/rules/FieldsOnCorrectTypeRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/FragmentsOnCompositeTypesRule.js +43 -0
- package/dist/node_modules/graphql/validation/rules/FragmentsOnCompositeTypesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/KnownArgumentNamesRule.js +73 -0
- package/dist/node_modules/graphql/validation/rules/KnownArgumentNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/KnownDirectivesRule.js +112 -0
- package/dist/node_modules/graphql/validation/rules/KnownDirectivesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/KnownFragmentNamesRule.js +20 -0
- package/dist/node_modules/graphql/validation/rules/KnownFragmentNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/KnownTypeNamesRule.js +55 -0
- package/dist/node_modules/graphql/validation/rules/KnownTypeNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/LoneAnonymousOperationRule.js +28 -0
- package/dist/node_modules/graphql/validation/rules/LoneAnonymousOperationRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/LoneSchemaDefinitionRule.js +34 -0
- package/dist/node_modules/graphql/validation/rules/LoneSchemaDefinitionRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/MaxIntrospectionDepthRule.js +56 -0
- package/dist/node_modules/graphql/validation/rules/MaxIntrospectionDepthRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/NoFragmentCyclesRule.js +53 -0
- package/dist/node_modules/graphql/validation/rules/NoFragmentCyclesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/NoUndefinedVariablesRule.js +34 -0
- package/dist/node_modules/graphql/validation/rules/NoUndefinedVariablesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/NoUnusedFragmentsRule.js +41 -0
- package/dist/node_modules/graphql/validation/rules/NoUnusedFragmentsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/NoUnusedVariablesRule.js +38 -0
- package/dist/node_modules/graphql/validation/rules/NoUnusedVariablesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/OverlappingFieldsCanBeMergedRule.js +519 -0
- package/dist/node_modules/graphql/validation/rules/OverlappingFieldsCanBeMergedRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/PossibleFragmentSpreadsRule.js +55 -0
- package/dist/node_modules/graphql/validation/rules/PossibleFragmentSpreadsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/PossibleTypeExtensionsRule.js +113 -0
- package/dist/node_modules/graphql/validation/rules/PossibleTypeExtensionsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/ProvidedRequiredArgumentsRule.js +99 -0
- package/dist/node_modules/graphql/validation/rules/ProvidedRequiredArgumentsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/ScalarLeafsRule.js +53 -0
- package/dist/node_modules/graphql/validation/rules/ScalarLeafsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/SingleFieldSubscriptionsRule.js +62 -0
- package/dist/node_modules/graphql/validation/rules/SingleFieldSubscriptionsRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueArgumentDefinitionNamesRule.js +47 -0
- package/dist/node_modules/graphql/validation/rules/UniqueArgumentDefinitionNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueArgumentNamesRule.js +29 -0
- package/dist/node_modules/graphql/validation/rules/UniqueArgumentNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueDirectiveNamesRule.js +38 -0
- package/dist/node_modules/graphql/validation/rules/UniqueDirectiveNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueDirectivesPerLocationRule.js +63 -0
- package/dist/node_modules/graphql/validation/rules/UniqueDirectivesPerLocationRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueEnumValueNamesRule.js +50 -0
- package/dist/node_modules/graphql/validation/rules/UniqueEnumValueNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueFieldDefinitionNamesRule.js +59 -0
- package/dist/node_modules/graphql/validation/rules/UniqueFieldDefinitionNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueFragmentNamesRule.js +27 -0
- package/dist/node_modules/graphql/validation/rules/UniqueFragmentNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueInputFieldNamesRule.js +38 -0
- package/dist/node_modules/graphql/validation/rules/UniqueInputFieldNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueOperationNamesRule.js +32 -0
- package/dist/node_modules/graphql/validation/rules/UniqueOperationNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueOperationTypesRule.js +48 -0
- package/dist/node_modules/graphql/validation/rules/UniqueOperationTypesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueTypeNamesRule.js +41 -0
- package/dist/node_modules/graphql/validation/rules/UniqueTypeNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/UniqueVariableNamesRule.js +30 -0
- package/dist/node_modules/graphql/validation/rules/UniqueVariableNamesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/ValuesOfCorrectTypeRule.js +170 -0
- package/dist/node_modules/graphql/validation/rules/ValuesOfCorrectTypeRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/VariablesAreInputTypesRule.js +27 -0
- package/dist/node_modules/graphql/validation/rules/VariablesAreInputTypesRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/rules/VariablesInAllowedPositionRule.js +74 -0
- package/dist/node_modules/graphql/validation/rules/VariablesInAllowedPositionRule.js.map +1 -0
- package/dist/node_modules/graphql/validation/specifiedRules.js +88 -0
- package/dist/node_modules/graphql/validation/specifiedRules.js.map +1 -0
- package/dist/node_modules/graphql/validation/validate.js +65 -0
- package/dist/node_modules/graphql/validation/validate.js.map +1 -0
- package/dist/node_modules/graphql/version.js +10 -0
- package/dist/node_modules/graphql/version.js.map +1 -0
- package/dist/node_modules/graphql-ws/lib/common.js +127 -0
- package/dist/node_modules/graphql-ws/lib/common.js.map +1 -0
- package/dist/node_modules/graphql-ws/lib/server.js +257 -0
- package/dist/node_modules/graphql-ws/lib/server.js.map +1 -0
- package/dist/node_modules/graphql-ws/lib/use/ws.js +83 -0
- package/dist/node_modules/graphql-ws/lib/use/ws.js.map +1 -0
- package/dist/node_modules/graphql-ws/lib/utils.js +35 -0
- package/dist/node_modules/graphql-ws/lib/utils.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/error.js +127 -0
- package/dist/node_modules/graphql-yoga/esm/error.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/graphiql-html.js +5 -0
- package/dist/node_modules/graphql-yoga/esm/graphiql-html.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/landing-page-html.js +21 -0
- package/dist/node_modules/graphql-yoga/esm/landing-page-html.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/allowed-headers.js +26 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/allowed-headers.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/get.js +15 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/get.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-form-url-encoded.js +12 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-form-url-encoded.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-graphql-string.js +12 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-graphql-string.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-json.js +58 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-json.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-multipart.js +78 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/post-multipart.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/utils.js +28 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-parser/utils.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-check-graphql-query-params.js +131 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-check-graphql-query-params.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-check-method-for-graphql.js +28 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-check-method-for-graphql.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-http-validation-error.js +21 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-http-validation-error.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-limit-batching.js +37 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-limit-batching.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-prevent-mutation-via-get.js +61 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/request-validation/use-prevent-mutation-via-get.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/accept.js +28 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/accept.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/multipart.js +68 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/multipart.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/regular.js +29 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/regular.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/sse.js +83 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/sse.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/stringify.js +47 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/result-processor/stringify.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-graphiql.js +55 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-graphiql.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-health-check.js +20 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-health-check.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-parser-and-validation-cache.js +63 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-parser-and-validation-cache.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-request-parser.js +15 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-request-parser.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-result-processor.js +58 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-result-processor.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-schema.js +76 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-schema.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-unhandled-route.js +52 -0
- package/dist/node_modules/graphql-yoga/esm/plugins/use-unhandled-route.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/process-request.js +56 -0
- package/dist/node_modules/graphql-yoga/esm/process-request.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/server.js +374 -0
- package/dist/node_modules/graphql-yoga/esm/server.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/utils/create-lru-cache.js +10 -0
- package/dist/node_modules/graphql-yoga/esm/utils/create-lru-cache.js.map +1 -0
- package/dist/node_modules/graphql-yoga/esm/utils/mask-error.js +47 -0
- package/dist/node_modules/graphql-yoga/esm/utils/mask-error.js.map +1 -0
- package/dist/node_modules/graphql-yoga/node_modules/lru-cache/dist/esm/index.js +1370 -0
- package/dist/node_modules/graphql-yoga/node_modules/lru-cache/dist/esm/index.js.map +1 -0
- package/dist/node_modules/ms/index.js +121 -0
- package/dist/node_modules/ms/index.js.map +1 -0
- package/dist/node_modules/picomatch/index.js +23 -0
- package/dist/node_modules/picomatch/index.js.map +1 -0
- package/dist/node_modules/picomatch/lib/constants.js +203 -0
- package/dist/node_modules/picomatch/lib/constants.js.map +1 -0
- package/dist/node_modules/picomatch/lib/parse.js +774 -0
- package/dist/node_modules/picomatch/lib/parse.js.map +1 -0
- package/dist/node_modules/picomatch/lib/picomatch.js +148 -0
- package/dist/node_modules/picomatch/lib/picomatch.js.map +1 -0
- package/dist/node_modules/picomatch/lib/scan.js +336 -0
- package/dist/node_modules/picomatch/lib/scan.js.map +1 -0
- package/dist/node_modules/picomatch/lib/utils.js +71 -0
- package/dist/node_modules/picomatch/lib/utils.js.map +1 -0
- package/dist/node_modules/semver/classes/comparator.js +123 -0
- package/dist/node_modules/semver/classes/comparator.js.map +1 -0
- package/dist/node_modules/semver/classes/range.js +388 -0
- package/dist/node_modules/semver/classes/range.js.map +1 -0
- package/dist/node_modules/semver/classes/semver.js +288 -0
- package/dist/node_modules/semver/classes/semver.js.map +1 -0
- package/dist/node_modules/semver/functions/clean.js +18 -0
- package/dist/node_modules/semver/functions/clean.js.map +1 -0
- package/dist/node_modules/semver/functions/cmp.js +60 -0
- package/dist/node_modules/semver/functions/cmp.js.map +1 -0
- package/dist/node_modules/semver/functions/coerce.js +53 -0
- package/dist/node_modules/semver/functions/coerce.js.map +1 -0
- package/dist/node_modules/semver/functions/compare-build.js +19 -0
- package/dist/node_modules/semver/functions/compare-build.js.map +1 -0
- package/dist/node_modules/semver/functions/compare-loose.js +15 -0
- package/dist/node_modules/semver/functions/compare-loose.js.map +1 -0
- package/dist/node_modules/semver/functions/compare.js +15 -0
- package/dist/node_modules/semver/functions/compare.js.map +1 -0
- package/dist/node_modules/semver/functions/diff.js +49 -0
- package/dist/node_modules/semver/functions/diff.js.map +1 -0
- package/dist/node_modules/semver/functions/eq.js +15 -0
- package/dist/node_modules/semver/functions/eq.js.map +1 -0
- package/dist/node_modules/semver/functions/gt.js +15 -0
- package/dist/node_modules/semver/functions/gt.js.map +1 -0
- package/dist/node_modules/semver/functions/gte.js +15 -0
- package/dist/node_modules/semver/functions/gte.js.map +1 -0
- package/dist/node_modules/semver/functions/inc.js +29 -0
- package/dist/node_modules/semver/functions/inc.js.map +1 -0
- package/dist/node_modules/semver/functions/lt.js +15 -0
- package/dist/node_modules/semver/functions/lt.js.map +1 -0
- package/dist/node_modules/semver/functions/lte.js +15 -0
- package/dist/node_modules/semver/functions/lte.js.map +1 -0
- package/dist/node_modules/semver/functions/major.js +15 -0
- package/dist/node_modules/semver/functions/major.js.map +1 -0
- package/dist/node_modules/semver/functions/minor.js +15 -0
- package/dist/node_modules/semver/functions/minor.js.map +1 -0
- package/dist/node_modules/semver/functions/neq.js +15 -0
- package/dist/node_modules/semver/functions/neq.js.map +1 -0
- package/dist/node_modules/semver/functions/parse.js +27 -0
- package/dist/node_modules/semver/functions/parse.js.map +1 -0
- package/dist/node_modules/semver/functions/patch.js +15 -0
- package/dist/node_modules/semver/functions/patch.js.map +1 -0
- package/dist/node_modules/semver/functions/prerelease.js +18 -0
- package/dist/node_modules/semver/functions/prerelease.js.map +1 -0
- package/dist/node_modules/semver/functions/rcompare.js +15 -0
- package/dist/node_modules/semver/functions/rcompare.js.map +1 -0
- package/dist/node_modules/semver/functions/rsort.js +15 -0
- package/dist/node_modules/semver/functions/rsort.js.map +1 -0
- package/dist/node_modules/semver/functions/satisfies.js +22 -0
- package/dist/node_modules/semver/functions/satisfies.js.map +1 -0
- package/dist/node_modules/semver/functions/sort.js +15 -0
- package/dist/node_modules/semver/functions/sort.js.map +1 -0
- package/dist/node_modules/semver/functions/valid.js +18 -0
- package/dist/node_modules/semver/functions/valid.js.map +1 -0
- package/dist/node_modules/semver/index.js +140 -0
- package/dist/node_modules/semver/index.js.map +1 -0
- package/dist/node_modules/semver/internal/constants.js +36 -0
- package/dist/node_modules/semver/internal/constants.js.map +1 -0
- package/dist/node_modules/semver/internal/debug.js +14 -0
- package/dist/node_modules/semver/internal/debug.js.map +1 -0
- package/dist/node_modules/semver/internal/identifiers.js +29 -0
- package/dist/node_modules/semver/internal/identifiers.js.map +1 -0
- package/dist/node_modules/semver/internal/lrucache.js +42 -0
- package/dist/node_modules/semver/internal/lrucache.js.map +1 -0
- package/dist/node_modules/semver/internal/parse-options.js +23 -0
- package/dist/node_modules/semver/internal/parse-options.js.map +1 -0
- package/dist/node_modules/semver/internal/re.js +96 -0
- package/dist/node_modules/semver/internal/re.js.map +1 -0
- package/dist/node_modules/semver/ranges/gtr.js +15 -0
- package/dist/node_modules/semver/ranges/gtr.js.map +1 -0
- package/dist/node_modules/semver/ranges/intersects.js +19 -0
- package/dist/node_modules/semver/ranges/intersects.js.map +1 -0
- package/dist/node_modules/semver/ranges/ltr.js +15 -0
- package/dist/node_modules/semver/ranges/ltr.js.map +1 -0
- package/dist/node_modules/semver/ranges/max-satisfying.js +35 -0
- package/dist/node_modules/semver/ranges/max-satisfying.js.map +1 -0
- package/dist/node_modules/semver/ranges/min-satisfying.js +35 -0
- package/dist/node_modules/semver/ranges/min-satisfying.js.map +1 -0
- package/dist/node_modules/semver/ranges/min-version.js +66 -0
- package/dist/node_modules/semver/ranges/min-version.js.map +1 -0
- package/dist/node_modules/semver/ranges/outside.js +81 -0
- package/dist/node_modules/semver/ranges/outside.js.map +1 -0
- package/dist/node_modules/semver/ranges/simplify.js +56 -0
- package/dist/node_modules/semver/ranges/simplify.js.map +1 -0
- package/dist/node_modules/semver/ranges/subset.js +170 -0
- package/dist/node_modules/semver/ranges/subset.js.map +1 -0
- package/dist/node_modules/semver/ranges/to-comparators.js +15 -0
- package/dist/node_modules/semver/ranges/to-comparators.js.map +1 -0
- package/dist/node_modules/semver/ranges/valid.js +21 -0
- package/dist/node_modules/semver/ranges/valid.js.map +1 -0
- package/dist/node_modules/tinyglobby/dist/index.js +332 -0
- package/dist/node_modules/tinyglobby/dist/index.js.map +1 -0
- package/dist/node_modules/ts-api-utils/lib/index.js +2361 -0
- package/dist/node_modules/ts-api-utils/lib/index.js.map +1 -0
- package/dist/node_modules/typescript/lib/tsserverlibrary.js +33 -0
- package/dist/node_modules/typescript/lib/tsserverlibrary.js.map +1 -0
- package/dist/node_modules/typescript/lib/typescript.js +210602 -0
- package/dist/node_modules/typescript/lib/typescript.js.map +1 -0
- package/dist/node_modules/ws/browser.js +16 -0
- package/dist/node_modules/ws/browser.js.map +1 -0
- package/dist/plugins/analyzers/code-complexity/analyzer.d.ts +105 -0
- package/dist/plugins/analyzers/code-complexity/analyzer.d.ts.map +1 -0
- package/dist/plugins/analyzers/code-complexity/analyzer.js +507 -0
- package/dist/plugins/analyzers/code-complexity/analyzer.js.map +1 -0
- package/dist/plugins/analyzers/code-complexity/graph-generator.d.ts +70 -0
- package/dist/plugins/analyzers/code-complexity/graph-generator.d.ts.map +1 -0
- package/dist/plugins/analyzers/code-complexity/graph-generator.js +405 -0
- package/dist/plugins/analyzers/code-complexity/graph-generator.js.map +1 -0
- package/dist/plugins/analyzers/code-complexity/index.d.ts +191 -0
- package/dist/plugins/analyzers/code-complexity/index.d.ts.map +1 -0
- package/dist/plugins/analyzers/code-complexity/index.js +276 -0
- package/dist/plugins/analyzers/code-complexity/index.js.map +1 -0
- package/dist/plugins/analyzers/code-complexity/metrics.d.ts +77 -0
- package/dist/plugins/analyzers/code-complexity/metrics.d.ts.map +1 -0
- package/dist/plugins/analyzers/code-complexity/metrics.js +514 -0
- package/dist/plugins/analyzers/code-complexity/metrics.js.map +1 -0
- package/dist/plugins/analyzers/code-complexity/plugin.d.ts +161 -0
- package/dist/plugins/analyzers/code-complexity/plugin.d.ts.map +1 -0
- package/dist/plugins/analyzers/code-complexity/plugin.js +661 -0
- package/dist/plugins/analyzers/code-complexity/plugin.js.map +1 -0
- package/dist/plugins/analyzers/code-complexity/types.d.ts +360 -0
- package/dist/plugins/analyzers/code-complexity/types.d.ts.map +1 -0
- package/dist/plugins/analyzers/code-complexity/types.js +27 -0
- package/dist/plugins/analyzers/code-complexity/types.js.map +1 -0
- package/dist/plugins/analyzers/dependency-health/analyzer.d.ts +56 -0
- package/dist/plugins/analyzers/dependency-health/analyzer.d.ts.map +1 -0
- package/dist/plugins/analyzers/dependency-health/analyzer.js +387 -0
- package/dist/plugins/analyzers/dependency-health/analyzer.js.map +1 -0
- package/dist/plugins/analyzers/dependency-health/graph-generator.d.ts +60 -0
- package/dist/plugins/analyzers/dependency-health/graph-generator.d.ts.map +1 -0
- package/dist/plugins/analyzers/dependency-health/graph-generator.js +295 -0
- package/dist/plugins/analyzers/dependency-health/graph-generator.js.map +1 -0
- package/dist/plugins/analyzers/dependency-health/index.d.ts +201 -0
- package/dist/plugins/analyzers/dependency-health/index.d.ts.map +1 -0
- package/dist/plugins/analyzers/dependency-health/index.js +857 -0
- package/dist/plugins/analyzers/dependency-health/index.js.map +1 -0
- package/dist/plugins/analyzers/dependency-health/npm-client.d.ts +68 -0
- package/dist/plugins/analyzers/dependency-health/npm-client.d.ts.map +1 -0
- package/dist/plugins/analyzers/dependency-health/npm-client.js +226 -0
- package/dist/plugins/analyzers/dependency-health/npm-client.js.map +1 -0
- package/dist/plugins/analyzers/dependency-health/types.d.ts +462 -0
- package/dist/plugins/analyzers/dependency-health/types.d.ts.map +1 -0
- package/dist/plugins/analyzers/dependency-health/vulnerability.d.ts +80 -0
- package/dist/plugins/analyzers/dependency-health/vulnerability.d.ts.map +1 -0
- package/dist/plugins/analyzers/dependency-health/vulnerability.js +215 -0
- package/dist/plugins/analyzers/dependency-health/vulnerability.js.map +1 -0
- package/dist/plugins/analyzers/index.d.ts +12 -0
- package/dist/plugins/analyzers/index.d.ts.map +1 -0
- package/dist/plugins/index.d.ts +13 -0
- package/dist/plugins/index.d.ts.map +1 -0
- package/dist/plugins/loader.d.ts +158 -0
- package/dist/plugins/loader.d.ts.map +1 -0
- package/dist/plugins/loader.js +554 -0
- package/dist/plugins/loader.js.map +1 -0
- package/dist/plugins/manager.d.ts +183 -0
- package/dist/plugins/manager.d.ts.map +1 -0
- package/dist/plugins/manager.js +876 -0
- package/dist/plugins/manager.js.map +1 -0
- package/dist/plugins/registry.d.ts +163 -0
- package/dist/plugins/registry.d.ts.map +1 -0
- package/dist/plugins/registry.js +448 -0
- package/dist/plugins/registry.js.map +1 -0
- package/dist/plugins/types.d.ts +930 -0
- package/dist/plugins/types.d.ts.map +1 -0
- package/dist/plugins/types.js +43 -0
- package/dist/plugins/types.js.map +1 -0
- package/dist/server/container.d.ts +263 -0
- package/dist/server/container.d.ts.map +1 -0
- package/dist/server/container.js +605 -0
- package/dist/server/container.js.map +1 -0
- package/dist/server/event-bus.d.ts +418 -0
- package/dist/server/event-bus.d.ts.map +1 -0
- package/dist/server/event-bus.js +442 -0
- package/dist/server/event-bus.js.map +1 -0
- package/dist/server/index.d.ts +37 -0
- package/dist/server/index.d.ts.map +1 -0
- package/dist/server/manager.d.ts +123 -0
- package/dist/server/manager.d.ts.map +1 -0
- package/dist/server/manager.js +742 -0
- package/dist/server/manager.js.map +1 -0
- package/dist/server/shared-services.d.ts +130 -0
- package/dist/server/shared-services.d.ts.map +1 -0
- package/dist/server/shared-services.js +476 -0
- package/dist/server/shared-services.js.map +1 -0
- package/dist/server/types.d.ts +320 -0
- package/dist/server/types.d.ts.map +1 -0
- package/dist/server/types.js +13 -0
- package/dist/server/types.js.map +1 -0
- package/dist/services/manager.js +328 -0
- package/dist/services/manager.js.map +1 -0
- package/dist/vector/config.d.ts +300 -0
- package/dist/vector/config.d.ts.map +1 -0
- package/dist/vector/config.js +124 -0
- package/dist/vector/config.js.map +1 -0
- package/dist/vector/index.d.ts +50 -0
- package/dist/vector/index.d.ts.map +1 -0
- package/dist/vector/services/index.d.ts +13 -0
- package/dist/vector/services/index.d.ts.map +1 -0
- package/dist/vector/services/trajectory-tracker.d.ts +405 -0
- package/dist/vector/services/trajectory-tracker.d.ts.map +1 -0
- package/dist/vector/services/trajectory-tracker.js +445 -0
- package/dist/vector/services/trajectory-tracker.js.map +1 -0
- package/dist/vector/services/vector-store.d.ts +339 -0
- package/dist/vector/services/vector-store.d.ts.map +1 -0
- package/dist/vector/services/vector-store.js +748 -0
- package/dist/vector/services/vector-store.js.map +1 -0
- package/dist/vector/types.d.ts +677 -0
- package/dist/vector/types.d.ts.map +1 -0
- package/dist/workflow/adapters/goap-adapter.d.ts +196 -0
- package/dist/workflow/adapters/goap-adapter.d.ts.map +1 -0
- package/dist/workflow/adapters/goap-adapter.js +706 -0
- package/dist/workflow/adapters/goap-adapter.js.map +1 -0
- package/dist/workflow/adapters/index.d.ts +10 -0
- package/dist/workflow/adapters/index.d.ts.map +1 -0
- package/dist/workflow/config.d.ts +135 -0
- package/dist/workflow/config.d.ts.map +1 -0
- package/dist/workflow/config.js +92 -0
- package/dist/workflow/config.js.map +1 -0
- package/dist/workflow/handlers/index.d.ts +9 -0
- package/dist/workflow/handlers/index.d.ts.map +1 -0
- package/dist/workflow/handlers/webhook-handlers.d.ts +397 -0
- package/dist/workflow/handlers/webhook-handlers.d.ts.map +1 -0
- package/dist/workflow/handlers/webhook-handlers.js +454 -0
- package/dist/workflow/handlers/webhook-handlers.js.map +1 -0
- package/dist/workflow/index.d.ts +42 -0
- package/dist/workflow/index.d.ts.map +1 -0
- package/dist/workflow/services/index.d.ts +9 -0
- package/dist/workflow/services/index.d.ts.map +1 -0
- package/dist/workflow/services/workflow-service.d.ts +318 -0
- package/dist/workflow/services/workflow-service.d.ts.map +1 -0
- package/dist/workflow/services/workflow-service.js +577 -0
- package/dist/workflow/services/workflow-service.js.map +1 -0
- package/dist/workflow/types.d.ts +470 -0
- package/dist/workflow/types.d.ts.map +1 -0
- package/dist/workflow/workflows/realtime-collab.d.ts +245 -0
- package/dist/workflow/workflows/realtime-collab.d.ts.map +1 -0
- package/package.json +29 -3
- package/dist/_virtual/additionalItems.js +0 -5
- package/dist/_virtual/additionalItems.js.map +0 -1
- package/dist/_virtual/additionalProperties.js +0 -5
- package/dist/_virtual/additionalProperties.js.map +0 -1
- package/dist/_virtual/ajv.js +0 -6
- package/dist/_virtual/ajv.js.map +0 -1
- package/dist/_virtual/ajv2.js +0 -5
- package/dist/_virtual/ajv2.js.map +0 -1
- package/dist/_virtual/allOf.js +0 -5
- package/dist/_virtual/allOf.js.map +0 -1
- package/dist/_virtual/anyOf.js +0 -5
- package/dist/_virtual/anyOf.js.map +0 -1
- package/dist/_virtual/applicability.js +0 -5
- package/dist/_virtual/applicability.js.map +0 -1
- package/dist/_virtual/boolSchema.js +0 -5
- package/dist/_virtual/boolSchema.js.map +0 -1
- package/dist/_virtual/code.js +0 -5
- package/dist/_virtual/code.js.map +0 -1
- package/dist/_virtual/code2.js +0 -5
- package/dist/_virtual/code2.js.map +0 -1
- package/dist/_virtual/const.js +0 -5
- package/dist/_virtual/const.js.map +0 -1
- package/dist/_virtual/contains.js +0 -5
- package/dist/_virtual/contains.js.map +0 -1
- package/dist/_virtual/core.js +0 -5
- package/dist/_virtual/core.js.map +0 -1
- package/dist/_virtual/dataType.js +0 -5
- package/dist/_virtual/dataType.js.map +0 -1
- package/dist/_virtual/defaults.js +0 -5
- package/dist/_virtual/defaults.js.map +0 -1
- package/dist/_virtual/dependencies.js +0 -5
- package/dist/_virtual/dependencies.js.map +0 -1
- package/dist/_virtual/draft7.js +0 -5
- package/dist/_virtual/draft7.js.map +0 -1
- package/dist/_virtual/enum.js +0 -5
- package/dist/_virtual/enum.js.map +0 -1
- package/dist/_virtual/equal.js +0 -5
- package/dist/_virtual/equal.js.map +0 -1
- package/dist/_virtual/errors.js +0 -5
- package/dist/_virtual/errors.js.map +0 -1
- package/dist/_virtual/format.js +0 -5
- package/dist/_virtual/format.js.map +0 -1
- package/dist/_virtual/formats.js +0 -5
- package/dist/_virtual/formats.js.map +0 -1
- package/dist/_virtual/id.js +0 -5
- package/dist/_virtual/id.js.map +0 -1
- package/dist/_virtual/if.js +0 -5
- package/dist/_virtual/if.js.map +0 -1
- package/dist/_virtual/index12.js +0 -5
- package/dist/_virtual/index12.js.map +0 -1
- package/dist/_virtual/items.js +0 -5
- package/dist/_virtual/items.js.map +0 -1
- package/dist/_virtual/items2020.js +0 -5
- package/dist/_virtual/items2020.js.map +0 -1
- package/dist/_virtual/keyword.js +0 -5
- package/dist/_virtual/keyword.js.map +0 -1
- package/dist/_virtual/limit.js +0 -5
- package/dist/_virtual/limit.js.map +0 -1
- package/dist/_virtual/limitItems.js +0 -5
- package/dist/_virtual/limitItems.js.map +0 -1
- package/dist/_virtual/limitLength.js +0 -5
- package/dist/_virtual/limitLength.js.map +0 -1
- package/dist/_virtual/limitNumber.js +0 -5
- package/dist/_virtual/limitNumber.js.map +0 -1
- package/dist/_virtual/limitProperties.js +0 -5
- package/dist/_virtual/limitProperties.js.map +0 -1
- package/dist/_virtual/metadata.js +0 -5
- package/dist/_virtual/metadata.js.map +0 -1
- package/dist/_virtual/multipleOf.js +0 -5
- package/dist/_virtual/multipleOf.js.map +0 -1
- package/dist/_virtual/names.js +0 -5
- package/dist/_virtual/names.js.map +0 -1
- package/dist/_virtual/not.js +0 -5
- package/dist/_virtual/not.js.map +0 -1
- package/dist/_virtual/oneOf.js +0 -5
- package/dist/_virtual/oneOf.js.map +0 -1
- package/dist/_virtual/pattern.js +0 -5
- package/dist/_virtual/pattern.js.map +0 -1
- package/dist/_virtual/patternProperties.js +0 -5
- package/dist/_virtual/patternProperties.js.map +0 -1
- package/dist/_virtual/prefixItems.js +0 -5
- package/dist/_virtual/prefixItems.js.map +0 -1
- package/dist/_virtual/properties.js +0 -5
- package/dist/_virtual/properties.js.map +0 -1
- package/dist/_virtual/propertyNames.js +0 -5
- package/dist/_virtual/propertyNames.js.map +0 -1
- package/dist/_virtual/ref.js +0 -5
- package/dist/_virtual/ref.js.map +0 -1
- package/dist/_virtual/ref_error.js +0 -5
- package/dist/_virtual/ref_error.js.map +0 -1
- package/dist/_virtual/required.js +0 -5
- package/dist/_virtual/required.js.map +0 -1
- package/dist/_virtual/resolve.js +0 -5
- package/dist/_virtual/resolve.js.map +0 -1
- package/dist/_virtual/rules.js +0 -5
- package/dist/_virtual/rules.js.map +0 -1
- package/dist/_virtual/scope.js +0 -5
- package/dist/_virtual/scope.js.map +0 -1
- package/dist/_virtual/subschema.js +0 -5
- package/dist/_virtual/subschema.js.map +0 -1
- package/dist/_virtual/thenElse.js +0 -5
- package/dist/_virtual/thenElse.js.map +0 -1
- package/dist/_virtual/types.js +0 -5
- package/dist/_virtual/types.js.map +0 -1
- package/dist/_virtual/ucs2length.js +0 -5
- package/dist/_virtual/ucs2length.js.map +0 -1
- package/dist/_virtual/uniqueItems.js +0 -5
- package/dist/_virtual/uniqueItems.js.map +0 -1
- package/dist/_virtual/uri.js +0 -5
- package/dist/_virtual/uri.js.map +0 -1
- package/dist/_virtual/util.js +0 -5
- package/dist/_virtual/util.js.map +0 -1
- package/dist/_virtual/validation_error.js +0 -5
- package/dist/_virtual/validation_error.js.map +0 -1
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/index.js +0 -296
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/index.js.map +0 -1
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-compat.js +0 -71
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-compat.js.map +0 -1
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-json-schema-compat.js +0 -26
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/server/zod-json-schema-compat.js.map +0 -1
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/shared/protocol.js +0 -407
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/shared/protocol.js.map +0 -1
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/types.js +0 -1332
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/types.js.map +0 -1
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/validation/ajv-provider.js +0 -71
- package/dist/node_modules/@modelcontextprotocol/sdk/dist/esm/validation/ajv-provider.js.map +0 -1
- package/dist/node_modules/ajv/dist/ajv.js +0 -84
- package/dist/node_modules/ajv/dist/ajv.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/codegen/code.js +0 -160
- package/dist/node_modules/ajv/dist/compile/codegen/code.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/codegen/index.js +0 -728
- package/dist/node_modules/ajv/dist/compile/codegen/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/codegen/scope.js +0 -152
- package/dist/node_modules/ajv/dist/compile/codegen/scope.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/errors.js +0 -131
- package/dist/node_modules/ajv/dist/compile/errors.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/index.js +0 -234
- package/dist/node_modules/ajv/dist/compile/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/names.js +0 -44
- package/dist/node_modules/ajv/dist/compile/names.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/ref_error.js +0 -22
- package/dist/node_modules/ajv/dist/compile/ref_error.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/resolve.js +0 -163
- package/dist/node_modules/ajv/dist/compile/resolve.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/rules.js +0 -35
- package/dist/node_modules/ajv/dist/compile/rules.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/util.js +0 -173
- package/dist/node_modules/ajv/dist/compile/util.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/applicability.js +0 -27
- package/dist/node_modules/ajv/dist/compile/validate/applicability.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/boolSchema.js +0 -58
- package/dist/node_modules/ajv/dist/compile/validate/boolSchema.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/dataType.js +0 -193
- package/dist/node_modules/ajv/dist/compile/validate/dataType.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/defaults.js +0 -43
- package/dist/node_modules/ajv/dist/compile/validate/defaults.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/index.js +0 -522
- package/dist/node_modules/ajv/dist/compile/validate/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/keyword.js +0 -126
- package/dist/node_modules/ajv/dist/compile/validate/keyword.js.map +0 -1
- package/dist/node_modules/ajv/dist/compile/validate/subschema.js +0 -89
- package/dist/node_modules/ajv/dist/compile/validate/subschema.js.map +0 -1
- package/dist/node_modules/ajv/dist/core.js +0 -628
- package/dist/node_modules/ajv/dist/core.js.map +0 -1
- package/dist/node_modules/ajv/dist/refs/data.json.js +0 -24
- package/dist/node_modules/ajv/dist/refs/data.json.js.map +0 -1
- package/dist/node_modules/ajv/dist/refs/json-schema-draft-07.json.js +0 -25
- package/dist/node_modules/ajv/dist/refs/json-schema-draft-07.json.js.map +0 -1
- package/dist/node_modules/ajv/dist/runtime/equal.js +0 -16
- package/dist/node_modules/ajv/dist/runtime/equal.js.map +0 -1
- package/dist/node_modules/ajv/dist/runtime/ucs2length.js +0 -30
- package/dist/node_modules/ajv/dist/runtime/ucs2length.js.map +0 -1
- package/dist/node_modules/ajv/dist/runtime/uri.js +0 -16
- package/dist/node_modules/ajv/dist/runtime/uri.js.map +0 -1
- package/dist/node_modules/ajv/dist/runtime/validation_error.js +0 -20
- package/dist/node_modules/ajv/dist/runtime/validation_error.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js +0 -59
- package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js +0 -114
- package/dist/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/allOf.js +0 -32
- package/dist/node_modules/ajv/dist/vocabularies/applicator/allOf.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/anyOf.js +0 -22
- package/dist/node_modules/ajv/dist/vocabularies/applicator/anyOf.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/contains.js +0 -100
- package/dist/node_modules/ajv/dist/vocabularies/applicator/contains.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/dependencies.js +0 -103
- package/dist/node_modules/ajv/dist/vocabularies/applicator/dependencies.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/if.js +0 -75
- package/dist/node_modules/ajv/dist/vocabularies/applicator/if.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/index.js +0 -68
- package/dist/node_modules/ajv/dist/vocabularies/applicator/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/items.js +0 -64
- package/dist/node_modules/ajv/dist/vocabularies/applicator/items.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/items2020.js +0 -43
- package/dist/node_modules/ajv/dist/vocabularies/applicator/items2020.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/not.js +0 -36
- package/dist/node_modules/ajv/dist/vocabularies/applicator/not.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/oneOf.js +0 -64
- package/dist/node_modules/ajv/dist/vocabularies/applicator/oneOf.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js +0 -81
- package/dist/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js +0 -22
- package/dist/node_modules/ajv/dist/vocabularies/applicator/prefixItems.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/properties.js +0 -66
- package/dist/node_modules/ajv/dist/vocabularies/applicator/properties.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js +0 -49
- package/dist/node_modules/ajv/dist/vocabularies/applicator/propertyNames.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/applicator/thenElse.js +0 -23
- package/dist/node_modules/ajv/dist/vocabularies/applicator/thenElse.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/code.js +0 -140
- package/dist/node_modules/ajv/dist/vocabularies/code.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/core/id.js +0 -19
- package/dist/node_modules/ajv/dist/vocabularies/core/id.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/core/index.js +0 -27
- package/dist/node_modules/ajv/dist/vocabularies/core/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/core/ref.js +0 -132
- package/dist/node_modules/ajv/dist/vocabularies/core/ref.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/discriminator/index.js +0 -114
- package/dist/node_modules/ajv/dist/vocabularies/discriminator/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/discriminator/types.js +0 -18
- package/dist/node_modules/ajv/dist/vocabularies/discriminator/types.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/draft7.js +0 -31
- package/dist/node_modules/ajv/dist/vocabularies/draft7.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/format/format.js +0 -95
- package/dist/node_modules/ajv/dist/vocabularies/format/format.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/format/index.js +0 -16
- package/dist/node_modules/ajv/dist/vocabularies/format/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/metadata.js +0 -27
- package/dist/node_modules/ajv/dist/vocabularies/metadata.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/const.js +0 -36
- package/dist/node_modules/ajv/dist/vocabularies/validation/const.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/enum.js +0 -56
- package/dist/node_modules/ajv/dist/vocabularies/validation/enum.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/index.js +0 -52
- package/dist/node_modules/ajv/dist/vocabularies/validation/index.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitItems.js +0 -34
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitItems.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitLength.js +0 -39
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitLength.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitNumber.js +0 -37
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitNumber.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitProperties.js +0 -34
- package/dist/node_modules/ajv/dist/vocabularies/validation/limitProperties.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/multipleOf.js +0 -33
- package/dist/node_modules/ajv/dist/vocabularies/validation/multipleOf.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/pattern.js +0 -34
- package/dist/node_modules/ajv/dist/vocabularies/validation/pattern.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/required.js +0 -89
- package/dist/node_modules/ajv/dist/vocabularies/validation/required.js.map +0 -1
- package/dist/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js +0 -75
- package/dist/node_modules/ajv/dist/vocabularies/validation/uniqueItems.js.map +0 -1
- package/dist/node_modules/ajv-formats/dist/formats.js +0 -209
- package/dist/node_modules/ajv-formats/dist/formats.js.map +0 -1
- package/dist/node_modules/ajv-formats/dist/index.js +0 -51
- package/dist/node_modules/ajv-formats/dist/index.js.map +0 -1
- package/dist/node_modules/ajv-formats/dist/limit.js +0 -80
- package/dist/node_modules/ajv-formats/dist/limit.js.map +0 -1
- package/dist/node_modules/fast-deep-equal/index.js +0 -39
- package/dist/node_modules/fast-deep-equal/index.js.map +0 -1
- package/dist/node_modules/fast-uri/index.js +0 -261
- package/dist/node_modules/fast-uri/index.js.map +0 -1
- package/dist/node_modules/fast-uri/lib/schemes.js +0 -215
- package/dist/node_modules/fast-uri/lib/schemes.js.map +0 -1
- package/dist/node_modules/fast-uri/lib/utils.js +0 -261
- package/dist/node_modules/fast-uri/lib/utils.js.map +0 -1
- package/dist/node_modules/json-schema-traverse/index.js +0 -92
- package/dist/node_modules/json-schema-traverse/index.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/errors.js +0 -37
- package/dist/node_modules/zod/v4/classic/errors.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/iso.js +0 -43
- package/dist/node_modules/zod/v4/classic/iso.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/parse.js +0 -13
- package/dist/node_modules/zod/v4/classic/parse.js.map +0 -1
- package/dist/node_modules/zod/v4/classic/schemas.js +0 -688
- package/dist/node_modules/zod/v4/classic/schemas.js.map +0 -1
- package/dist/node_modules/zod/v4/core/api.js +0 -492
- package/dist/node_modules/zod/v4/core/api.js.map +0 -1
- package/dist/node_modules/zod/v4/core/checks.js +0 -405
- package/dist/node_modules/zod/v4/core/checks.js.map +0 -1
- package/dist/node_modules/zod/v4/core/core.js +0 -58
- package/dist/node_modules/zod/v4/core/core.js.map +0 -1
- package/dist/node_modules/zod/v4/core/doc.js +0 -38
- package/dist/node_modules/zod/v4/core/doc.js.map +0 -1
- package/dist/node_modules/zod/v4/core/errors.js +0 -82
- package/dist/node_modules/zod/v4/core/errors.js.map +0 -1
- package/dist/node_modules/zod/v4/core/parse.js +0 -60
- package/dist/node_modules/zod/v4/core/parse.js.map +0 -1
- package/dist/node_modules/zod/v4/core/regexes.js +0 -87
- package/dist/node_modules/zod/v4/core/regexes.js.map +0 -1
- package/dist/node_modules/zod/v4/core/registries.js +0 -52
- package/dist/node_modules/zod/v4/core/registries.js.map +0 -1
- package/dist/node_modules/zod/v4/core/schemas.js +0 -1283
- package/dist/node_modules/zod/v4/core/schemas.js.map +0 -1
- package/dist/node_modules/zod/v4/core/util.js +0 -341
- package/dist/node_modules/zod/v4/core/util.js.map +0 -1
- package/dist/node_modules/zod/v4/core/versions.js +0 -9
- package/dist/node_modules/zod/v4/core/versions.js.map +0 -1
- package/dist/node_modules/zod-to-json-schema/dist/esm/parsers/string.js +0 -2
- package/dist/node_modules/zod-to-json-schema/dist/esm/parsers/string.js.map +0 -1
|
@@ -0,0 +1,1370 @@
|
|
|
1
|
+
const perf = typeof performance === "object" && performance && typeof performance.now === "function" ? performance : Date;
|
|
2
|
+
const warned = /* @__PURE__ */ new Set();
|
|
3
|
+
const PROCESS = typeof process === "object" && !!process ? process : {};
|
|
4
|
+
const emitWarning = (msg, type, code, fn) => {
|
|
5
|
+
typeof PROCESS.emitWarning === "function" ? PROCESS.emitWarning(msg, type, code, fn) : console.error(`[${code}] ${type}: ${msg}`);
|
|
6
|
+
};
|
|
7
|
+
let AC = globalThis.AbortController;
|
|
8
|
+
let AS = globalThis.AbortSignal;
|
|
9
|
+
if (typeof AC === "undefined") {
|
|
10
|
+
AS = class AbortSignal {
|
|
11
|
+
onabort;
|
|
12
|
+
_onabort = [];
|
|
13
|
+
reason;
|
|
14
|
+
aborted = false;
|
|
15
|
+
addEventListener(_, fn) {
|
|
16
|
+
this._onabort.push(fn);
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
AC = class AbortController {
|
|
20
|
+
constructor() {
|
|
21
|
+
warnACPolyfill();
|
|
22
|
+
}
|
|
23
|
+
signal = new AS();
|
|
24
|
+
abort(reason) {
|
|
25
|
+
if (this.signal.aborted)
|
|
26
|
+
return;
|
|
27
|
+
this.signal.reason = reason;
|
|
28
|
+
this.signal.aborted = true;
|
|
29
|
+
for (const fn of this.signal._onabort) {
|
|
30
|
+
fn(reason);
|
|
31
|
+
}
|
|
32
|
+
this.signal.onabort?.(reason);
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
let printACPolyfillWarning = PROCESS.env?.LRU_CACHE_IGNORE_AC_WARNING !== "1";
|
|
36
|
+
const warnACPolyfill = () => {
|
|
37
|
+
if (!printACPolyfillWarning)
|
|
38
|
+
return;
|
|
39
|
+
printACPolyfillWarning = false;
|
|
40
|
+
emitWarning("AbortController is not defined. If using lru-cache in node 14, load an AbortController polyfill from the `node-abort-controller` package. A minimal polyfill is provided for use by LRUCache.fetch(), but it should not be relied upon in other contexts (eg, passing it to other APIs that use AbortController/AbortSignal might have undesirable effects). You may disable this with LRU_CACHE_IGNORE_AC_WARNING=1 in the env.", "NO_ABORT_CONTROLLER", "ENOTSUP", warnACPolyfill);
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
const shouldWarn = (code) => !warned.has(code);
|
|
44
|
+
const isPosInt = (n) => n && n === Math.floor(n) && n > 0 && isFinite(n);
|
|
45
|
+
const getUintArray = (max) => !isPosInt(max) ? null : max <= Math.pow(2, 8) ? Uint8Array : max <= Math.pow(2, 16) ? Uint16Array : max <= Math.pow(2, 32) ? Uint32Array : max <= Number.MAX_SAFE_INTEGER ? ZeroArray : null;
|
|
46
|
+
class ZeroArray extends Array {
|
|
47
|
+
constructor(size) {
|
|
48
|
+
super(size);
|
|
49
|
+
this.fill(0);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
class Stack {
|
|
53
|
+
heap;
|
|
54
|
+
length;
|
|
55
|
+
// private constructor
|
|
56
|
+
static #constructing = false;
|
|
57
|
+
static create(max) {
|
|
58
|
+
const HeapCls = getUintArray(max);
|
|
59
|
+
if (!HeapCls)
|
|
60
|
+
return [];
|
|
61
|
+
Stack.#constructing = true;
|
|
62
|
+
const s = new Stack(max, HeapCls);
|
|
63
|
+
Stack.#constructing = false;
|
|
64
|
+
return s;
|
|
65
|
+
}
|
|
66
|
+
constructor(max, HeapCls) {
|
|
67
|
+
if (!Stack.#constructing) {
|
|
68
|
+
throw new TypeError("instantiate Stack using Stack.create(n)");
|
|
69
|
+
}
|
|
70
|
+
this.heap = new HeapCls(max);
|
|
71
|
+
this.length = 0;
|
|
72
|
+
}
|
|
73
|
+
push(n) {
|
|
74
|
+
this.heap[this.length++] = n;
|
|
75
|
+
}
|
|
76
|
+
pop() {
|
|
77
|
+
return this.heap[--this.length];
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
class LRUCache {
|
|
81
|
+
// options that cannot be changed without disaster
|
|
82
|
+
#max;
|
|
83
|
+
#maxSize;
|
|
84
|
+
#dispose;
|
|
85
|
+
#disposeAfter;
|
|
86
|
+
#fetchMethod;
|
|
87
|
+
#memoMethod;
|
|
88
|
+
/**
|
|
89
|
+
* {@link LRUCache.OptionsBase.ttl}
|
|
90
|
+
*/
|
|
91
|
+
ttl;
|
|
92
|
+
/**
|
|
93
|
+
* {@link LRUCache.OptionsBase.ttlResolution}
|
|
94
|
+
*/
|
|
95
|
+
ttlResolution;
|
|
96
|
+
/**
|
|
97
|
+
* {@link LRUCache.OptionsBase.ttlAutopurge}
|
|
98
|
+
*/
|
|
99
|
+
ttlAutopurge;
|
|
100
|
+
/**
|
|
101
|
+
* {@link LRUCache.OptionsBase.updateAgeOnGet}
|
|
102
|
+
*/
|
|
103
|
+
updateAgeOnGet;
|
|
104
|
+
/**
|
|
105
|
+
* {@link LRUCache.OptionsBase.updateAgeOnHas}
|
|
106
|
+
*/
|
|
107
|
+
updateAgeOnHas;
|
|
108
|
+
/**
|
|
109
|
+
* {@link LRUCache.OptionsBase.allowStale}
|
|
110
|
+
*/
|
|
111
|
+
allowStale;
|
|
112
|
+
/**
|
|
113
|
+
* {@link LRUCache.OptionsBase.noDisposeOnSet}
|
|
114
|
+
*/
|
|
115
|
+
noDisposeOnSet;
|
|
116
|
+
/**
|
|
117
|
+
* {@link LRUCache.OptionsBase.noUpdateTTL}
|
|
118
|
+
*/
|
|
119
|
+
noUpdateTTL;
|
|
120
|
+
/**
|
|
121
|
+
* {@link LRUCache.OptionsBase.maxEntrySize}
|
|
122
|
+
*/
|
|
123
|
+
maxEntrySize;
|
|
124
|
+
/**
|
|
125
|
+
* {@link LRUCache.OptionsBase.sizeCalculation}
|
|
126
|
+
*/
|
|
127
|
+
sizeCalculation;
|
|
128
|
+
/**
|
|
129
|
+
* {@link LRUCache.OptionsBase.noDeleteOnFetchRejection}
|
|
130
|
+
*/
|
|
131
|
+
noDeleteOnFetchRejection;
|
|
132
|
+
/**
|
|
133
|
+
* {@link LRUCache.OptionsBase.noDeleteOnStaleGet}
|
|
134
|
+
*/
|
|
135
|
+
noDeleteOnStaleGet;
|
|
136
|
+
/**
|
|
137
|
+
* {@link LRUCache.OptionsBase.allowStaleOnFetchAbort}
|
|
138
|
+
*/
|
|
139
|
+
allowStaleOnFetchAbort;
|
|
140
|
+
/**
|
|
141
|
+
* {@link LRUCache.OptionsBase.allowStaleOnFetchRejection}
|
|
142
|
+
*/
|
|
143
|
+
allowStaleOnFetchRejection;
|
|
144
|
+
/**
|
|
145
|
+
* {@link LRUCache.OptionsBase.ignoreFetchAbort}
|
|
146
|
+
*/
|
|
147
|
+
ignoreFetchAbort;
|
|
148
|
+
// computed properties
|
|
149
|
+
#size;
|
|
150
|
+
#calculatedSize;
|
|
151
|
+
#keyMap;
|
|
152
|
+
#keyList;
|
|
153
|
+
#valList;
|
|
154
|
+
#next;
|
|
155
|
+
#prev;
|
|
156
|
+
#head;
|
|
157
|
+
#tail;
|
|
158
|
+
#free;
|
|
159
|
+
#disposed;
|
|
160
|
+
#sizes;
|
|
161
|
+
#starts;
|
|
162
|
+
#ttls;
|
|
163
|
+
#hasDispose;
|
|
164
|
+
#hasFetchMethod;
|
|
165
|
+
#hasDisposeAfter;
|
|
166
|
+
/**
|
|
167
|
+
* Do not call this method unless you need to inspect the
|
|
168
|
+
* inner workings of the cache. If anything returned by this
|
|
169
|
+
* object is modified in any way, strange breakage may occur.
|
|
170
|
+
*
|
|
171
|
+
* These fields are private for a reason!
|
|
172
|
+
*
|
|
173
|
+
* @internal
|
|
174
|
+
*/
|
|
175
|
+
static unsafeExposeInternals(c) {
|
|
176
|
+
return {
|
|
177
|
+
// properties
|
|
178
|
+
starts: c.#starts,
|
|
179
|
+
ttls: c.#ttls,
|
|
180
|
+
sizes: c.#sizes,
|
|
181
|
+
keyMap: c.#keyMap,
|
|
182
|
+
keyList: c.#keyList,
|
|
183
|
+
valList: c.#valList,
|
|
184
|
+
next: c.#next,
|
|
185
|
+
prev: c.#prev,
|
|
186
|
+
get head() {
|
|
187
|
+
return c.#head;
|
|
188
|
+
},
|
|
189
|
+
get tail() {
|
|
190
|
+
return c.#tail;
|
|
191
|
+
},
|
|
192
|
+
free: c.#free,
|
|
193
|
+
// methods
|
|
194
|
+
isBackgroundFetch: (p) => c.#isBackgroundFetch(p),
|
|
195
|
+
backgroundFetch: (k, index, options, context) => c.#backgroundFetch(k, index, options, context),
|
|
196
|
+
moveToTail: (index) => c.#moveToTail(index),
|
|
197
|
+
indexes: (options) => c.#indexes(options),
|
|
198
|
+
rindexes: (options) => c.#rindexes(options),
|
|
199
|
+
isStale: (index) => c.#isStale(index)
|
|
200
|
+
};
|
|
201
|
+
}
|
|
202
|
+
// Protected read-only members
|
|
203
|
+
/**
|
|
204
|
+
* {@link LRUCache.OptionsBase.max} (read-only)
|
|
205
|
+
*/
|
|
206
|
+
get max() {
|
|
207
|
+
return this.#max;
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* {@link LRUCache.OptionsBase.maxSize} (read-only)
|
|
211
|
+
*/
|
|
212
|
+
get maxSize() {
|
|
213
|
+
return this.#maxSize;
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* The total computed size of items in the cache (read-only)
|
|
217
|
+
*/
|
|
218
|
+
get calculatedSize() {
|
|
219
|
+
return this.#calculatedSize;
|
|
220
|
+
}
|
|
221
|
+
/**
|
|
222
|
+
* The number of items stored in the cache (read-only)
|
|
223
|
+
*/
|
|
224
|
+
get size() {
|
|
225
|
+
return this.#size;
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* {@link LRUCache.OptionsBase.fetchMethod} (read-only)
|
|
229
|
+
*/
|
|
230
|
+
get fetchMethod() {
|
|
231
|
+
return this.#fetchMethod;
|
|
232
|
+
}
|
|
233
|
+
get memoMethod() {
|
|
234
|
+
return this.#memoMethod;
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* {@link LRUCache.OptionsBase.dispose} (read-only)
|
|
238
|
+
*/
|
|
239
|
+
get dispose() {
|
|
240
|
+
return this.#dispose;
|
|
241
|
+
}
|
|
242
|
+
/**
|
|
243
|
+
* {@link LRUCache.OptionsBase.disposeAfter} (read-only)
|
|
244
|
+
*/
|
|
245
|
+
get disposeAfter() {
|
|
246
|
+
return this.#disposeAfter;
|
|
247
|
+
}
|
|
248
|
+
constructor(options) {
|
|
249
|
+
const { max = 0, ttl, ttlResolution = 1, ttlAutopurge, updateAgeOnGet, updateAgeOnHas, allowStale, dispose, disposeAfter, noDisposeOnSet, noUpdateTTL, maxSize = 0, maxEntrySize = 0, sizeCalculation, fetchMethod, memoMethod, noDeleteOnFetchRejection, noDeleteOnStaleGet, allowStaleOnFetchRejection, allowStaleOnFetchAbort, ignoreFetchAbort } = options;
|
|
250
|
+
if (max !== 0 && !isPosInt(max)) {
|
|
251
|
+
throw new TypeError("max option must be a nonnegative integer");
|
|
252
|
+
}
|
|
253
|
+
const UintArray = max ? getUintArray(max) : Array;
|
|
254
|
+
if (!UintArray) {
|
|
255
|
+
throw new Error("invalid max value: " + max);
|
|
256
|
+
}
|
|
257
|
+
this.#max = max;
|
|
258
|
+
this.#maxSize = maxSize;
|
|
259
|
+
this.maxEntrySize = maxEntrySize || this.#maxSize;
|
|
260
|
+
this.sizeCalculation = sizeCalculation;
|
|
261
|
+
if (this.sizeCalculation) {
|
|
262
|
+
if (!this.#maxSize && !this.maxEntrySize) {
|
|
263
|
+
throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");
|
|
264
|
+
}
|
|
265
|
+
if (typeof this.sizeCalculation !== "function") {
|
|
266
|
+
throw new TypeError("sizeCalculation set to non-function");
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
if (memoMethod !== void 0 && typeof memoMethod !== "function") {
|
|
270
|
+
throw new TypeError("memoMethod must be a function if defined");
|
|
271
|
+
}
|
|
272
|
+
this.#memoMethod = memoMethod;
|
|
273
|
+
if (fetchMethod !== void 0 && typeof fetchMethod !== "function") {
|
|
274
|
+
throw new TypeError("fetchMethod must be a function if specified");
|
|
275
|
+
}
|
|
276
|
+
this.#fetchMethod = fetchMethod;
|
|
277
|
+
this.#hasFetchMethod = !!fetchMethod;
|
|
278
|
+
this.#keyMap = /* @__PURE__ */ new Map();
|
|
279
|
+
this.#keyList = new Array(max).fill(void 0);
|
|
280
|
+
this.#valList = new Array(max).fill(void 0);
|
|
281
|
+
this.#next = new UintArray(max);
|
|
282
|
+
this.#prev = new UintArray(max);
|
|
283
|
+
this.#head = 0;
|
|
284
|
+
this.#tail = 0;
|
|
285
|
+
this.#free = Stack.create(max);
|
|
286
|
+
this.#size = 0;
|
|
287
|
+
this.#calculatedSize = 0;
|
|
288
|
+
if (typeof dispose === "function") {
|
|
289
|
+
this.#dispose = dispose;
|
|
290
|
+
}
|
|
291
|
+
if (typeof disposeAfter === "function") {
|
|
292
|
+
this.#disposeAfter = disposeAfter;
|
|
293
|
+
this.#disposed = [];
|
|
294
|
+
} else {
|
|
295
|
+
this.#disposeAfter = void 0;
|
|
296
|
+
this.#disposed = void 0;
|
|
297
|
+
}
|
|
298
|
+
this.#hasDispose = !!this.#dispose;
|
|
299
|
+
this.#hasDisposeAfter = !!this.#disposeAfter;
|
|
300
|
+
this.noDisposeOnSet = !!noDisposeOnSet;
|
|
301
|
+
this.noUpdateTTL = !!noUpdateTTL;
|
|
302
|
+
this.noDeleteOnFetchRejection = !!noDeleteOnFetchRejection;
|
|
303
|
+
this.allowStaleOnFetchRejection = !!allowStaleOnFetchRejection;
|
|
304
|
+
this.allowStaleOnFetchAbort = !!allowStaleOnFetchAbort;
|
|
305
|
+
this.ignoreFetchAbort = !!ignoreFetchAbort;
|
|
306
|
+
if (this.maxEntrySize !== 0) {
|
|
307
|
+
if (this.#maxSize !== 0) {
|
|
308
|
+
if (!isPosInt(this.#maxSize)) {
|
|
309
|
+
throw new TypeError("maxSize must be a positive integer if specified");
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
if (!isPosInt(this.maxEntrySize)) {
|
|
313
|
+
throw new TypeError("maxEntrySize must be a positive integer if specified");
|
|
314
|
+
}
|
|
315
|
+
this.#initializeSizeTracking();
|
|
316
|
+
}
|
|
317
|
+
this.allowStale = !!allowStale;
|
|
318
|
+
this.noDeleteOnStaleGet = !!noDeleteOnStaleGet;
|
|
319
|
+
this.updateAgeOnGet = !!updateAgeOnGet;
|
|
320
|
+
this.updateAgeOnHas = !!updateAgeOnHas;
|
|
321
|
+
this.ttlResolution = isPosInt(ttlResolution) || ttlResolution === 0 ? ttlResolution : 1;
|
|
322
|
+
this.ttlAutopurge = !!ttlAutopurge;
|
|
323
|
+
this.ttl = ttl || 0;
|
|
324
|
+
if (this.ttl) {
|
|
325
|
+
if (!isPosInt(this.ttl)) {
|
|
326
|
+
throw new TypeError("ttl must be a positive integer if specified");
|
|
327
|
+
}
|
|
328
|
+
this.#initializeTTLTracking();
|
|
329
|
+
}
|
|
330
|
+
if (this.#max === 0 && this.ttl === 0 && this.#maxSize === 0) {
|
|
331
|
+
throw new TypeError("At least one of max, maxSize, or ttl is required");
|
|
332
|
+
}
|
|
333
|
+
if (!this.ttlAutopurge && !this.#max && !this.#maxSize) {
|
|
334
|
+
const code = "LRU_CACHE_UNBOUNDED";
|
|
335
|
+
if (shouldWarn(code)) {
|
|
336
|
+
warned.add(code);
|
|
337
|
+
const msg = "TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.";
|
|
338
|
+
emitWarning(msg, "UnboundedCacheWarning", code, LRUCache);
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
/**
|
|
343
|
+
* Return the number of ms left in the item's TTL. If item is not in cache,
|
|
344
|
+
* returns `0`. Returns `Infinity` if item is in cache without a defined TTL.
|
|
345
|
+
*/
|
|
346
|
+
getRemainingTTL(key) {
|
|
347
|
+
return this.#keyMap.has(key) ? Infinity : 0;
|
|
348
|
+
}
|
|
349
|
+
#initializeTTLTracking() {
|
|
350
|
+
const ttls = new ZeroArray(this.#max);
|
|
351
|
+
const starts = new ZeroArray(this.#max);
|
|
352
|
+
this.#ttls = ttls;
|
|
353
|
+
this.#starts = starts;
|
|
354
|
+
this.#setItemTTL = (index, ttl, start = perf.now()) => {
|
|
355
|
+
starts[index] = ttl !== 0 ? start : 0;
|
|
356
|
+
ttls[index] = ttl;
|
|
357
|
+
if (ttl !== 0 && this.ttlAutopurge) {
|
|
358
|
+
const t = setTimeout(() => {
|
|
359
|
+
if (this.#isStale(index)) {
|
|
360
|
+
this.#delete(this.#keyList[index], "expire");
|
|
361
|
+
}
|
|
362
|
+
}, ttl + 1);
|
|
363
|
+
if (t.unref) {
|
|
364
|
+
t.unref();
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
};
|
|
368
|
+
this.#updateItemAge = (index) => {
|
|
369
|
+
starts[index] = ttls[index] !== 0 ? perf.now() : 0;
|
|
370
|
+
};
|
|
371
|
+
this.#statusTTL = (status, index) => {
|
|
372
|
+
if (ttls[index]) {
|
|
373
|
+
const ttl = ttls[index];
|
|
374
|
+
const start = starts[index];
|
|
375
|
+
if (!ttl || !start)
|
|
376
|
+
return;
|
|
377
|
+
status.ttl = ttl;
|
|
378
|
+
status.start = start;
|
|
379
|
+
status.now = cachedNow || getNow();
|
|
380
|
+
const age = status.now - start;
|
|
381
|
+
status.remainingTTL = ttl - age;
|
|
382
|
+
}
|
|
383
|
+
};
|
|
384
|
+
let cachedNow = 0;
|
|
385
|
+
const getNow = () => {
|
|
386
|
+
const n = perf.now();
|
|
387
|
+
if (this.ttlResolution > 0) {
|
|
388
|
+
cachedNow = n;
|
|
389
|
+
const t = setTimeout(() => cachedNow = 0, this.ttlResolution);
|
|
390
|
+
if (t.unref) {
|
|
391
|
+
t.unref();
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
return n;
|
|
395
|
+
};
|
|
396
|
+
this.getRemainingTTL = (key) => {
|
|
397
|
+
const index = this.#keyMap.get(key);
|
|
398
|
+
if (index === void 0) {
|
|
399
|
+
return 0;
|
|
400
|
+
}
|
|
401
|
+
const ttl = ttls[index];
|
|
402
|
+
const start = starts[index];
|
|
403
|
+
if (!ttl || !start) {
|
|
404
|
+
return Infinity;
|
|
405
|
+
}
|
|
406
|
+
const age = (cachedNow || getNow()) - start;
|
|
407
|
+
return ttl - age;
|
|
408
|
+
};
|
|
409
|
+
this.#isStale = (index) => {
|
|
410
|
+
const s = starts[index];
|
|
411
|
+
const t = ttls[index];
|
|
412
|
+
return !!t && !!s && (cachedNow || getNow()) - s > t;
|
|
413
|
+
};
|
|
414
|
+
}
|
|
415
|
+
// conditionally set private methods related to TTL
|
|
416
|
+
#updateItemAge = () => {
|
|
417
|
+
};
|
|
418
|
+
#statusTTL = () => {
|
|
419
|
+
};
|
|
420
|
+
#setItemTTL = () => {
|
|
421
|
+
};
|
|
422
|
+
/* c8 ignore stop */
|
|
423
|
+
#isStale = () => false;
|
|
424
|
+
#initializeSizeTracking() {
|
|
425
|
+
const sizes = new ZeroArray(this.#max);
|
|
426
|
+
this.#calculatedSize = 0;
|
|
427
|
+
this.#sizes = sizes;
|
|
428
|
+
this.#removeItemSize = (index) => {
|
|
429
|
+
this.#calculatedSize -= sizes[index];
|
|
430
|
+
sizes[index] = 0;
|
|
431
|
+
};
|
|
432
|
+
this.#requireSize = (k, v, size, sizeCalculation) => {
|
|
433
|
+
if (this.#isBackgroundFetch(v)) {
|
|
434
|
+
return 0;
|
|
435
|
+
}
|
|
436
|
+
if (!isPosInt(size)) {
|
|
437
|
+
if (sizeCalculation) {
|
|
438
|
+
if (typeof sizeCalculation !== "function") {
|
|
439
|
+
throw new TypeError("sizeCalculation must be a function");
|
|
440
|
+
}
|
|
441
|
+
size = sizeCalculation(v, k);
|
|
442
|
+
if (!isPosInt(size)) {
|
|
443
|
+
throw new TypeError("sizeCalculation return invalid (expect positive integer)");
|
|
444
|
+
}
|
|
445
|
+
} else {
|
|
446
|
+
throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.");
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
return size;
|
|
450
|
+
};
|
|
451
|
+
this.#addItemSize = (index, size, status) => {
|
|
452
|
+
sizes[index] = size;
|
|
453
|
+
if (this.#maxSize) {
|
|
454
|
+
const maxSize = this.#maxSize - sizes[index];
|
|
455
|
+
while (this.#calculatedSize > maxSize) {
|
|
456
|
+
this.#evict(true);
|
|
457
|
+
}
|
|
458
|
+
}
|
|
459
|
+
this.#calculatedSize += sizes[index];
|
|
460
|
+
if (status) {
|
|
461
|
+
status.entrySize = size;
|
|
462
|
+
status.totalCalculatedSize = this.#calculatedSize;
|
|
463
|
+
}
|
|
464
|
+
};
|
|
465
|
+
}
|
|
466
|
+
#removeItemSize = (_i) => {
|
|
467
|
+
};
|
|
468
|
+
#addItemSize = (_i, _s, _st) => {
|
|
469
|
+
};
|
|
470
|
+
#requireSize = (_k, _v, size, sizeCalculation) => {
|
|
471
|
+
if (size || sizeCalculation) {
|
|
472
|
+
throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");
|
|
473
|
+
}
|
|
474
|
+
return 0;
|
|
475
|
+
};
|
|
476
|
+
*#indexes({ allowStale = this.allowStale } = {}) {
|
|
477
|
+
if (this.#size) {
|
|
478
|
+
for (let i = this.#tail; true; ) {
|
|
479
|
+
if (!this.#isValidIndex(i)) {
|
|
480
|
+
break;
|
|
481
|
+
}
|
|
482
|
+
if (allowStale || !this.#isStale(i)) {
|
|
483
|
+
yield i;
|
|
484
|
+
}
|
|
485
|
+
if (i === this.#head) {
|
|
486
|
+
break;
|
|
487
|
+
} else {
|
|
488
|
+
i = this.#prev[i];
|
|
489
|
+
}
|
|
490
|
+
}
|
|
491
|
+
}
|
|
492
|
+
}
|
|
493
|
+
*#rindexes({ allowStale = this.allowStale } = {}) {
|
|
494
|
+
if (this.#size) {
|
|
495
|
+
for (let i = this.#head; true; ) {
|
|
496
|
+
if (!this.#isValidIndex(i)) {
|
|
497
|
+
break;
|
|
498
|
+
}
|
|
499
|
+
if (allowStale || !this.#isStale(i)) {
|
|
500
|
+
yield i;
|
|
501
|
+
}
|
|
502
|
+
if (i === this.#tail) {
|
|
503
|
+
break;
|
|
504
|
+
} else {
|
|
505
|
+
i = this.#next[i];
|
|
506
|
+
}
|
|
507
|
+
}
|
|
508
|
+
}
|
|
509
|
+
}
|
|
510
|
+
#isValidIndex(index) {
|
|
511
|
+
return index !== void 0 && this.#keyMap.get(this.#keyList[index]) === index;
|
|
512
|
+
}
|
|
513
|
+
/**
|
|
514
|
+
* Return a generator yielding `[key, value]` pairs,
|
|
515
|
+
* in order from most recently used to least recently used.
|
|
516
|
+
*/
|
|
517
|
+
*entries() {
|
|
518
|
+
for (const i of this.#indexes()) {
|
|
519
|
+
if (this.#valList[i] !== void 0 && this.#keyList[i] !== void 0 && !this.#isBackgroundFetch(this.#valList[i])) {
|
|
520
|
+
yield [this.#keyList[i], this.#valList[i]];
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
}
|
|
524
|
+
/**
|
|
525
|
+
* Inverse order version of {@link LRUCache.entries}
|
|
526
|
+
*
|
|
527
|
+
* Return a generator yielding `[key, value]` pairs,
|
|
528
|
+
* in order from least recently used to most recently used.
|
|
529
|
+
*/
|
|
530
|
+
*rentries() {
|
|
531
|
+
for (const i of this.#rindexes()) {
|
|
532
|
+
if (this.#valList[i] !== void 0 && this.#keyList[i] !== void 0 && !this.#isBackgroundFetch(this.#valList[i])) {
|
|
533
|
+
yield [this.#keyList[i], this.#valList[i]];
|
|
534
|
+
}
|
|
535
|
+
}
|
|
536
|
+
}
|
|
537
|
+
/**
|
|
538
|
+
* Return a generator yielding the keys in the cache,
|
|
539
|
+
* in order from most recently used to least recently used.
|
|
540
|
+
*/
|
|
541
|
+
*keys() {
|
|
542
|
+
for (const i of this.#indexes()) {
|
|
543
|
+
const k = this.#keyList[i];
|
|
544
|
+
if (k !== void 0 && !this.#isBackgroundFetch(this.#valList[i])) {
|
|
545
|
+
yield k;
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* Inverse order version of {@link LRUCache.keys}
|
|
551
|
+
*
|
|
552
|
+
* Return a generator yielding the keys in the cache,
|
|
553
|
+
* in order from least recently used to most recently used.
|
|
554
|
+
*/
|
|
555
|
+
*rkeys() {
|
|
556
|
+
for (const i of this.#rindexes()) {
|
|
557
|
+
const k = this.#keyList[i];
|
|
558
|
+
if (k !== void 0 && !this.#isBackgroundFetch(this.#valList[i])) {
|
|
559
|
+
yield k;
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
/**
|
|
564
|
+
* Return a generator yielding the values in the cache,
|
|
565
|
+
* in order from most recently used to least recently used.
|
|
566
|
+
*/
|
|
567
|
+
*values() {
|
|
568
|
+
for (const i of this.#indexes()) {
|
|
569
|
+
const v = this.#valList[i];
|
|
570
|
+
if (v !== void 0 && !this.#isBackgroundFetch(this.#valList[i])) {
|
|
571
|
+
yield this.#valList[i];
|
|
572
|
+
}
|
|
573
|
+
}
|
|
574
|
+
}
|
|
575
|
+
/**
|
|
576
|
+
* Inverse order version of {@link LRUCache.values}
|
|
577
|
+
*
|
|
578
|
+
* Return a generator yielding the values in the cache,
|
|
579
|
+
* in order from least recently used to most recently used.
|
|
580
|
+
*/
|
|
581
|
+
*rvalues() {
|
|
582
|
+
for (const i of this.#rindexes()) {
|
|
583
|
+
const v = this.#valList[i];
|
|
584
|
+
if (v !== void 0 && !this.#isBackgroundFetch(this.#valList[i])) {
|
|
585
|
+
yield this.#valList[i];
|
|
586
|
+
}
|
|
587
|
+
}
|
|
588
|
+
}
|
|
589
|
+
/**
|
|
590
|
+
* Iterating over the cache itself yields the same results as
|
|
591
|
+
* {@link LRUCache.entries}
|
|
592
|
+
*/
|
|
593
|
+
[Symbol.iterator]() {
|
|
594
|
+
return this.entries();
|
|
595
|
+
}
|
|
596
|
+
/**
|
|
597
|
+
* A String value that is used in the creation of the default string
|
|
598
|
+
* description of an object. Called by the built-in method
|
|
599
|
+
* `Object.prototype.toString`.
|
|
600
|
+
*/
|
|
601
|
+
[Symbol.toStringTag] = "LRUCache";
|
|
602
|
+
/**
|
|
603
|
+
* Find a value for which the supplied fn method returns a truthy value,
|
|
604
|
+
* similar to `Array.find()`. fn is called as `fn(value, key, cache)`.
|
|
605
|
+
*/
|
|
606
|
+
find(fn, getOptions = {}) {
|
|
607
|
+
for (const i of this.#indexes()) {
|
|
608
|
+
const v = this.#valList[i];
|
|
609
|
+
const value = this.#isBackgroundFetch(v) ? v.__staleWhileFetching : v;
|
|
610
|
+
if (value === void 0)
|
|
611
|
+
continue;
|
|
612
|
+
if (fn(value, this.#keyList[i], this)) {
|
|
613
|
+
return this.get(this.#keyList[i], getOptions);
|
|
614
|
+
}
|
|
615
|
+
}
|
|
616
|
+
}
|
|
617
|
+
/**
|
|
618
|
+
* Call the supplied function on each item in the cache, in order from most
|
|
619
|
+
* recently used to least recently used.
|
|
620
|
+
*
|
|
621
|
+
* `fn` is called as `fn(value, key, cache)`.
|
|
622
|
+
*
|
|
623
|
+
* If `thisp` is provided, function will be called in the `this`-context of
|
|
624
|
+
* the provided object, or the cache if no `thisp` object is provided.
|
|
625
|
+
*
|
|
626
|
+
* Does not update age or recenty of use, or iterate over stale values.
|
|
627
|
+
*/
|
|
628
|
+
forEach(fn, thisp = this) {
|
|
629
|
+
for (const i of this.#indexes()) {
|
|
630
|
+
const v = this.#valList[i];
|
|
631
|
+
const value = this.#isBackgroundFetch(v) ? v.__staleWhileFetching : v;
|
|
632
|
+
if (value === void 0)
|
|
633
|
+
continue;
|
|
634
|
+
fn.call(thisp, value, this.#keyList[i], this);
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
/**
|
|
638
|
+
* The same as {@link LRUCache.forEach} but items are iterated over in
|
|
639
|
+
* reverse order. (ie, less recently used items are iterated over first.)
|
|
640
|
+
*/
|
|
641
|
+
rforEach(fn, thisp = this) {
|
|
642
|
+
for (const i of this.#rindexes()) {
|
|
643
|
+
const v = this.#valList[i];
|
|
644
|
+
const value = this.#isBackgroundFetch(v) ? v.__staleWhileFetching : v;
|
|
645
|
+
if (value === void 0)
|
|
646
|
+
continue;
|
|
647
|
+
fn.call(thisp, value, this.#keyList[i], this);
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
/**
|
|
651
|
+
* Delete any stale entries. Returns true if anything was removed,
|
|
652
|
+
* false otherwise.
|
|
653
|
+
*/
|
|
654
|
+
purgeStale() {
|
|
655
|
+
let deleted = false;
|
|
656
|
+
for (const i of this.#rindexes({ allowStale: true })) {
|
|
657
|
+
if (this.#isStale(i)) {
|
|
658
|
+
this.#delete(this.#keyList[i], "expire");
|
|
659
|
+
deleted = true;
|
|
660
|
+
}
|
|
661
|
+
}
|
|
662
|
+
return deleted;
|
|
663
|
+
}
|
|
664
|
+
/**
|
|
665
|
+
* Get the extended info about a given entry, to get its value, size, and
|
|
666
|
+
* TTL info simultaneously. Returns `undefined` if the key is not present.
|
|
667
|
+
*
|
|
668
|
+
* Unlike {@link LRUCache#dump}, which is designed to be portable and survive
|
|
669
|
+
* serialization, the `start` value is always the current timestamp, and the
|
|
670
|
+
* `ttl` is a calculated remaining time to live (negative if expired).
|
|
671
|
+
*
|
|
672
|
+
* Always returns stale values, if their info is found in the cache, so be
|
|
673
|
+
* sure to check for expirations (ie, a negative {@link LRUCache.Entry#ttl})
|
|
674
|
+
* if relevant.
|
|
675
|
+
*/
|
|
676
|
+
info(key) {
|
|
677
|
+
const i = this.#keyMap.get(key);
|
|
678
|
+
if (i === void 0)
|
|
679
|
+
return void 0;
|
|
680
|
+
const v = this.#valList[i];
|
|
681
|
+
const value = this.#isBackgroundFetch(v) ? v.__staleWhileFetching : v;
|
|
682
|
+
if (value === void 0)
|
|
683
|
+
return void 0;
|
|
684
|
+
const entry = { value };
|
|
685
|
+
if (this.#ttls && this.#starts) {
|
|
686
|
+
const ttl = this.#ttls[i];
|
|
687
|
+
const start = this.#starts[i];
|
|
688
|
+
if (ttl && start) {
|
|
689
|
+
const remain = ttl - (perf.now() - start);
|
|
690
|
+
entry.ttl = remain;
|
|
691
|
+
entry.start = Date.now();
|
|
692
|
+
}
|
|
693
|
+
}
|
|
694
|
+
if (this.#sizes) {
|
|
695
|
+
entry.size = this.#sizes[i];
|
|
696
|
+
}
|
|
697
|
+
return entry;
|
|
698
|
+
}
|
|
699
|
+
/**
|
|
700
|
+
* Return an array of [key, {@link LRUCache.Entry}] tuples which can be
|
|
701
|
+
* passed to {@link LRLUCache#load}.
|
|
702
|
+
*
|
|
703
|
+
* The `start` fields are calculated relative to a portable `Date.now()`
|
|
704
|
+
* timestamp, even if `performance.now()` is available.
|
|
705
|
+
*
|
|
706
|
+
* Stale entries are always included in the `dump`, even if
|
|
707
|
+
* {@link LRUCache.OptionsBase.allowStale} is false.
|
|
708
|
+
*
|
|
709
|
+
* Note: this returns an actual array, not a generator, so it can be more
|
|
710
|
+
* easily passed around.
|
|
711
|
+
*/
|
|
712
|
+
dump() {
|
|
713
|
+
const arr = [];
|
|
714
|
+
for (const i of this.#indexes({ allowStale: true })) {
|
|
715
|
+
const key = this.#keyList[i];
|
|
716
|
+
const v = this.#valList[i];
|
|
717
|
+
const value = this.#isBackgroundFetch(v) ? v.__staleWhileFetching : v;
|
|
718
|
+
if (value === void 0 || key === void 0)
|
|
719
|
+
continue;
|
|
720
|
+
const entry = { value };
|
|
721
|
+
if (this.#ttls && this.#starts) {
|
|
722
|
+
entry.ttl = this.#ttls[i];
|
|
723
|
+
const age = perf.now() - this.#starts[i];
|
|
724
|
+
entry.start = Math.floor(Date.now() - age);
|
|
725
|
+
}
|
|
726
|
+
if (this.#sizes) {
|
|
727
|
+
entry.size = this.#sizes[i];
|
|
728
|
+
}
|
|
729
|
+
arr.unshift([key, entry]);
|
|
730
|
+
}
|
|
731
|
+
return arr;
|
|
732
|
+
}
|
|
733
|
+
/**
|
|
734
|
+
* Reset the cache and load in the items in entries in the order listed.
|
|
735
|
+
*
|
|
736
|
+
* The shape of the resulting cache may be different if the same options are
|
|
737
|
+
* not used in both caches.
|
|
738
|
+
*
|
|
739
|
+
* The `start` fields are assumed to be calculated relative to a portable
|
|
740
|
+
* `Date.now()` timestamp, even if `performance.now()` is available.
|
|
741
|
+
*/
|
|
742
|
+
load(arr) {
|
|
743
|
+
this.clear();
|
|
744
|
+
for (const [key, entry] of arr) {
|
|
745
|
+
if (entry.start) {
|
|
746
|
+
const age = Date.now() - entry.start;
|
|
747
|
+
entry.start = perf.now() - age;
|
|
748
|
+
}
|
|
749
|
+
this.set(key, entry.value, entry);
|
|
750
|
+
}
|
|
751
|
+
}
|
|
752
|
+
/**
|
|
753
|
+
* Add a value to the cache.
|
|
754
|
+
*
|
|
755
|
+
* Note: if `undefined` is specified as a value, this is an alias for
|
|
756
|
+
* {@link LRUCache#delete}
|
|
757
|
+
*
|
|
758
|
+
* Fields on the {@link LRUCache.SetOptions} options param will override
|
|
759
|
+
* their corresponding values in the constructor options for the scope
|
|
760
|
+
* of this single `set()` operation.
|
|
761
|
+
*
|
|
762
|
+
* If `start` is provided, then that will set the effective start
|
|
763
|
+
* time for the TTL calculation. Note that this must be a previous
|
|
764
|
+
* value of `performance.now()` if supported, or a previous value of
|
|
765
|
+
* `Date.now()` if not.
|
|
766
|
+
*
|
|
767
|
+
* Options object may also include `size`, which will prevent
|
|
768
|
+
* calling the `sizeCalculation` function and just use the specified
|
|
769
|
+
* number if it is a positive integer, and `noDisposeOnSet` which
|
|
770
|
+
* will prevent calling a `dispose` function in the case of
|
|
771
|
+
* overwrites.
|
|
772
|
+
*
|
|
773
|
+
* If the `size` (or return value of `sizeCalculation`) for a given
|
|
774
|
+
* entry is greater than `maxEntrySize`, then the item will not be
|
|
775
|
+
* added to the cache.
|
|
776
|
+
*
|
|
777
|
+
* Will update the recency of the entry.
|
|
778
|
+
*
|
|
779
|
+
* If the value is `undefined`, then this is an alias for
|
|
780
|
+
* `cache.delete(key)`. `undefined` is never stored in the cache.
|
|
781
|
+
*/
|
|
782
|
+
set(k, v, setOptions = {}) {
|
|
783
|
+
if (v === void 0) {
|
|
784
|
+
this.delete(k);
|
|
785
|
+
return this;
|
|
786
|
+
}
|
|
787
|
+
const { ttl = this.ttl, start, noDisposeOnSet = this.noDisposeOnSet, sizeCalculation = this.sizeCalculation, status } = setOptions;
|
|
788
|
+
let { noUpdateTTL = this.noUpdateTTL } = setOptions;
|
|
789
|
+
const size = this.#requireSize(k, v, setOptions.size || 0, sizeCalculation);
|
|
790
|
+
if (this.maxEntrySize && size > this.maxEntrySize) {
|
|
791
|
+
if (status) {
|
|
792
|
+
status.set = "miss";
|
|
793
|
+
status.maxEntrySizeExceeded = true;
|
|
794
|
+
}
|
|
795
|
+
this.#delete(k, "set");
|
|
796
|
+
return this;
|
|
797
|
+
}
|
|
798
|
+
let index = this.#size === 0 ? void 0 : this.#keyMap.get(k);
|
|
799
|
+
if (index === void 0) {
|
|
800
|
+
index = this.#size === 0 ? this.#tail : this.#free.length !== 0 ? this.#free.pop() : this.#size === this.#max ? this.#evict(false) : this.#size;
|
|
801
|
+
this.#keyList[index] = k;
|
|
802
|
+
this.#valList[index] = v;
|
|
803
|
+
this.#keyMap.set(k, index);
|
|
804
|
+
this.#next[this.#tail] = index;
|
|
805
|
+
this.#prev[index] = this.#tail;
|
|
806
|
+
this.#tail = index;
|
|
807
|
+
this.#size++;
|
|
808
|
+
this.#addItemSize(index, size, status);
|
|
809
|
+
if (status)
|
|
810
|
+
status.set = "add";
|
|
811
|
+
noUpdateTTL = false;
|
|
812
|
+
} else {
|
|
813
|
+
this.#moveToTail(index);
|
|
814
|
+
const oldVal = this.#valList[index];
|
|
815
|
+
if (v !== oldVal) {
|
|
816
|
+
if (this.#hasFetchMethod && this.#isBackgroundFetch(oldVal)) {
|
|
817
|
+
oldVal.__abortController.abort(new Error("replaced"));
|
|
818
|
+
const { __staleWhileFetching: s } = oldVal;
|
|
819
|
+
if (s !== void 0 && !noDisposeOnSet) {
|
|
820
|
+
if (this.#hasDispose) {
|
|
821
|
+
this.#dispose?.(s, k, "set");
|
|
822
|
+
}
|
|
823
|
+
if (this.#hasDisposeAfter) {
|
|
824
|
+
this.#disposed?.push([s, k, "set"]);
|
|
825
|
+
}
|
|
826
|
+
}
|
|
827
|
+
} else if (!noDisposeOnSet) {
|
|
828
|
+
if (this.#hasDispose) {
|
|
829
|
+
this.#dispose?.(oldVal, k, "set");
|
|
830
|
+
}
|
|
831
|
+
if (this.#hasDisposeAfter) {
|
|
832
|
+
this.#disposed?.push([oldVal, k, "set"]);
|
|
833
|
+
}
|
|
834
|
+
}
|
|
835
|
+
this.#removeItemSize(index);
|
|
836
|
+
this.#addItemSize(index, size, status);
|
|
837
|
+
this.#valList[index] = v;
|
|
838
|
+
if (status) {
|
|
839
|
+
status.set = "replace";
|
|
840
|
+
const oldValue = oldVal && this.#isBackgroundFetch(oldVal) ? oldVal.__staleWhileFetching : oldVal;
|
|
841
|
+
if (oldValue !== void 0)
|
|
842
|
+
status.oldValue = oldValue;
|
|
843
|
+
}
|
|
844
|
+
} else if (status) {
|
|
845
|
+
status.set = "update";
|
|
846
|
+
}
|
|
847
|
+
}
|
|
848
|
+
if (ttl !== 0 && !this.#ttls) {
|
|
849
|
+
this.#initializeTTLTracking();
|
|
850
|
+
}
|
|
851
|
+
if (this.#ttls) {
|
|
852
|
+
if (!noUpdateTTL) {
|
|
853
|
+
this.#setItemTTL(index, ttl, start);
|
|
854
|
+
}
|
|
855
|
+
if (status)
|
|
856
|
+
this.#statusTTL(status, index);
|
|
857
|
+
}
|
|
858
|
+
if (!noDisposeOnSet && this.#hasDisposeAfter && this.#disposed) {
|
|
859
|
+
const dt = this.#disposed;
|
|
860
|
+
let task;
|
|
861
|
+
while (task = dt?.shift()) {
|
|
862
|
+
this.#disposeAfter?.(...task);
|
|
863
|
+
}
|
|
864
|
+
}
|
|
865
|
+
return this;
|
|
866
|
+
}
|
|
867
|
+
/**
|
|
868
|
+
* Evict the least recently used item, returning its value or
|
|
869
|
+
* `undefined` if cache is empty.
|
|
870
|
+
*/
|
|
871
|
+
pop() {
|
|
872
|
+
try {
|
|
873
|
+
while (this.#size) {
|
|
874
|
+
const val = this.#valList[this.#head];
|
|
875
|
+
this.#evict(true);
|
|
876
|
+
if (this.#isBackgroundFetch(val)) {
|
|
877
|
+
if (val.__staleWhileFetching) {
|
|
878
|
+
return val.__staleWhileFetching;
|
|
879
|
+
}
|
|
880
|
+
} else if (val !== void 0) {
|
|
881
|
+
return val;
|
|
882
|
+
}
|
|
883
|
+
}
|
|
884
|
+
} finally {
|
|
885
|
+
if (this.#hasDisposeAfter && this.#disposed) {
|
|
886
|
+
const dt = this.#disposed;
|
|
887
|
+
let task;
|
|
888
|
+
while (task = dt?.shift()) {
|
|
889
|
+
this.#disposeAfter?.(...task);
|
|
890
|
+
}
|
|
891
|
+
}
|
|
892
|
+
}
|
|
893
|
+
}
|
|
894
|
+
#evict(free) {
|
|
895
|
+
const head = this.#head;
|
|
896
|
+
const k = this.#keyList[head];
|
|
897
|
+
const v = this.#valList[head];
|
|
898
|
+
if (this.#hasFetchMethod && this.#isBackgroundFetch(v)) {
|
|
899
|
+
v.__abortController.abort(new Error("evicted"));
|
|
900
|
+
} else if (this.#hasDispose || this.#hasDisposeAfter) {
|
|
901
|
+
if (this.#hasDispose) {
|
|
902
|
+
this.#dispose?.(v, k, "evict");
|
|
903
|
+
}
|
|
904
|
+
if (this.#hasDisposeAfter) {
|
|
905
|
+
this.#disposed?.push([v, k, "evict"]);
|
|
906
|
+
}
|
|
907
|
+
}
|
|
908
|
+
this.#removeItemSize(head);
|
|
909
|
+
if (free) {
|
|
910
|
+
this.#keyList[head] = void 0;
|
|
911
|
+
this.#valList[head] = void 0;
|
|
912
|
+
this.#free.push(head);
|
|
913
|
+
}
|
|
914
|
+
if (this.#size === 1) {
|
|
915
|
+
this.#head = this.#tail = 0;
|
|
916
|
+
this.#free.length = 0;
|
|
917
|
+
} else {
|
|
918
|
+
this.#head = this.#next[head];
|
|
919
|
+
}
|
|
920
|
+
this.#keyMap.delete(k);
|
|
921
|
+
this.#size--;
|
|
922
|
+
return head;
|
|
923
|
+
}
|
|
924
|
+
/**
|
|
925
|
+
* Check if a key is in the cache, without updating the recency of use.
|
|
926
|
+
* Will return false if the item is stale, even though it is technically
|
|
927
|
+
* in the cache.
|
|
928
|
+
*
|
|
929
|
+
* Check if a key is in the cache, without updating the recency of
|
|
930
|
+
* use. Age is updated if {@link LRUCache.OptionsBase.updateAgeOnHas} is set
|
|
931
|
+
* to `true` in either the options or the constructor.
|
|
932
|
+
*
|
|
933
|
+
* Will return `false` if the item is stale, even though it is technically in
|
|
934
|
+
* the cache. The difference can be determined (if it matters) by using a
|
|
935
|
+
* `status` argument, and inspecting the `has` field.
|
|
936
|
+
*
|
|
937
|
+
* Will not update item age unless
|
|
938
|
+
* {@link LRUCache.OptionsBase.updateAgeOnHas} is set.
|
|
939
|
+
*/
|
|
940
|
+
has(k, hasOptions = {}) {
|
|
941
|
+
const { updateAgeOnHas = this.updateAgeOnHas, status } = hasOptions;
|
|
942
|
+
const index = this.#keyMap.get(k);
|
|
943
|
+
if (index !== void 0) {
|
|
944
|
+
const v = this.#valList[index];
|
|
945
|
+
if (this.#isBackgroundFetch(v) && v.__staleWhileFetching === void 0) {
|
|
946
|
+
return false;
|
|
947
|
+
}
|
|
948
|
+
if (!this.#isStale(index)) {
|
|
949
|
+
if (updateAgeOnHas) {
|
|
950
|
+
this.#updateItemAge(index);
|
|
951
|
+
}
|
|
952
|
+
if (status) {
|
|
953
|
+
status.has = "hit";
|
|
954
|
+
this.#statusTTL(status, index);
|
|
955
|
+
}
|
|
956
|
+
return true;
|
|
957
|
+
} else if (status) {
|
|
958
|
+
status.has = "stale";
|
|
959
|
+
this.#statusTTL(status, index);
|
|
960
|
+
}
|
|
961
|
+
} else if (status) {
|
|
962
|
+
status.has = "miss";
|
|
963
|
+
}
|
|
964
|
+
return false;
|
|
965
|
+
}
|
|
966
|
+
/**
|
|
967
|
+
* Like {@link LRUCache#get} but doesn't update recency or delete stale
|
|
968
|
+
* items.
|
|
969
|
+
*
|
|
970
|
+
* Returns `undefined` if the item is stale, unless
|
|
971
|
+
* {@link LRUCache.OptionsBase.allowStale} is set.
|
|
972
|
+
*/
|
|
973
|
+
peek(k, peekOptions = {}) {
|
|
974
|
+
const { allowStale = this.allowStale } = peekOptions;
|
|
975
|
+
const index = this.#keyMap.get(k);
|
|
976
|
+
if (index === void 0 || !allowStale && this.#isStale(index)) {
|
|
977
|
+
return;
|
|
978
|
+
}
|
|
979
|
+
const v = this.#valList[index];
|
|
980
|
+
return this.#isBackgroundFetch(v) ? v.__staleWhileFetching : v;
|
|
981
|
+
}
|
|
982
|
+
#backgroundFetch(k, index, options, context) {
|
|
983
|
+
const v = index === void 0 ? void 0 : this.#valList[index];
|
|
984
|
+
if (this.#isBackgroundFetch(v)) {
|
|
985
|
+
return v;
|
|
986
|
+
}
|
|
987
|
+
const ac = new AC();
|
|
988
|
+
const { signal } = options;
|
|
989
|
+
signal?.addEventListener("abort", () => ac.abort(signal.reason), {
|
|
990
|
+
signal: ac.signal
|
|
991
|
+
});
|
|
992
|
+
const fetchOpts = {
|
|
993
|
+
signal: ac.signal,
|
|
994
|
+
options,
|
|
995
|
+
context
|
|
996
|
+
};
|
|
997
|
+
const cb = (v2, updateCache = false) => {
|
|
998
|
+
const { aborted } = ac.signal;
|
|
999
|
+
const ignoreAbort = options.ignoreFetchAbort && v2 !== void 0;
|
|
1000
|
+
if (options.status) {
|
|
1001
|
+
if (aborted && !updateCache) {
|
|
1002
|
+
options.status.fetchAborted = true;
|
|
1003
|
+
options.status.fetchError = ac.signal.reason;
|
|
1004
|
+
if (ignoreAbort)
|
|
1005
|
+
options.status.fetchAbortIgnored = true;
|
|
1006
|
+
} else {
|
|
1007
|
+
options.status.fetchResolved = true;
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
if (aborted && !ignoreAbort && !updateCache) {
|
|
1011
|
+
return fetchFail(ac.signal.reason);
|
|
1012
|
+
}
|
|
1013
|
+
const bf2 = p;
|
|
1014
|
+
if (this.#valList[index] === p) {
|
|
1015
|
+
if (v2 === void 0) {
|
|
1016
|
+
if (bf2.__staleWhileFetching) {
|
|
1017
|
+
this.#valList[index] = bf2.__staleWhileFetching;
|
|
1018
|
+
} else {
|
|
1019
|
+
this.#delete(k, "fetch");
|
|
1020
|
+
}
|
|
1021
|
+
} else {
|
|
1022
|
+
if (options.status)
|
|
1023
|
+
options.status.fetchUpdated = true;
|
|
1024
|
+
this.set(k, v2, fetchOpts.options);
|
|
1025
|
+
}
|
|
1026
|
+
}
|
|
1027
|
+
return v2;
|
|
1028
|
+
};
|
|
1029
|
+
const eb = (er) => {
|
|
1030
|
+
if (options.status) {
|
|
1031
|
+
options.status.fetchRejected = true;
|
|
1032
|
+
options.status.fetchError = er;
|
|
1033
|
+
}
|
|
1034
|
+
return fetchFail(er);
|
|
1035
|
+
};
|
|
1036
|
+
const fetchFail = (er) => {
|
|
1037
|
+
const { aborted } = ac.signal;
|
|
1038
|
+
const allowStaleAborted = aborted && options.allowStaleOnFetchAbort;
|
|
1039
|
+
const allowStale = allowStaleAborted || options.allowStaleOnFetchRejection;
|
|
1040
|
+
const noDelete = allowStale || options.noDeleteOnFetchRejection;
|
|
1041
|
+
const bf2 = p;
|
|
1042
|
+
if (this.#valList[index] === p) {
|
|
1043
|
+
const del = !noDelete || bf2.__staleWhileFetching === void 0;
|
|
1044
|
+
if (del) {
|
|
1045
|
+
this.#delete(k, "fetch");
|
|
1046
|
+
} else if (!allowStaleAborted) {
|
|
1047
|
+
this.#valList[index] = bf2.__staleWhileFetching;
|
|
1048
|
+
}
|
|
1049
|
+
}
|
|
1050
|
+
if (allowStale) {
|
|
1051
|
+
if (options.status && bf2.__staleWhileFetching !== void 0) {
|
|
1052
|
+
options.status.returnedStale = true;
|
|
1053
|
+
}
|
|
1054
|
+
return bf2.__staleWhileFetching;
|
|
1055
|
+
} else if (bf2.__returned === bf2) {
|
|
1056
|
+
throw er;
|
|
1057
|
+
}
|
|
1058
|
+
};
|
|
1059
|
+
const pcall = (res, rej) => {
|
|
1060
|
+
const fmp = this.#fetchMethod?.(k, v, fetchOpts);
|
|
1061
|
+
if (fmp && fmp instanceof Promise) {
|
|
1062
|
+
fmp.then((v2) => res(v2 === void 0 ? void 0 : v2), rej);
|
|
1063
|
+
}
|
|
1064
|
+
ac.signal.addEventListener("abort", () => {
|
|
1065
|
+
if (!options.ignoreFetchAbort || options.allowStaleOnFetchAbort) {
|
|
1066
|
+
res(void 0);
|
|
1067
|
+
if (options.allowStaleOnFetchAbort) {
|
|
1068
|
+
res = (v2) => cb(v2, true);
|
|
1069
|
+
}
|
|
1070
|
+
}
|
|
1071
|
+
});
|
|
1072
|
+
};
|
|
1073
|
+
if (options.status)
|
|
1074
|
+
options.status.fetchDispatched = true;
|
|
1075
|
+
const p = new Promise(pcall).then(cb, eb);
|
|
1076
|
+
const bf = Object.assign(p, {
|
|
1077
|
+
__abortController: ac,
|
|
1078
|
+
__staleWhileFetching: v,
|
|
1079
|
+
__returned: void 0
|
|
1080
|
+
});
|
|
1081
|
+
if (index === void 0) {
|
|
1082
|
+
this.set(k, bf, { ...fetchOpts.options, status: void 0 });
|
|
1083
|
+
index = this.#keyMap.get(k);
|
|
1084
|
+
} else {
|
|
1085
|
+
this.#valList[index] = bf;
|
|
1086
|
+
}
|
|
1087
|
+
return bf;
|
|
1088
|
+
}
|
|
1089
|
+
#isBackgroundFetch(p) {
|
|
1090
|
+
if (!this.#hasFetchMethod)
|
|
1091
|
+
return false;
|
|
1092
|
+
const b = p;
|
|
1093
|
+
return !!b && b instanceof Promise && b.hasOwnProperty("__staleWhileFetching") && b.__abortController instanceof AC;
|
|
1094
|
+
}
|
|
1095
|
+
async fetch(k, fetchOptions = {}) {
|
|
1096
|
+
const {
|
|
1097
|
+
// get options
|
|
1098
|
+
allowStale = this.allowStale,
|
|
1099
|
+
updateAgeOnGet = this.updateAgeOnGet,
|
|
1100
|
+
noDeleteOnStaleGet = this.noDeleteOnStaleGet,
|
|
1101
|
+
// set options
|
|
1102
|
+
ttl = this.ttl,
|
|
1103
|
+
noDisposeOnSet = this.noDisposeOnSet,
|
|
1104
|
+
size = 0,
|
|
1105
|
+
sizeCalculation = this.sizeCalculation,
|
|
1106
|
+
noUpdateTTL = this.noUpdateTTL,
|
|
1107
|
+
// fetch exclusive options
|
|
1108
|
+
noDeleteOnFetchRejection = this.noDeleteOnFetchRejection,
|
|
1109
|
+
allowStaleOnFetchRejection = this.allowStaleOnFetchRejection,
|
|
1110
|
+
ignoreFetchAbort = this.ignoreFetchAbort,
|
|
1111
|
+
allowStaleOnFetchAbort = this.allowStaleOnFetchAbort,
|
|
1112
|
+
context,
|
|
1113
|
+
forceRefresh = false,
|
|
1114
|
+
status,
|
|
1115
|
+
signal
|
|
1116
|
+
} = fetchOptions;
|
|
1117
|
+
if (!this.#hasFetchMethod) {
|
|
1118
|
+
if (status)
|
|
1119
|
+
status.fetch = "get";
|
|
1120
|
+
return this.get(k, {
|
|
1121
|
+
allowStale,
|
|
1122
|
+
updateAgeOnGet,
|
|
1123
|
+
noDeleteOnStaleGet,
|
|
1124
|
+
status
|
|
1125
|
+
});
|
|
1126
|
+
}
|
|
1127
|
+
const options = {
|
|
1128
|
+
allowStale,
|
|
1129
|
+
updateAgeOnGet,
|
|
1130
|
+
noDeleteOnStaleGet,
|
|
1131
|
+
ttl,
|
|
1132
|
+
noDisposeOnSet,
|
|
1133
|
+
size,
|
|
1134
|
+
sizeCalculation,
|
|
1135
|
+
noUpdateTTL,
|
|
1136
|
+
noDeleteOnFetchRejection,
|
|
1137
|
+
allowStaleOnFetchRejection,
|
|
1138
|
+
allowStaleOnFetchAbort,
|
|
1139
|
+
ignoreFetchAbort,
|
|
1140
|
+
status,
|
|
1141
|
+
signal
|
|
1142
|
+
};
|
|
1143
|
+
let index = this.#keyMap.get(k);
|
|
1144
|
+
if (index === void 0) {
|
|
1145
|
+
if (status)
|
|
1146
|
+
status.fetch = "miss";
|
|
1147
|
+
const p = this.#backgroundFetch(k, index, options, context);
|
|
1148
|
+
return p.__returned = p;
|
|
1149
|
+
} else {
|
|
1150
|
+
const v = this.#valList[index];
|
|
1151
|
+
if (this.#isBackgroundFetch(v)) {
|
|
1152
|
+
const stale = allowStale && v.__staleWhileFetching !== void 0;
|
|
1153
|
+
if (status) {
|
|
1154
|
+
status.fetch = "inflight";
|
|
1155
|
+
if (stale)
|
|
1156
|
+
status.returnedStale = true;
|
|
1157
|
+
}
|
|
1158
|
+
return stale ? v.__staleWhileFetching : v.__returned = v;
|
|
1159
|
+
}
|
|
1160
|
+
const isStale = this.#isStale(index);
|
|
1161
|
+
if (!forceRefresh && !isStale) {
|
|
1162
|
+
if (status)
|
|
1163
|
+
status.fetch = "hit";
|
|
1164
|
+
this.#moveToTail(index);
|
|
1165
|
+
if (updateAgeOnGet) {
|
|
1166
|
+
this.#updateItemAge(index);
|
|
1167
|
+
}
|
|
1168
|
+
if (status)
|
|
1169
|
+
this.#statusTTL(status, index);
|
|
1170
|
+
return v;
|
|
1171
|
+
}
|
|
1172
|
+
const p = this.#backgroundFetch(k, index, options, context);
|
|
1173
|
+
const hasStale = p.__staleWhileFetching !== void 0;
|
|
1174
|
+
const staleVal = hasStale && allowStale;
|
|
1175
|
+
if (status) {
|
|
1176
|
+
status.fetch = isStale ? "stale" : "refresh";
|
|
1177
|
+
if (staleVal && isStale)
|
|
1178
|
+
status.returnedStale = true;
|
|
1179
|
+
}
|
|
1180
|
+
return staleVal ? p.__staleWhileFetching : p.__returned = p;
|
|
1181
|
+
}
|
|
1182
|
+
}
|
|
1183
|
+
async forceFetch(k, fetchOptions = {}) {
|
|
1184
|
+
const v = await this.fetch(k, fetchOptions);
|
|
1185
|
+
if (v === void 0)
|
|
1186
|
+
throw new Error("fetch() returned undefined");
|
|
1187
|
+
return v;
|
|
1188
|
+
}
|
|
1189
|
+
memo(k, memoOptions = {}) {
|
|
1190
|
+
const memoMethod = this.#memoMethod;
|
|
1191
|
+
if (!memoMethod) {
|
|
1192
|
+
throw new Error("no memoMethod provided to constructor");
|
|
1193
|
+
}
|
|
1194
|
+
const { context, forceRefresh, ...options } = memoOptions;
|
|
1195
|
+
const v = this.get(k, options);
|
|
1196
|
+
if (!forceRefresh && v !== void 0)
|
|
1197
|
+
return v;
|
|
1198
|
+
const vv = memoMethod(k, v, {
|
|
1199
|
+
options,
|
|
1200
|
+
context
|
|
1201
|
+
});
|
|
1202
|
+
this.set(k, vv, options);
|
|
1203
|
+
return vv;
|
|
1204
|
+
}
|
|
1205
|
+
/**
|
|
1206
|
+
* Return a value from the cache. Will update the recency of the cache
|
|
1207
|
+
* entry found.
|
|
1208
|
+
*
|
|
1209
|
+
* If the key is not found, get() will return `undefined`.
|
|
1210
|
+
*/
|
|
1211
|
+
get(k, getOptions = {}) {
|
|
1212
|
+
const { allowStale = this.allowStale, updateAgeOnGet = this.updateAgeOnGet, noDeleteOnStaleGet = this.noDeleteOnStaleGet, status } = getOptions;
|
|
1213
|
+
const index = this.#keyMap.get(k);
|
|
1214
|
+
if (index !== void 0) {
|
|
1215
|
+
const value = this.#valList[index];
|
|
1216
|
+
const fetching = this.#isBackgroundFetch(value);
|
|
1217
|
+
if (status)
|
|
1218
|
+
this.#statusTTL(status, index);
|
|
1219
|
+
if (this.#isStale(index)) {
|
|
1220
|
+
if (status)
|
|
1221
|
+
status.get = "stale";
|
|
1222
|
+
if (!fetching) {
|
|
1223
|
+
if (!noDeleteOnStaleGet) {
|
|
1224
|
+
this.#delete(k, "expire");
|
|
1225
|
+
}
|
|
1226
|
+
if (status && allowStale)
|
|
1227
|
+
status.returnedStale = true;
|
|
1228
|
+
return allowStale ? value : void 0;
|
|
1229
|
+
} else {
|
|
1230
|
+
if (status && allowStale && value.__staleWhileFetching !== void 0) {
|
|
1231
|
+
status.returnedStale = true;
|
|
1232
|
+
}
|
|
1233
|
+
return allowStale ? value.__staleWhileFetching : void 0;
|
|
1234
|
+
}
|
|
1235
|
+
} else {
|
|
1236
|
+
if (status)
|
|
1237
|
+
status.get = "hit";
|
|
1238
|
+
if (fetching) {
|
|
1239
|
+
return value.__staleWhileFetching;
|
|
1240
|
+
}
|
|
1241
|
+
this.#moveToTail(index);
|
|
1242
|
+
if (updateAgeOnGet) {
|
|
1243
|
+
this.#updateItemAge(index);
|
|
1244
|
+
}
|
|
1245
|
+
return value;
|
|
1246
|
+
}
|
|
1247
|
+
} else if (status) {
|
|
1248
|
+
status.get = "miss";
|
|
1249
|
+
}
|
|
1250
|
+
}
|
|
1251
|
+
#connect(p, n) {
|
|
1252
|
+
this.#prev[n] = p;
|
|
1253
|
+
this.#next[p] = n;
|
|
1254
|
+
}
|
|
1255
|
+
#moveToTail(index) {
|
|
1256
|
+
if (index !== this.#tail) {
|
|
1257
|
+
if (index === this.#head) {
|
|
1258
|
+
this.#head = this.#next[index];
|
|
1259
|
+
} else {
|
|
1260
|
+
this.#connect(this.#prev[index], this.#next[index]);
|
|
1261
|
+
}
|
|
1262
|
+
this.#connect(this.#tail, index);
|
|
1263
|
+
this.#tail = index;
|
|
1264
|
+
}
|
|
1265
|
+
}
|
|
1266
|
+
/**
|
|
1267
|
+
* Deletes a key out of the cache.
|
|
1268
|
+
*
|
|
1269
|
+
* Returns true if the key was deleted, false otherwise.
|
|
1270
|
+
*/
|
|
1271
|
+
delete(k) {
|
|
1272
|
+
return this.#delete(k, "delete");
|
|
1273
|
+
}
|
|
1274
|
+
#delete(k, reason) {
|
|
1275
|
+
let deleted = false;
|
|
1276
|
+
if (this.#size !== 0) {
|
|
1277
|
+
const index = this.#keyMap.get(k);
|
|
1278
|
+
if (index !== void 0) {
|
|
1279
|
+
deleted = true;
|
|
1280
|
+
if (this.#size === 1) {
|
|
1281
|
+
this.#clear(reason);
|
|
1282
|
+
} else {
|
|
1283
|
+
this.#removeItemSize(index);
|
|
1284
|
+
const v = this.#valList[index];
|
|
1285
|
+
if (this.#isBackgroundFetch(v)) {
|
|
1286
|
+
v.__abortController.abort(new Error("deleted"));
|
|
1287
|
+
} else if (this.#hasDispose || this.#hasDisposeAfter) {
|
|
1288
|
+
if (this.#hasDispose) {
|
|
1289
|
+
this.#dispose?.(v, k, reason);
|
|
1290
|
+
}
|
|
1291
|
+
if (this.#hasDisposeAfter) {
|
|
1292
|
+
this.#disposed?.push([v, k, reason]);
|
|
1293
|
+
}
|
|
1294
|
+
}
|
|
1295
|
+
this.#keyMap.delete(k);
|
|
1296
|
+
this.#keyList[index] = void 0;
|
|
1297
|
+
this.#valList[index] = void 0;
|
|
1298
|
+
if (index === this.#tail) {
|
|
1299
|
+
this.#tail = this.#prev[index];
|
|
1300
|
+
} else if (index === this.#head) {
|
|
1301
|
+
this.#head = this.#next[index];
|
|
1302
|
+
} else {
|
|
1303
|
+
const pi = this.#prev[index];
|
|
1304
|
+
this.#next[pi] = this.#next[index];
|
|
1305
|
+
const ni = this.#next[index];
|
|
1306
|
+
this.#prev[ni] = this.#prev[index];
|
|
1307
|
+
}
|
|
1308
|
+
this.#size--;
|
|
1309
|
+
this.#free.push(index);
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
}
|
|
1313
|
+
if (this.#hasDisposeAfter && this.#disposed?.length) {
|
|
1314
|
+
const dt = this.#disposed;
|
|
1315
|
+
let task;
|
|
1316
|
+
while (task = dt?.shift()) {
|
|
1317
|
+
this.#disposeAfter?.(...task);
|
|
1318
|
+
}
|
|
1319
|
+
}
|
|
1320
|
+
return deleted;
|
|
1321
|
+
}
|
|
1322
|
+
/**
|
|
1323
|
+
* Clear the cache entirely, throwing away all values.
|
|
1324
|
+
*/
|
|
1325
|
+
clear() {
|
|
1326
|
+
return this.#clear("delete");
|
|
1327
|
+
}
|
|
1328
|
+
#clear(reason) {
|
|
1329
|
+
for (const index of this.#rindexes({ allowStale: true })) {
|
|
1330
|
+
const v = this.#valList[index];
|
|
1331
|
+
if (this.#isBackgroundFetch(v)) {
|
|
1332
|
+
v.__abortController.abort(new Error("deleted"));
|
|
1333
|
+
} else {
|
|
1334
|
+
const k = this.#keyList[index];
|
|
1335
|
+
if (this.#hasDispose) {
|
|
1336
|
+
this.#dispose?.(v, k, reason);
|
|
1337
|
+
}
|
|
1338
|
+
if (this.#hasDisposeAfter) {
|
|
1339
|
+
this.#disposed?.push([v, k, reason]);
|
|
1340
|
+
}
|
|
1341
|
+
}
|
|
1342
|
+
}
|
|
1343
|
+
this.#keyMap.clear();
|
|
1344
|
+
this.#valList.fill(void 0);
|
|
1345
|
+
this.#keyList.fill(void 0);
|
|
1346
|
+
if (this.#ttls && this.#starts) {
|
|
1347
|
+
this.#ttls.fill(0);
|
|
1348
|
+
this.#starts.fill(0);
|
|
1349
|
+
}
|
|
1350
|
+
if (this.#sizes) {
|
|
1351
|
+
this.#sizes.fill(0);
|
|
1352
|
+
}
|
|
1353
|
+
this.#head = 0;
|
|
1354
|
+
this.#tail = 0;
|
|
1355
|
+
this.#free.length = 0;
|
|
1356
|
+
this.#calculatedSize = 0;
|
|
1357
|
+
this.#size = 0;
|
|
1358
|
+
if (this.#hasDisposeAfter && this.#disposed) {
|
|
1359
|
+
const dt = this.#disposed;
|
|
1360
|
+
let task;
|
|
1361
|
+
while (task = dt?.shift()) {
|
|
1362
|
+
this.#disposeAfter?.(...task);
|
|
1363
|
+
}
|
|
1364
|
+
}
|
|
1365
|
+
}
|
|
1366
|
+
}
|
|
1367
|
+
export {
|
|
1368
|
+
LRUCache
|
|
1369
|
+
};
|
|
1370
|
+
//# sourceMappingURL=index.js.map
|