@warlock.js/core 4.0.174 → 4.1.2
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 +5 -1
- package/esm/_virtual/_rolldown/runtime.mjs +7 -0
- package/esm/application/app.d.mts +16 -0
- package/esm/application/app.d.mts.map +1 -0
- package/esm/application/app.mjs +36 -0
- package/esm/application/app.mjs.map +1 -0
- package/esm/application/application-config-types.d.mts +30 -0
- package/esm/application/application-config-types.d.mts.map +1 -0
- package/esm/application/application.d.mts +72 -0
- package/esm/application/application.d.mts.map +1 -0
- package/esm/application/application.mjs +98 -0
- package/esm/application/application.mjs.map +1 -0
- package/esm/application/index.d.mts +3 -0
- package/esm/application/index.mjs +4 -0
- package/esm/benchmark/benchmark-snapshots.d.mts +51 -0
- package/esm/benchmark/benchmark-snapshots.d.mts.map +1 -0
- package/esm/benchmark/benchmark-snapshots.mjs +70 -0
- package/esm/benchmark/benchmark-snapshots.mjs.map +1 -0
- package/esm/benchmark/benchmark.d.mts +29 -0
- package/esm/benchmark/benchmark.d.mts.map +1 -0
- package/esm/benchmark/benchmark.mjs +101 -0
- package/esm/benchmark/benchmark.mjs.map +1 -0
- package/esm/benchmark/channels/console.channel.d.mts +18 -0
- package/esm/benchmark/channels/console.channel.d.mts.map +1 -0
- package/esm/benchmark/channels/console.channel.mjs +32 -0
- package/esm/benchmark/channels/console.channel.mjs.map +1 -0
- package/esm/benchmark/channels/noop.channel.d.mts +9 -0
- package/esm/benchmark/channels/noop.channel.d.mts.map +1 -0
- package/esm/benchmark/channels/noop.channel.mjs +8 -0
- package/esm/benchmark/channels/noop.channel.mjs.map +1 -0
- package/esm/benchmark/index.mjs +7 -0
- package/esm/benchmark/profiler.d.mts +67 -0
- package/esm/benchmark/profiler.d.mts.map +1 -0
- package/esm/benchmark/profiler.mjs +142 -0
- package/esm/benchmark/profiler.mjs.map +1 -0
- package/esm/benchmark/types.d.mts +164 -0
- package/esm/benchmark/types.d.mts.map +1 -0
- package/esm/bootstrap/setup.d.mts +5 -0
- package/esm/bootstrap/setup.d.mts.map +1 -0
- package/esm/bootstrap/setup.mjs +20 -0
- package/esm/bootstrap/setup.mjs.map +1 -0
- package/esm/bootstrap.d.mts +5 -0
- package/esm/bootstrap.d.mts.map +1 -0
- package/esm/bootstrap.mjs +14 -0
- package/esm/bootstrap.mjs.map +1 -0
- package/esm/cache/database-cache-driver.d.mts +60 -0
- package/esm/cache/database-cache-driver.d.mts.map +1 -0
- package/esm/cache/database-cache-driver.mjs +98 -0
- package/esm/cache/database-cache-driver.mjs.map +1 -0
- package/esm/cache/index.d.mts +1 -0
- package/esm/cache/index.mjs +9 -0
- package/esm/cache/index.mjs.map +1 -0
- package/esm/cli/cli-command.d.mts +119 -0
- package/esm/cli/cli-command.d.mts.map +1 -0
- package/esm/cli/cli-command.mjs +159 -0
- package/esm/cli/cli-command.mjs.map +1 -0
- package/esm/cli/cli-commands.manager.mjs +285 -0
- package/esm/cli/cli-commands.manager.mjs.map +1 -0
- package/esm/cli/cli-commands.utils.mjs +187 -0
- package/esm/cli/cli-commands.utils.mjs.map +1 -0
- package/esm/cli/commands/add.command.mjs +27 -0
- package/esm/cli/commands/add.command.mjs.map +1 -0
- package/esm/cli/commands/build.command.mjs +14 -0
- package/esm/cli/commands/build.command.mjs.map +1 -0
- package/esm/cli/commands/create-database.command.mjs +24 -0
- package/esm/cli/commands/create-database.command.mjs.map +1 -0
- package/esm/cli/commands/dev-server.command.mjs +48 -0
- package/esm/cli/commands/dev-server.command.mjs.map +1 -0
- package/esm/cli/commands/drop-tables.command.mjs +23 -0
- package/esm/cli/commands/drop-tables.command.mjs.map +1 -0
- package/esm/cli/commands/generate/generate.command.mjs +201 -0
- package/esm/cli/commands/generate/generate.command.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/column-dsl-parser.mjs +49 -0
- package/esm/cli/commands/generate/generators/column-dsl-parser.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/controller.generator.mjs +48 -0
- package/esm/cli/commands/generate/generators/controller.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/migration.generator.mjs +81 -0
- package/esm/cli/commands/generate/generators/migration.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/model.generator.mjs +60 -0
- package/esm/cli/commands/generate/generators/model.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/module.generator.mjs +113 -0
- package/esm/cli/commands/generate/generators/module.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/repository.generator.mjs +42 -0
- package/esm/cli/commands/generate/generators/repository.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/resource.generator.mjs +42 -0
- package/esm/cli/commands/generate/generators/resource.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/generators/service.generator.mjs +42 -0
- package/esm/cli/commands/generate/generators/service.generator.mjs.map +1 -0
- package/esm/cli/commands/generate/templates/stubs.mjs +514 -0
- package/esm/cli/commands/generate/templates/stubs.mjs.map +1 -0
- package/esm/cli/commands/generate/utils/name-parser.mjs +69 -0
- package/esm/cli/commands/generate/utils/name-parser.mjs.map +1 -0
- package/esm/cli/commands/generate/utils/path-resolver.mjs +56 -0
- package/esm/cli/commands/generate/utils/path-resolver.mjs.map +1 -0
- package/esm/cli/commands/generate/utils/prompt.mjs +28 -0
- package/esm/cli/commands/generate/utils/prompt.mjs.map +1 -0
- package/esm/cli/commands/generate/utils/writer.mjs +60 -0
- package/esm/cli/commands/generate/utils/writer.mjs.map +1 -0
- package/esm/cli/commands/migrate.command.mjs +60 -0
- package/esm/cli/commands/migrate.command.mjs.map +1 -0
- package/esm/cli/commands/seed.command.mjs +41 -0
- package/esm/cli/commands/seed.command.mjs.map +1 -0
- package/esm/cli/commands/start-production.command.mjs +50 -0
- package/esm/cli/commands/start-production.command.mjs.map +1 -0
- package/esm/cli/commands/storage-put.action.mjs +75 -0
- package/esm/cli/commands/storage-put.action.mjs.map +1 -0
- package/esm/cli/commands/storage-put.command.mjs +46 -0
- package/esm/cli/commands/storage-put.command.mjs.map +1 -0
- package/esm/cli/commands/typings-generator.command.mjs +38 -0
- package/esm/cli/commands/typings-generator.command.mjs.map +1 -0
- package/esm/cli/commands-loader.mjs +50 -0
- package/esm/cli/commands-loader.mjs.map +1 -0
- package/esm/cli/framework-cli-commands.mjs +37 -0
- package/esm/cli/framework-cli-commands.mjs.map +1 -0
- package/esm/cli/index.d.mts +2 -0
- package/esm/cli/parse-cli-args.mjs +62 -0
- package/esm/cli/parse-cli-args.mjs.map +1 -0
- package/esm/cli/start.d.mts +1 -0
- package/esm/cli/start.mjs +8 -0
- package/esm/cli/start.mjs.map +1 -0
- package/esm/cli/string-similarity.mjs +56 -0
- package/esm/cli/string-similarity.mjs.map +1 -0
- package/esm/cli/types.d.mts +216 -0
- package/esm/cli/types.d.mts.map +1 -0
- package/esm/config/config-getter.d.mts +38 -0
- package/esm/config/config-getter.d.mts.map +1 -0
- package/esm/config/config-getter.mjs +28 -0
- package/esm/config/config-getter.mjs.map +1 -0
- package/esm/config/config-handlers.d.mts +11 -0
- package/esm/config/config-handlers.d.mts.map +1 -0
- package/esm/config/config-handlers.mjs +23 -0
- package/esm/config/config-handlers.mjs.map +1 -0
- package/esm/config/config-loader.d.mts +9 -0
- package/esm/config/config-loader.d.mts.map +1 -0
- package/esm/config/config-loader.mjs +48 -0
- package/esm/config/config-loader.mjs.map +1 -0
- package/esm/config/config-manager.mjs +28 -0
- package/esm/config/config-manager.mjs.map +1 -0
- package/esm/config/config-special-handlers.d.mts +21 -0
- package/esm/config/config-special-handlers.d.mts.map +1 -0
- package/esm/config/config-special-handlers.mjs +25 -0
- package/esm/config/config-special-handlers.mjs.map +1 -0
- package/esm/config/index.mjs +5 -0
- package/esm/config/load-config-files.mjs +24 -0
- package/esm/config/load-config-files.mjs.map +1 -0
- package/esm/config/types.d.mts +53 -0
- package/esm/config/types.d.mts.map +1 -0
- package/esm/connectors/base-connector.d.mts +63 -0
- package/esm/connectors/base-connector.d.mts.map +1 -0
- package/esm/connectors/base-connector.mjs +52 -0
- package/esm/connectors/base-connector.mjs.map +1 -0
- package/esm/connectors/cache-connector.d.mts +28 -0
- package/esm/connectors/cache-connector.d.mts.map +1 -0
- package/esm/connectors/cache-connector.mjs +40 -0
- package/esm/connectors/cache-connector.mjs.map +1 -0
- package/esm/connectors/connectors-manager.d.mts +56 -0
- package/esm/connectors/connectors-manager.d.mts.map +1 -0
- package/esm/connectors/connectors-manager.mjs +105 -0
- package/esm/connectors/connectors-manager.mjs.map +1 -0
- package/esm/connectors/database-connector.d.mts +28 -0
- package/esm/connectors/database-connector.d.mts.map +1 -0
- package/esm/connectors/database-connector.mjs +53 -0
- package/esm/connectors/database-connector.mjs.map +1 -0
- package/esm/connectors/herald-connector.d.mts +28 -0
- package/esm/connectors/herald-connector.d.mts.map +1 -0
- package/esm/connectors/herald-connector.mjs +56 -0
- package/esm/connectors/herald-connector.mjs.map +1 -0
- package/esm/connectors/http-connector.d.mts +55 -0
- package/esm/connectors/http-connector.d.mts.map +1 -0
- package/esm/connectors/http-connector.mjs +107 -0
- package/esm/connectors/http-connector.mjs.map +1 -0
- package/esm/connectors/index.d.mts +11 -0
- package/esm/connectors/index.mjs +13 -0
- package/esm/connectors/logger-connector.d.mts +28 -0
- package/esm/connectors/logger-connector.d.mts.map +1 -0
- package/esm/connectors/logger-connector.mjs +52 -0
- package/esm/connectors/logger-connector.mjs.map +1 -0
- package/esm/connectors/mail-connector.d.mts +28 -0
- package/esm/connectors/mail-connector.d.mts.map +1 -0
- package/esm/connectors/mail-connector.mjs +56 -0
- package/esm/connectors/mail-connector.mjs.map +1 -0
- package/esm/connectors/socket-connector.d.mts +36 -0
- package/esm/connectors/socket-connector.d.mts.map +1 -0
- package/esm/connectors/socket-connector.mjs +82 -0
- package/esm/connectors/socket-connector.mjs.map +1 -0
- package/esm/connectors/storage.connector.d.mts +28 -0
- package/esm/connectors/storage.connector.d.mts.map +1 -0
- package/esm/connectors/storage.connector.mjs +40 -0
- package/esm/connectors/storage.connector.mjs.map +1 -0
- package/esm/connectors/types.d.mts +81 -0
- package/esm/connectors/types.d.mts.map +1 -0
- package/esm/connectors/types.mjs +33 -0
- package/esm/connectors/types.mjs.map +1 -0
- package/esm/container/index.d.mts +41 -0
- package/esm/container/index.d.mts.map +1 -0
- package/esm/container/index.mjs +27 -0
- package/esm/container/index.mjs.map +1 -0
- package/esm/database/create-database-action.mjs +32 -0
- package/esm/database/create-database-action.mjs.map +1 -0
- package/esm/database/drop-tables-action.mjs +35 -0
- package/esm/database/drop-tables-action.mjs.map +1 -0
- package/esm/database/index.d.mts +4 -0
- package/esm/database/index.mjs +6 -0
- package/esm/database/migrate-action.mjs +99 -0
- package/esm/database/migrate-action.mjs.map +1 -0
- package/esm/database/models/database-log/database-log.d.mts +19 -0
- package/esm/database/models/database-log/database-log.d.mts.map +1 -0
- package/esm/database/models/database-log/database-log.mjs +23 -0
- package/esm/database/models/database-log/database-log.mjs.map +1 -0
- package/esm/database/models/database-log/index.d.mts +1 -0
- package/esm/database/models/database-log/index.mjs +3 -0
- package/esm/database/seed-command-action.mjs +74 -0
- package/esm/database/seed-command-action.mjs.map +1 -0
- package/esm/database/seeds/seeder.d.mts +44 -0
- package/esm/database/seeds/seeder.d.mts.map +1 -0
- package/esm/database/seeds/seeder.mjs +11 -0
- package/esm/database/seeds/seeder.mjs.map +1 -0
- package/esm/database/seeds/seeders.manager.mjs +129 -0
- package/esm/database/seeds/seeders.manager.mjs.map +1 -0
- package/esm/database/seeds/seeds-table-migration.mjs +31 -0
- package/esm/database/seeds/seeds-table-migration.mjs.map +1 -0
- package/esm/database/seeds/types.d.mts +16 -0
- package/esm/database/seeds/types.d.mts.map +1 -0
- package/esm/database/seeds/utils.mjs +6 -0
- package/esm/database/seeds/utils.mjs.map +1 -0
- package/esm/database/utils.d.mts +20 -0
- package/esm/database/utils.d.mts.map +1 -0
- package/esm/database/utils.mjs +37 -0
- package/esm/database/utils.mjs.map +1 -0
- package/esm/dev-server/create-worker.mjs +41 -0
- package/esm/dev-server/create-worker.mjs.map +1 -0
- package/esm/dev-server/dependency-graph.d.mts +134 -0
- package/esm/dev-server/dependency-graph.d.mts.map +1 -0
- package/esm/dev-server/dependency-graph.mjs +303 -0
- package/esm/dev-server/dependency-graph.mjs.map +1 -0
- package/esm/dev-server/dev-logger.mjs +110 -0
- package/esm/dev-server/dev-logger.mjs.map +1 -0
- package/esm/dev-server/development-server.mjs +115 -0
- package/esm/dev-server/development-server.mjs.map +1 -0
- package/esm/dev-server/events.mjs +9 -0
- package/esm/dev-server/events.mjs.map +1 -0
- package/esm/dev-server/file-event-handler.mjs +98 -0
- package/esm/dev-server/file-event-handler.mjs.map +1 -0
- package/esm/dev-server/file-manager.d.mts +77 -0
- package/esm/dev-server/file-manager.d.mts.map +1 -0
- package/esm/dev-server/file-manager.mjs +157 -0
- package/esm/dev-server/file-manager.mjs.map +1 -0
- package/esm/dev-server/file-operations.d.mts +43 -0
- package/esm/dev-server/file-operations.d.mts.map +1 -0
- package/esm/dev-server/file-operations.mjs +113 -0
- package/esm/dev-server/file-operations.mjs.map +1 -0
- package/esm/dev-server/files-orchestrator.d.mts +89 -0
- package/esm/dev-server/files-orchestrator.d.mts.map +1 -0
- package/esm/dev-server/files-orchestrator.mjs +201 -0
- package/esm/dev-server/files-orchestrator.mjs.map +1 -0
- package/esm/dev-server/files-watcher.d.mts +69 -0
- package/esm/dev-server/files-watcher.d.mts.map +1 -0
- package/esm/dev-server/files-watcher.mjs +129 -0
- package/esm/dev-server/files-watcher.mjs.map +1 -0
- package/esm/dev-server/flags.mjs +9 -0
- package/esm/dev-server/flags.mjs.map +1 -0
- package/esm/dev-server/health-checker/checkers/base-health-checker.d.mts +55 -0
- package/esm/dev-server/health-checker/checkers/base-health-checker.d.mts.map +1 -0
- package/esm/dev-server/health-checker/checkers/base-health-checker.mjs +65 -0
- package/esm/dev-server/health-checker/checkers/base-health-checker.mjs.map +1 -0
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.d.mts +44 -0
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.d.mts.map +1 -0
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.mjs +155 -0
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.mjs.map +1 -0
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.d.mts +60 -0
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.d.mts.map +1 -0
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.mjs +192 -0
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.mjs.map +1 -0
- package/esm/dev-server/health-checker/file-health-checker.contract.d.mts +63 -0
- package/esm/dev-server/health-checker/file-health-checker.contract.d.mts.map +1 -0
- package/esm/dev-server/health-checker/file-health-result.d.mts +70 -0
- package/esm/dev-server/health-checker/file-health-result.d.mts.map +1 -0
- package/esm/dev-server/health-checker/file-health-result.mjs +41 -0
- package/esm/dev-server/health-checker/file-health-result.mjs.map +1 -0
- package/esm/dev-server/health-checker/files-healthcare.manager.d.mts +119 -0
- package/esm/dev-server/health-checker/files-healthcare.manager.d.mts.map +1 -0
- package/esm/dev-server/health-checker/files-healthcare.manager.mjs +346 -0
- package/esm/dev-server/health-checker/files-healthcare.manager.mjs.map +1 -0
- package/esm/dev-server/health-checker/index.mjs +7 -0
- package/esm/dev-server/health-checker/workers/eslint-health.worker.mjs +188 -0
- package/esm/dev-server/health-checker/workers/eslint-health.worker.mjs.map +1 -0
- package/esm/dev-server/health-checker/workers/ts-health.worker.mjs +212 -0
- package/esm/dev-server/health-checker/workers/ts-health.worker.mjs.map +1 -0
- package/esm/dev-server/layer-executor.mjs +114 -0
- package/esm/dev-server/layer-executor.mjs.map +1 -0
- package/esm/dev-server/loader/build-transpile-init.mjs +49 -0
- package/esm/dev-server/loader/build-transpile-init.mjs.map +1 -0
- package/esm/dev-server/loader/register-loader.mjs +68 -0
- package/esm/dev-server/loader/register-loader.mjs.map +1 -0
- package/esm/dev-server/loader/transpile-cache.mjs +57 -0
- package/esm/dev-server/loader/transpile-cache.mjs.map +1 -0
- package/esm/dev-server/manifest-manager.d.mts +71 -0
- package/esm/dev-server/manifest-manager.d.mts.map +1 -0
- package/esm/dev-server/manifest-manager.mjs +107 -0
- package/esm/dev-server/manifest-manager.mjs.map +1 -0
- package/esm/dev-server/module-loader.d.mts +51 -0
- package/esm/dev-server/module-loader.d.mts.map +1 -0
- package/esm/dev-server/module-loader.mjs +111 -0
- package/esm/dev-server/module-loader.mjs.map +1 -0
- package/esm/dev-server/package-json-manager.mjs +26 -0
- package/esm/dev-server/package-json-manager.mjs.map +1 -0
- package/esm/dev-server/parse-imports.mjs +348 -0
- package/esm/dev-server/parse-imports.mjs.map +1 -0
- package/esm/dev-server/path.mjs +63 -0
- package/esm/dev-server/path.mjs.map +1 -0
- package/esm/dev-server/special-files-collector.d.mts +23 -0
- package/esm/dev-server/special-files-collector.d.mts.map +1 -0
- package/esm/dev-server/special-files-collector.mjs +67 -0
- package/esm/dev-server/special-files-collector.mjs.map +1 -0
- package/esm/dev-server/start-development-server.mjs +63 -0
- package/esm/dev-server/start-development-server.mjs.map +1 -0
- package/esm/dev-server/tsconfig-manager.mjs +81 -0
- package/esm/dev-server/tsconfig-manager.mjs.map +1 -0
- package/esm/dev-server/type-generator.mjs +453 -0
- package/esm/dev-server/type-generator.mjs.map +1 -0
- package/esm/dev-server/types.d.mts +31 -0
- package/esm/dev-server/types.d.mts.map +1 -0
- package/esm/dev-server/utils.mjs +33 -0
- package/esm/dev-server/utils.mjs.map +1 -0
- package/esm/encryption/encrypt.d.mts +26 -0
- package/esm/encryption/encrypt.d.mts.map +1 -0
- package/esm/encryption/encrypt.mjs +81 -0
- package/esm/encryption/encrypt.mjs.map +1 -0
- package/esm/encryption/hash.d.mts +20 -0
- package/esm/encryption/hash.d.mts.map +1 -0
- package/esm/encryption/hash.mjs +31 -0
- package/esm/encryption/hash.mjs.map +1 -0
- package/esm/encryption/index.mjs +5 -0
- package/esm/encryption/password.d.mts +26 -0
- package/esm/encryption/password.d.mts.map +1 -0
- package/esm/encryption/password.mjs +73 -0
- package/esm/encryption/password.mjs.map +1 -0
- package/esm/encryption/types.d.mts +54 -0
- package/esm/encryption/types.d.mts.map +1 -0
- package/esm/generations/add-command.action.mjs +381 -0
- package/esm/generations/add-command.action.mjs.map +1 -0
- package/esm/generations/stubs.mjs +103 -0
- package/esm/generations/stubs.mjs.map +1 -0
- package/esm/http/config.d.mts +14 -0
- package/esm/http/config.d.mts.map +1 -0
- package/esm/http/config.mjs +26 -0
- package/esm/http/config.mjs.map +1 -0
- package/esm/http/context/request-context.d.mts +50 -0
- package/esm/http/context/request-context.d.mts.map +1 -0
- package/esm/http/context/request-context.mjs +59 -0
- package/esm/http/context/request-context.mjs.map +1 -0
- package/esm/http/createHttpApplication.d.mts +6 -0
- package/esm/http/createHttpApplication.d.mts.map +1 -0
- package/esm/http/createHttpApplication.mjs +38 -0
- package/esm/http/createHttpApplication.mjs.map +1 -0
- package/esm/http/database/RequestLog.d.mts +19 -0
- package/esm/http/database/RequestLog.d.mts.map +1 -0
- package/esm/http/database/RequestLog.mjs +32 -0
- package/esm/http/database/RequestLog.mjs.map +1 -0
- package/esm/http/error-codes.d.mts +44 -0
- package/esm/http/error-codes.d.mts.map +1 -0
- package/esm/http/error-codes.mjs +46 -0
- package/esm/http/error-codes.mjs.map +1 -0
- package/esm/http/errors/errors.d.mts +42 -0
- package/esm/http/errors/errors.d.mts.map +1 -0
- package/esm/http/errors/errors.mjs +70 -0
- package/esm/http/errors/errors.mjs.map +1 -0
- package/esm/http/events.d.mts +8 -0
- package/esm/http/events.d.mts.map +1 -0
- package/esm/http/events.mjs +29 -0
- package/esm/http/events.mjs.map +1 -0
- package/esm/http/index.d.mts +27 -0
- package/esm/http/index.mjs +22 -0
- package/esm/http/middleware/cache-response-middleware.d.mts +38 -0
- package/esm/http/middleware/cache-response-middleware.d.mts.map +1 -0
- package/esm/http/middleware/cache-response-middleware.mjs +39 -0
- package/esm/http/middleware/cache-response-middleware.mjs.map +1 -0
- package/esm/http/middleware/concurrency-limit.middleware.d.mts +53 -0
- package/esm/http/middleware/concurrency-limit.middleware.d.mts.map +1 -0
- package/esm/http/middleware/concurrency-limit.middleware.mjs +67 -0
- package/esm/http/middleware/concurrency-limit.middleware.mjs.map +1 -0
- package/esm/http/middleware/idempotency.middleware.d.mts +61 -0
- package/esm/http/middleware/idempotency.middleware.d.mts.map +1 -0
- package/esm/http/middleware/idempotency.middleware.mjs +88 -0
- package/esm/http/middleware/idempotency.middleware.mjs.map +1 -0
- package/esm/http/middleware/index.d.mts +11 -0
- package/esm/http/middleware/index.mjs +7 -0
- package/esm/http/middleware/inject-request-context.d.mts +25 -0
- package/esm/http/middleware/inject-request-context.d.mts.map +1 -0
- package/esm/http/middleware/inject-request-context.mjs +118 -0
- package/esm/http/middleware/inject-request-context.mjs.map +1 -0
- package/esm/http/middleware/ip-filter.middleware.d.mts +52 -0
- package/esm/http/middleware/ip-filter.middleware.d.mts.map +1 -0
- package/esm/http/middleware/ip-filter.middleware.mjs +51 -0
- package/esm/http/middleware/ip-filter.middleware.mjs.map +1 -0
- package/esm/http/middleware/maintenance.middleware.d.mts +49 -0
- package/esm/http/middleware/maintenance.middleware.d.mts.map +1 -0
- package/esm/http/middleware/maintenance.middleware.mjs +48 -0
- package/esm/http/middleware/maintenance.middleware.mjs.map +1 -0
- package/esm/http/middleware/max-body-size.middleware.d.mts +26 -0
- package/esm/http/middleware/max-body-size.middleware.d.mts.map +1 -0
- package/esm/http/middleware/max-body-size.middleware.mjs +46 -0
- package/esm/http/middleware/max-body-size.middleware.mjs.map +1 -0
- package/esm/http/middleware/middleware-list.d.mts +44 -0
- package/esm/http/middleware/middleware-list.d.mts.map +1 -0
- package/esm/http/middleware/middleware-list.mjs +45 -0
- package/esm/http/middleware/middleware-list.mjs.map +1 -0
- package/esm/http/middleware/rate-limit.middleware.d.mts +51 -0
- package/esm/http/middleware/rate-limit.middleware.d.mts.map +1 -0
- package/esm/http/middleware/rate-limit.middleware.mjs +70 -0
- package/esm/http/middleware/rate-limit.middleware.mjs.map +1 -0
- package/esm/http/middleware/utils/cidr-match.d.mts +12 -0
- package/esm/http/middleware/utils/cidr-match.d.mts.map +1 -0
- package/esm/http/middleware/utils/cidr-match.mjs +51 -0
- package/esm/http/middleware/utils/cidr-match.mjs.map +1 -0
- package/esm/http/middleware/utils/idempotency-key.d.mts +33 -0
- package/esm/http/middleware/utils/idempotency-key.d.mts.map +1 -0
- package/esm/http/middleware/utils/idempotency-key.mjs +51 -0
- package/esm/http/middleware/utils/idempotency-key.mjs.map +1 -0
- package/esm/http/middleware/utils/index.d.mts +3 -0
- package/esm/http/middleware/utils/parse-size.d.mts +5 -0
- package/esm/http/middleware/utils/parse-size.d.mts.map +1 -0
- package/esm/http/middleware/utils/parse-size.mjs +32 -0
- package/esm/http/middleware/utils/parse-size.mjs.map +1 -0
- package/esm/http/plugins.d.mts +7 -0
- package/esm/http/plugins.d.mts.map +1 -0
- package/esm/http/plugins.mjs +37 -0
- package/esm/http/plugins.mjs.map +1 -0
- package/esm/http/request-controller.d.mts +15 -0
- package/esm/http/request-controller.d.mts.map +1 -0
- package/esm/http/request-controller.mjs +11 -0
- package/esm/http/request-controller.mjs.map +1 -0
- package/esm/http/request.d.mts +458 -0
- package/esm/http/request.d.mts.map +1 -0
- package/esm/http/request.mjs +714 -0
- package/esm/http/request.mjs.map +1 -0
- package/esm/http/response.d.mts +452 -0
- package/esm/http/response.d.mts.map +1 -0
- package/esm/http/response.mjs +851 -0
- package/esm/http/response.mjs.map +1 -0
- package/esm/http/server.d.mts +12 -0
- package/esm/http/server.d.mts.map +1 -0
- package/esm/http/server.mjs +28 -0
- package/esm/http/server.mjs.map +1 -0
- package/esm/http/types.d.mts +326 -0
- package/esm/http/types.d.mts.map +1 -0
- package/esm/http/uploaded-file.d.mts +464 -0
- package/esm/http/uploaded-file.d.mts.map +1 -0
- package/esm/http/uploaded-file.mjs +579 -0
- package/esm/http/uploaded-file.mjs.map +1 -0
- package/esm/http/uploads-config.d.mts +30 -0
- package/esm/http/uploads-config.d.mts.map +1 -0
- package/esm/http/uploads-config.mjs +42 -0
- package/esm/http/uploads-config.mjs.map +1 -0
- package/esm/http/uploads-types.d.mts +240 -0
- package/esm/http/uploads-types.d.mts.map +1 -0
- package/esm/image/image.d.mts +389 -0
- package/esm/image/image.d.mts.map +1 -0
- package/esm/image/image.mjs +529 -0
- package/esm/image/image.mjs.map +1 -0
- package/esm/image/index.d.mts +1 -0
- package/esm/image/index.mjs +3 -0
- package/esm/index.d.mts +145 -0
- package/esm/index.mjs +145 -0
- package/esm/logger/index.d.mts +2 -0
- package/esm/logger/index.mjs +3 -0
- package/esm/logger/logger.d.mts +7 -0
- package/esm/logger/logger.d.mts.map +1 -0
- package/esm/logger/logger.mjs +17 -0
- package/esm/logger/logger.mjs.map +1 -0
- package/esm/logger/types.d.mts +42 -0
- package/esm/logger/types.d.mts.map +1 -0
- package/esm/mail/config.d.mts +84 -0
- package/esm/mail/config.d.mts.map +1 -0
- package/esm/mail/config.mjs +143 -0
- package/esm/mail/config.mjs.map +1 -0
- package/esm/mail/events.d.mts +99 -0
- package/esm/mail/events.d.mts.map +1 -0
- package/esm/mail/events.mjs +129 -0
- package/esm/mail/events.mjs.map +1 -0
- package/esm/mail/index.d.mts +8 -0
- package/esm/mail/index.mjs +10 -0
- package/esm/mail/mail.d.mts +178 -0
- package/esm/mail/mail.d.mts.map +1 -0
- package/esm/mail/mail.mjs +289 -0
- package/esm/mail/mail.mjs.map +1 -0
- package/esm/mail/mailer-pool.d.mts +31 -0
- package/esm/mail/mailer-pool.d.mts.map +1 -0
- package/esm/mail/mailer-pool.mjs +190 -0
- package/esm/mail/mailer-pool.mjs.map +1 -0
- package/esm/mail/react-mail.d.mts +16 -0
- package/esm/mail/react-mail.d.mts.map +1 -0
- package/esm/mail/react-mail.mjs +39 -0
- package/esm/mail/react-mail.mjs.map +1 -0
- package/esm/mail/send-mail.d.mts +37 -0
- package/esm/mail/send-mail.d.mts.map +1 -0
- package/esm/mail/send-mail.mjs +264 -0
- package/esm/mail/send-mail.mjs.map +1 -0
- package/esm/mail/test-mailbox.d.mts +50 -0
- package/esm/mail/test-mailbox.d.mts.map +1 -0
- package/esm/mail/test-mailbox.mjs +79 -0
- package/esm/mail/test-mailbox.mjs.map +1 -0
- package/esm/mail/types.d.mts +267 -0
- package/esm/mail/types.d.mts.map +1 -0
- package/esm/mail/types.mjs +16 -0
- package/esm/mail/types.mjs.map +1 -0
- package/esm/manifest/manifest-manager.mjs +79 -0
- package/esm/manifest/manifest-manager.mjs.map +1 -0
- package/esm/production/build-app-production.mjs +14 -0
- package/esm/production/build-app-production.mjs.map +1 -0
- package/esm/production/esbuild-plugins.mjs +37 -0
- package/esm/production/esbuild-plugins.mjs.map +1 -0
- package/esm/production/production-builder.mjs +264 -0
- package/esm/production/production-builder.mjs.map +1 -0
- package/esm/production/resolve-build-config.mjs +28 -0
- package/esm/production/resolve-build-config.mjs.map +1 -0
- package/esm/react/index.d.mts +18 -0
- package/esm/react/index.d.mts.map +1 -0
- package/esm/react/index.mjs +58 -0
- package/esm/react/index.mjs.map +1 -0
- package/esm/repositories/adapters/cascade/cascade-adapter.d.mts +91 -0
- package/esm/repositories/adapters/cascade/cascade-adapter.d.mts.map +1 -0
- package/esm/repositories/adapters/cascade/cascade-adapter.mjs +147 -0
- package/esm/repositories/adapters/cascade/cascade-adapter.mjs.map +1 -0
- package/esm/repositories/adapters/cascade/cascade-query-builder.d.mts +146 -0
- package/esm/repositories/adapters/cascade/cascade-query-builder.d.mts.map +1 -0
- package/esm/repositories/adapters/cascade/cascade-query-builder.mjs +238 -0
- package/esm/repositories/adapters/cascade/cascade-query-builder.mjs.map +1 -0
- package/esm/repositories/adapters/cascade/filter-applicator.mjs +381 -0
- package/esm/repositories/adapters/cascade/filter-applicator.mjs.map +1 -0
- package/esm/repositories/adapters/cascade/index.d.mts +2 -0
- package/esm/repositories/adapters/cascade/index.mjs +4 -0
- package/esm/repositories/contracts/index.d.mts +3 -0
- package/esm/repositories/contracts/query-builder.contract.d.mts +324 -0
- package/esm/repositories/contracts/query-builder.contract.d.mts.map +1 -0
- package/esm/repositories/contracts/repository-adapter.contract.d.mts +187 -0
- package/esm/repositories/contracts/repository-adapter.contract.d.mts.map +1 -0
- package/esm/repositories/contracts/types.d.mts +332 -0
- package/esm/repositories/contracts/types.d.mts.map +1 -0
- package/esm/repositories/index.d.mts +6 -0
- package/esm/repositories/index.mjs +6 -0
- package/esm/repositories/repository.manager.d.mts +700 -0
- package/esm/repositories/repository.manager.d.mts.map +1 -0
- package/esm/repositories/repository.manager.mjs +927 -0
- package/esm/repositories/repository.manager.mjs.map +1 -0
- package/esm/resource/define-resource.d.mts +69 -0
- package/esm/resource/define-resource.d.mts.map +1 -0
- package/esm/resource/define-resource.mjs +63 -0
- package/esm/resource/define-resource.mjs.map +1 -0
- package/esm/resource/index.d.mts +5 -0
- package/esm/resource/index.mjs +6 -0
- package/esm/resource/register-resource.d.mts +25 -0
- package/esm/resource/register-resource.d.mts.map +1 -0
- package/esm/resource/register-resource.mjs +30 -0
- package/esm/resource/register-resource.mjs.map +1 -0
- package/esm/resource/resource-field-builder.d.mts +108 -0
- package/esm/resource/resource-field-builder.d.mts.map +1 -0
- package/esm/resource/resource-field-builder.mjs +187 -0
- package/esm/resource/resource-field-builder.mjs.map +1 -0
- package/esm/resource/resource.d.mts +221 -0
- package/esm/resource/resource.d.mts.map +1 -0
- package/esm/resource/resource.mjs +239 -0
- package/esm/resource/resource.mjs.map +1 -0
- package/esm/resource/types.d.mts +77 -0
- package/esm/resource/types.d.mts.map +1 -0
- package/esm/restful/index.d.mts +1 -0
- package/esm/restful/index.mjs +3 -0
- package/esm/restful/restful.d.mts +115 -0
- package/esm/restful/restful.d.mts.map +1 -0
- package/esm/restful/restful.mjs +212 -0
- package/esm/restful/restful.mjs.map +1 -0
- package/esm/router/index.d.mts +2 -0
- package/esm/router/index.mjs +3 -0
- package/esm/router/route-builder.d.mts +124 -0
- package/esm/router/route-builder.d.mts.map +1 -0
- package/esm/router/route-builder.mjs +182 -0
- package/esm/router/route-builder.mjs.map +1 -0
- package/esm/router/route-registry.mjs +61 -0
- package/esm/router/route-registry.mjs.map +1 -0
- package/esm/router/router.d.mts +192 -0
- package/esm/router/router.d.mts.map +1 -0
- package/esm/router/router.mjs +498 -0
- package/esm/router/router.mjs.map +1 -0
- package/esm/router/types.d.mts +260 -0
- package/esm/router/types.d.mts.map +1 -0
- package/esm/socket/index.d.mts +2 -0
- package/esm/socket/index.mjs +3 -0
- package/esm/socket/types.d.mts +19 -0
- package/esm/socket/types.d.mts.map +1 -0
- package/esm/socket/utils.d.mts +10 -0
- package/esm/socket/utils.d.mts.map +1 -0
- package/esm/socket/utils.mjs +14 -0
- package/esm/socket/utils.mjs.map +1 -0
- package/esm/storage/config.d.mts +19 -0
- package/esm/storage/config.d.mts.map +1 -0
- package/esm/storage/config.mjs +38 -0
- package/esm/storage/config.mjs.map +1 -0
- package/esm/storage/context/storage-driver-context.d.mts +72 -0
- package/esm/storage/context/storage-driver-context.d.mts.map +1 -0
- package/esm/storage/context/storage-driver-context.mjs +87 -0
- package/esm/storage/context/storage-driver-context.mjs.map +1 -0
- package/esm/storage/drivers/cloud-driver.d.mts +208 -0
- package/esm/storage/drivers/cloud-driver.d.mts.map +1 -0
- package/esm/storage/drivers/cloud-driver.mjs +593 -0
- package/esm/storage/drivers/cloud-driver.mjs.map +1 -0
- package/esm/storage/drivers/do-spaces-driver.d.mts +47 -0
- package/esm/storage/drivers/do-spaces-driver.d.mts.map +1 -0
- package/esm/storage/drivers/do-spaces-driver.mjs +53 -0
- package/esm/storage/drivers/do-spaces-driver.mjs.map +1 -0
- package/esm/storage/drivers/local-driver.d.mts +157 -0
- package/esm/storage/drivers/local-driver.d.mts.map +1 -0
- package/esm/storage/drivers/local-driver.mjs +379 -0
- package/esm/storage/drivers/local-driver.mjs.map +1 -0
- package/esm/storage/drivers/r2-driver.d.mts +51 -0
- package/esm/storage/drivers/r2-driver.d.mts.map +1 -0
- package/esm/storage/drivers/r2-driver.mjs +58 -0
- package/esm/storage/drivers/r2-driver.mjs.map +1 -0
- package/esm/storage/drivers/s3-driver.d.mts +36 -0
- package/esm/storage/drivers/s3-driver.d.mts.map +1 -0
- package/esm/storage/drivers/s3-driver.mjs +40 -0
- package/esm/storage/drivers/s3-driver.mjs.map +1 -0
- package/esm/storage/index.d.mts +12 -0
- package/esm/storage/index.mjs +13 -0
- package/esm/storage/scoped-storage.d.mts +549 -0
- package/esm/storage/scoped-storage.d.mts.map +1 -0
- package/esm/storage/scoped-storage.mjs +693 -0
- package/esm/storage/scoped-storage.mjs.map +1 -0
- package/esm/storage/storage-file.d.mts +252 -0
- package/esm/storage/storage-file.d.mts.map +1 -0
- package/esm/storage/storage-file.mjs +363 -0
- package/esm/storage/storage-file.mjs.map +1 -0
- package/esm/storage/storage.d.mts +578 -0
- package/esm/storage/storage.d.mts.map +1 -0
- package/esm/storage/storage.mjs +871 -0
- package/esm/storage/storage.mjs.map +1 -0
- package/esm/storage/types.d.mts +967 -0
- package/esm/storage/types.d.mts.map +1 -0
- package/esm/storage/utils/mime.d.mts +36 -0
- package/esm/storage/utils/mime.d.mts.map +1 -0
- package/esm/storage/utils/mime.mjs +47 -0
- package/esm/storage/utils/mime.mjs.map +1 -0
- package/esm/tests/index.d.mts +3 -0
- package/esm/tests/index.mjs +5 -0
- package/esm/tests/start-http-development-server.d.mts +18 -0
- package/esm/tests/start-http-development-server.d.mts.map +1 -0
- package/esm/tests/start-http-development-server.mjs +74 -0
- package/esm/tests/start-http-development-server.mjs.map +1 -0
- package/esm/tests/test-helpers.d.mts +46 -0
- package/esm/tests/test-helpers.d.mts.map +1 -0
- package/esm/tests/test-helpers.mjs +99 -0
- package/esm/tests/test-helpers.mjs.map +1 -0
- package/esm/tests/vitest-setup.d.mts +14 -0
- package/esm/tests/vitest-setup.d.mts.map +1 -0
- package/esm/tests/vitest-setup.mjs +36 -0
- package/esm/tests/vitest-setup.mjs.map +1 -0
- package/esm/use-cases/index.d.mts +7 -0
- package/esm/use-cases/index.mjs +8 -0
- package/esm/use-cases/types.d.mts +306 -0
- package/esm/use-cases/types.d.mts.map +1 -0
- package/esm/use-cases/use-case-broadcast.d.mts +24 -0
- package/esm/use-cases/use-case-broadcast.d.mts.map +1 -0
- package/esm/use-cases/use-case-broadcast.mjs +36 -0
- package/esm/use-cases/use-case-broadcast.mjs.map +1 -0
- package/esm/use-cases/use-case-events.d.mts +40 -0
- package/esm/use-cases/use-case-events.d.mts.map +1 -0
- package/esm/use-cases/use-case-events.mjs +67 -0
- package/esm/use-cases/use-case-events.mjs.map +1 -0
- package/esm/use-cases/use-case-pipeline.d.mts +33 -0
- package/esm/use-cases/use-case-pipeline.d.mts.map +1 -0
- package/esm/use-cases/use-case-pipeline.mjs +47 -0
- package/esm/use-cases/use-case-pipeline.mjs.map +1 -0
- package/esm/use-cases/use-case.d.mts +35 -0
- package/esm/use-cases/use-case.d.mts.map +1 -0
- package/esm/use-cases/use-case.errors.d.mts +10 -0
- package/esm/use-cases/use-case.errors.d.mts.map +1 -0
- package/esm/use-cases/use-case.errors.mjs +15 -0
- package/esm/use-cases/use-case.errors.mjs.map +1 -0
- package/esm/use-cases/use-case.mjs +138 -0
- package/esm/use-cases/use-case.mjs.map +1 -0
- package/esm/use-cases/use-cases-registry.d.mts +41 -0
- package/esm/use-cases/use-cases-registry.d.mts.map +1 -0
- package/esm/use-cases/use-cases-registry.mjs +110 -0
- package/esm/use-cases/use-cases-registry.mjs.map +1 -0
- package/esm/utils/app-log.d.mts +11 -0
- package/esm/utils/app-log.d.mts.map +1 -0
- package/esm/utils/app-log.mjs +14 -0
- package/esm/utils/app-log.mjs.map +1 -0
- package/esm/utils/database-log.d.mts +28 -0
- package/esm/utils/database-log.d.mts.map +1 -0
- package/esm/utils/database-log.mjs +48 -0
- package/esm/utils/database-log.mjs.map +1 -0
- package/esm/utils/environment.d.mts +7 -0
- package/esm/utils/environment.d.mts.map +1 -0
- package/esm/utils/environment.mjs +11 -0
- package/esm/utils/environment.mjs.map +1 -0
- package/esm/utils/framework-vesion.mjs +24 -0
- package/esm/utils/framework-vesion.mjs.map +1 -0
- package/esm/utils/get-localized.d.mts +13 -0
- package/esm/utils/get-localized.d.mts.map +1 -0
- package/esm/utils/get-localized.mjs +17 -0
- package/esm/utils/get-localized.mjs.map +1 -0
- package/esm/utils/index.d.mts +11 -0
- package/esm/utils/index.mjs +13 -0
- package/esm/utils/paths.d.mts +72 -0
- package/esm/utils/paths.d.mts.map +1 -0
- package/esm/utils/paths.mjs +107 -0
- package/esm/utils/paths.mjs.map +1 -0
- package/esm/utils/promise-all-object.d.mts +9 -0
- package/esm/utils/promise-all-object.d.mts.map +1 -0
- package/esm/utils/promise-all-object.mjs +16 -0
- package/esm/utils/promise-all-object.mjs.map +1 -0
- package/esm/utils/queue.d.mts +52 -0
- package/esm/utils/queue.d.mts.map +1 -0
- package/esm/utils/queue.mjs +66 -0
- package/esm/utils/queue.mjs.map +1 -0
- package/esm/utils/sleep.d.mts +5 -0
- package/esm/utils/sleep.d.mts.map +1 -0
- package/esm/utils/sleep.mjs +8 -0
- package/esm/utils/sleep.mjs.map +1 -0
- package/esm/utils/sluggable.d.mts +10 -0
- package/esm/utils/sluggable.d.mts.map +1 -0
- package/esm/utils/sluggable.mjs +18 -0
- package/esm/utils/sluggable.mjs.map +1 -0
- package/esm/utils/to-json.d.mts +5 -0
- package/esm/utils/to-json.d.mts.map +1 -0
- package/esm/utils/to-json.mjs +23 -0
- package/esm/utils/to-json.mjs.map +1 -0
- package/esm/utils/types.d.mts +24 -0
- package/esm/utils/types.d.mts.map +1 -0
- package/esm/utils/urls.d.mts +24 -0
- package/esm/utils/urls.d.mts.map +1 -0
- package/esm/utils/urls.mjs +38 -0
- package/esm/utils/urls.mjs.map +1 -0
- package/esm/validation/database/exists-except-current-id.d.mts +11 -0
- package/esm/validation/database/exists-except-current-id.d.mts.map +1 -0
- package/esm/validation/database/exists-except-current-id.mjs +30 -0
- package/esm/validation/database/exists-except-current-id.mjs.map +1 -0
- package/esm/validation/database/exists-except-current-user.d.mts +11 -0
- package/esm/validation/database/exists-except-current-user.d.mts.map +1 -0
- package/esm/validation/database/exists-except-current-user.mjs +30 -0
- package/esm/validation/database/exists-except-current-user.mjs.map +1 -0
- package/esm/validation/database/index.d.mts +5 -0
- package/esm/validation/database/index.mjs +6 -0
- package/esm/validation/database/types.d.mts +32 -0
- package/esm/validation/database/types.d.mts.map +1 -0
- package/esm/validation/database/unique-except-current-id.d.mts +11 -0
- package/esm/validation/database/unique-except-current-id.d.mts.map +1 -0
- package/esm/validation/database/unique-except-current-id.mjs +30 -0
- package/esm/validation/database/unique-except-current-id.mjs.map +1 -0
- package/esm/validation/database/unique-except-current-user.d.mts +11 -0
- package/esm/validation/database/unique-except-current-user.d.mts.map +1 -0
- package/esm/validation/database/unique-except-current-user.mjs +35 -0
- package/esm/validation/database/unique-except-current-user.mjs.map +1 -0
- package/esm/validation/file/file.d.mts +26 -0
- package/esm/validation/file/file.d.mts.map +1 -0
- package/esm/validation/file/file.mjs +57 -0
- package/esm/validation/file/file.mjs.map +1 -0
- package/esm/validation/file/index.d.mts +1 -0
- package/esm/validation/file/index.mjs +3 -0
- package/esm/validation/index.d.mts +8 -0
- package/esm/validation/index.mjs +11 -0
- package/esm/validation/init.mjs +47 -0
- package/esm/validation/init.mjs.map +1 -0
- package/esm/validation/plugins/database-plugin.mjs +59 -0
- package/esm/validation/plugins/database-plugin.mjs.map +1 -0
- package/esm/validation/plugins/file-plugin.mjs +20 -0
- package/esm/validation/plugins/file-plugin.mjs.map +1 -0
- package/esm/validation/plugins/index.mjs +5 -0
- package/esm/validation/plugins/localized-plugin.mjs +21 -0
- package/esm/validation/plugins/localized-plugin.mjs.map +1 -0
- package/esm/validation/types.d.mts +71 -0
- package/esm/validation/types.d.mts.map +1 -0
- package/esm/validation/validateAll.mjs +53 -0
- package/esm/validation/validateAll.mjs.map +1 -0
- package/esm/validation/validators/file-validator.d.mts +65 -0
- package/esm/validation/validators/file-validator.d.mts.map +1 -0
- package/esm/validation/validators/file-validator.mjs +125 -0
- package/esm/validation/validators/file-validator.mjs.map +1 -0
- package/esm/validation/validators/index.d.mts +1 -0
- package/esm/validation/validators/index.mjs +3 -0
- package/esm/warlock-config/default-configurations.mjs +11 -0
- package/esm/warlock-config/default-configurations.mjs.map +1 -0
- package/esm/warlock-config/define-config.d.mts +7 -0
- package/esm/warlock-config/define-config.d.mts.map +1 -0
- package/esm/warlock-config/define-config.mjs +11 -0
- package/esm/warlock-config/define-config.mjs.map +1 -0
- package/esm/warlock-config/index.d.mts +3 -0
- package/esm/warlock-config/index.mjs +4 -0
- package/esm/warlock-config/types.d.mts +143 -0
- package/esm/warlock-config/types.d.mts.map +1 -0
- package/esm/warlock-config/warlock-config.manager.d.mts +86 -0
- package/esm/warlock-config/warlock-config.manager.d.mts.map +1 -0
- package/esm/warlock-config/warlock-config.manager.mjs +117 -0
- package/esm/warlock-config/warlock-config.manager.mjs.map +1 -0
- package/llms-full.txt +8233 -0
- package/llms.txt +41 -0
- package/package.json +93 -71
- package/skills/add-connector/SKILL.md +224 -0
- package/skills/benchmark-code/SKILL.md +256 -0
- package/skills/build-restful/SKILL.md +268 -0
- package/skills/build-url/SKILL.md +180 -0
- package/skills/configure-app/SKILL.md +219 -0
- package/skills/create-controller/SKILL.md +223 -0
- package/skills/create-module/SKILL.md +190 -0
- package/skills/define-resource/SKILL.md +297 -0
- package/skills/encrypt-data/SKILL.md +208 -0
- package/skills/hash-password/SKILL.md +183 -0
- package/skills/process-image/SKILL.md +169 -0
- package/skills/register-route/SKILL.md +159 -0
- package/skills/resolve-path/SKILL.md +170 -0
- package/skills/retry-operation/SKILL.md +109 -0
- package/skills/run-app/SKILL.md +256 -0
- package/skills/send-mail/SKILL.md +372 -0
- package/skills/send-response/SKILL.md +245 -0
- package/skills/store-file/SKILL.md +385 -0
- package/skills/test-http/SKILL.md +287 -0
- package/skills/test-service/SKILL.md +241 -0
- package/skills/upload-file/SKILL.md +297 -0
- package/skills/use-app-context/SKILL.md +240 -0
- package/skills/use-localization/SKILL.md +296 -0
- package/skills/use-middleware/SKILL.md +221 -0
- package/skills/use-model-transformers/SKILL.md +220 -0
- package/skills/use-repository/SKILL.md +393 -0
- package/skills/validate-input/SKILL.md +297 -0
- package/skills/warlock-conventions/SKILL.md +125 -0
- package/skills/wire-socket/SKILL.md +284 -0
- package/skills/write-cli-command/SKILL.md +289 -0
- package/skills/write-middleware/SKILL.md +220 -0
- package/skills/write-seeder/SKILL.md +279 -0
- package/skills/write-use-case/SKILL.md +293 -0
- package/esm/application/app.d.ts +0 -13
- package/esm/application/app.d.ts.map +0 -1
- package/esm/application/app.js +0 -29
- package/esm/application/app.js.map +0 -1
- package/esm/application/application-config-types.d.ts +0 -27
- package/esm/application/application-config-types.d.ts.map +0 -1
- package/esm/application/application.d.ts +0 -68
- package/esm/application/application.d.ts.map +0 -1
- package/esm/application/application.js +0 -94
- package/esm/application/application.js.map +0 -1
- package/esm/application/index.d.ts +0 -4
- package/esm/application/index.d.ts.map +0 -1
- package/esm/benchmark/benchmark-snapshots.d.ts +0 -47
- package/esm/benchmark/benchmark-snapshots.d.ts.map +0 -1
- package/esm/benchmark/benchmark-snapshots.js +0 -77
- package/esm/benchmark/benchmark-snapshots.js.map +0 -1
- package/esm/benchmark/benchmark.d.ts +0 -25
- package/esm/benchmark/benchmark.d.ts.map +0 -1
- package/esm/benchmark/benchmark.example.d.ts +0 -2
- package/esm/benchmark/benchmark.example.d.ts.map +0 -1
- package/esm/benchmark/benchmark.js +0 -120
- package/esm/benchmark/benchmark.js.map +0 -1
- package/esm/benchmark/channels/console.channel.d.ts +0 -14
- package/esm/benchmark/channels/console.channel.d.ts.map +0 -1
- package/esm/benchmark/channels/console.channel.js +0 -29
- package/esm/benchmark/channels/console.channel.js.map +0 -1
- package/esm/benchmark/channels/index.d.ts +0 -3
- package/esm/benchmark/channels/index.d.ts.map +0 -1
- package/esm/benchmark/channels/noop.channel.d.ts +0 -5
- package/esm/benchmark/channels/noop.channel.d.ts.map +0 -1
- package/esm/benchmark/channels/noop.channel.js +0 -3
- package/esm/benchmark/channels/noop.channel.js.map +0 -1
- package/esm/benchmark/index.d.ts +0 -7
- package/esm/benchmark/index.d.ts.map +0 -1
- package/esm/benchmark/profiler.d.ts +0 -63
- package/esm/benchmark/profiler.d.ts.map +0 -1
- package/esm/benchmark/profiler.js +0 -155
- package/esm/benchmark/profiler.js.map +0 -1
- package/esm/benchmark/types.d.ts +0 -167
- package/esm/benchmark/types.d.ts.map +0 -1
- package/esm/bootstrap/setup.d.ts +0 -2
- package/esm/bootstrap/setup.d.ts.map +0 -1
- package/esm/bootstrap/setup.js +0 -14
- package/esm/bootstrap/setup.js.map +0 -1
- package/esm/bootstrap.d.ts +0 -2
- package/esm/bootstrap.d.ts.map +0 -1
- package/esm/bootstrap.js +0 -5
- package/esm/bootstrap.js.map +0 -1
- package/esm/cache/database-cache-driver.d.ts +0 -56
- package/esm/cache/database-cache-driver.d.ts.map +0 -1
- package/esm/cache/database-cache-driver.js +0 -112
- package/esm/cache/database-cache-driver.js.map +0 -1
- package/esm/cache/index.d.ts +0 -3
- package/esm/cache/index.d.ts.map +0 -1
- package/esm/cache/index.js +0 -1
- package/esm/cache/index.js.map +0 -1
- package/esm/cli/cli-command.d.ts +0 -115
- package/esm/cli/cli-command.d.ts.map +0 -1
- package/esm/cli/cli-command.js +0 -227
- package/esm/cli/cli-command.js.map +0 -1
- package/esm/cli/cli-commands.manager.d.ts +0 -71
- package/esm/cli/cli-commands.manager.d.ts.map +0 -1
- package/esm/cli/cli-commands.manager.js +0 -362
- package/esm/cli/cli-commands.manager.js.map +0 -1
- package/esm/cli/cli-commands.utils.d.ts +0 -69
- package/esm/cli/cli-commands.utils.d.ts.map +0 -1
- package/esm/cli/cli-commands.utils.js +0 -180
- package/esm/cli/cli-commands.utils.js.map +0 -1
- package/esm/cli/commands/add.command.d.ts +0 -2
- package/esm/cli/commands/add.command.d.ts.map +0 -1
- package/esm/cli/commands/add.command.js +0 -15
- package/esm/cli/commands/add.command.js.map +0 -1
- package/esm/cli/commands/build.command.d.ts +0 -2
- package/esm/cli/commands/build.command.d.ts.map +0 -1
- package/esm/cli/commands/build.command.js +0 -8
- package/esm/cli/commands/build.command.js.map +0 -1
- package/esm/cli/commands/create-database.command.d.ts +0 -2
- package/esm/cli/commands/create-database.command.d.ts.map +0 -1
- package/esm/cli/commands/create-database.command.js +0 -18
- package/esm/cli/commands/create-database.command.js.map +0 -1
- package/esm/cli/commands/dev-server.command.d.ts +0 -2
- package/esm/cli/commands/dev-server.command.d.ts.map +0 -1
- package/esm/cli/commands/dev-server.command.js +0 -18
- package/esm/cli/commands/dev-server.command.js.map +0 -1
- package/esm/cli/commands/drop-tables.command.d.ts +0 -2
- package/esm/cli/commands/drop-tables.command.d.ts.map +0 -1
- package/esm/cli/commands/drop-tables.command.js +0 -17
- package/esm/cli/commands/drop-tables.command.js.map +0 -1
- package/esm/cli/commands/generate/generate.command.d.ts +0 -10
- package/esm/cli/commands/generate/generate.command.d.ts.map +0 -1
- package/esm/cli/commands/generate/generate.command.js +0 -188
- package/esm/cli/commands/generate/generate.command.js.map +0 -1
- package/esm/cli/commands/generate/generators/column-dsl-parser.d.ts +0 -11
- package/esm/cli/commands/generate/generators/column-dsl-parser.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/column-dsl-parser.js +0 -47
- package/esm/cli/commands/generate/generators/column-dsl-parser.js.map +0 -1
- package/esm/cli/commands/generate/generators/controller.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/controller.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/controller.generator.js +0 -51
- package/esm/cli/commands/generate/generators/controller.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/migration.generator.d.ts +0 -13
- package/esm/cli/commands/generate/generators/migration.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/migration.generator.js +0 -82
- package/esm/cli/commands/generate/generators/migration.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/model.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/model.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/model.generator.js +0 -58
- package/esm/cli/commands/generate/generators/model.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/module.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/module.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/module.generator.js +0 -149
- package/esm/cli/commands/generate/generators/module.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/repository.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/repository.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/repository.generator.js +0 -37
- package/esm/cli/commands/generate/generators/repository.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/resource.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/resource.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/resource.generator.js +0 -37
- package/esm/cli/commands/generate/generators/resource.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/service.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/service.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/service.generator.js +0 -37
- package/esm/cli/commands/generate/generators/service.generator.js.map +0 -1
- package/esm/cli/commands/generate/generators/validation.generator.d.ts +0 -3
- package/esm/cli/commands/generate/generators/validation.generator.d.ts.map +0 -1
- package/esm/cli/commands/generate/generators/validation.generator.js +0 -46
- package/esm/cli/commands/generate/generators/validation.generator.js.map +0 -1
- package/esm/cli/commands/generate/templates/stubs.d.ts +0 -129
- package/esm/cli/commands/generate/templates/stubs.d.ts.map +0 -1
- package/esm/cli/commands/generate/templates/stubs.js +0 -528
- package/esm/cli/commands/generate/templates/stubs.js.map +0 -1
- package/esm/cli/commands/generate/types.d.ts +0 -53
- package/esm/cli/commands/generate/types.d.ts.map +0 -1
- package/esm/cli/commands/generate/utils/name-parser.d.ts +0 -40
- package/esm/cli/commands/generate/utils/name-parser.d.ts.map +0 -1
- package/esm/cli/commands/generate/utils/name-parser.js +0 -65
- package/esm/cli/commands/generate/utils/name-parser.js.map +0 -1
- package/esm/cli/commands/generate/utils/path-resolver.d.ts +0 -30
- package/esm/cli/commands/generate/utils/path-resolver.d.ts.map +0 -1
- package/esm/cli/commands/generate/utils/path-resolver.js +0 -42
- package/esm/cli/commands/generate/utils/path-resolver.js.map +0 -1
- package/esm/cli/commands/generate/utils/prompt.d.ts +0 -13
- package/esm/cli/commands/generate/utils/prompt.d.ts.map +0 -1
- package/esm/cli/commands/generate/utils/prompt.js +0 -21
- package/esm/cli/commands/generate/utils/prompt.js.map +0 -1
- package/esm/cli/commands/migrate.command.d.ts +0 -2
- package/esm/cli/commands/migrate.command.d.ts.map +0 -1
- package/esm/cli/commands/migrate.command.js +0 -52
- package/esm/cli/commands/migrate.command.js.map +0 -1
- package/esm/cli/commands/seed.command.d.ts +0 -2
- package/esm/cli/commands/seed.command.d.ts.map +0 -1
- package/esm/cli/commands/seed.command.js +0 -29
- package/esm/cli/commands/seed.command.js.map +0 -1
- package/esm/cli/commands/start-production.command.d.ts +0 -2
- package/esm/cli/commands/start-production.command.d.ts.map +0 -1
- package/esm/cli/commands/start-production.command.js +0 -65
- package/esm/cli/commands/start-production.command.js.map +0 -1
- package/esm/cli/commands/storage-put.action.d.ts +0 -22
- package/esm/cli/commands/storage-put.action.d.ts.map +0 -1
- package/esm/cli/commands/storage-put.action.js +0 -75
- package/esm/cli/commands/storage-put.action.js.map +0 -1
- package/esm/cli/commands/storage-put.command.d.ts +0 -20
- package/esm/cli/commands/storage-put.command.d.ts.map +0 -1
- package/esm/cli/commands/storage-put.command.js +0 -41
- package/esm/cli/commands/storage-put.command.js.map +0 -1
- package/esm/cli/commands/typings-generator.command.d.ts +0 -2
- package/esm/cli/commands/typings-generator.command.d.ts.map +0 -1
- package/esm/cli/commands/typings-generator.command.js +0 -37
- package/esm/cli/commands/typings-generator.command.js.map +0 -1
- package/esm/cli/commands-loader.d.ts +0 -18
- package/esm/cli/commands-loader.d.ts.map +0 -1
- package/esm/cli/commands-loader.js +0 -45
- package/esm/cli/commands-loader.js.map +0 -1
- package/esm/cli/framework-cli-commands.d.ts +0 -2
- package/esm/cli/framework-cli-commands.d.ts.map +0 -1
- package/esm/cli/framework-cli-commands.js +0 -27
- package/esm/cli/framework-cli-commands.js.map +0 -1
- package/esm/cli/index.d.ts +0 -3
- package/esm/cli/index.d.ts.map +0 -1
- package/esm/cli/index.js +0 -1
- package/esm/cli/index.js.map +0 -1
- package/esm/cli/parse-cli-args.d.ts +0 -18
- package/esm/cli/parse-cli-args.d.ts.map +0 -1
- package/esm/cli/parse-cli-args.js +0 -82
- package/esm/cli/parse-cli-args.js.map +0 -1
- package/esm/cli/start.d.ts +0 -2
- package/esm/cli/start.d.ts.map +0 -1
- package/esm/cli/start.js +0 -2
- package/esm/cli/start.js.map +0 -1
- package/esm/cli/string-similarity.d.ts +0 -44
- package/esm/cli/string-similarity.d.ts.map +0 -1
- package/esm/cli/string-similarity.js +0 -57
- package/esm/cli/string-similarity.js.map +0 -1
- package/esm/cli/types.d.ts +0 -218
- package/esm/cli/types.d.ts.map +0 -1
- package/esm/config/config-getter.d.ts +0 -35
- package/esm/config/config-getter.d.ts.map +0 -1
- package/esm/config/config-getter.js +0 -21
- package/esm/config/config-getter.js.map +0 -1
- package/esm/config/config-handlers.d.ts +0 -7
- package/esm/config/config-handlers.d.ts.map +0 -1
- package/esm/config/config-handlers.js +0 -19
- package/esm/config/config-handlers.js.map +0 -1
- package/esm/config/config-loader.d.ts +0 -37
- package/esm/config/config-loader.d.ts.map +0 -1
- package/esm/config/config-loader.js +0 -85
- package/esm/config/config-loader.js.map +0 -1
- package/esm/config/config-manager.d.ts +0 -22
- package/esm/config/config-manager.d.ts.map +0 -1
- package/esm/config/config-manager.js +0 -25
- package/esm/config/config-manager.js.map +0 -1
- package/esm/config/config-special-handlers.d.ts +0 -17
- package/esm/config/config-special-handlers.d.ts.map +0 -1
- package/esm/config/config-special-handlers.js +0 -23
- package/esm/config/config-special-handlers.js.map +0 -1
- package/esm/config/index.d.ts +0 -5
- package/esm/config/index.d.ts.map +0 -1
- package/esm/config/load-config-files.d.ts +0 -6
- package/esm/config/load-config-files.d.ts.map +0 -1
- package/esm/config/load-config-files.js +0 -19
- package/esm/config/load-config-files.js.map +0 -1
- package/esm/config/types.d.ts +0 -52
- package/esm/config/types.d.ts.map +0 -1
- package/esm/connectors/base-connector.d.ts +0 -49
- package/esm/connectors/base-connector.d.ts.map +0 -1
- package/esm/connectors/base-connector.js +0 -48
- package/esm/connectors/base-connector.js.map +0 -1
- package/esm/connectors/cache-connector.d.ts +0 -23
- package/esm/connectors/cache-connector.d.ts.map +0 -1
- package/esm/connectors/cache-connector.js +0 -35
- package/esm/connectors/cache-connector.js.map +0 -1
- package/esm/connectors/connectors-manager.d.ts +0 -42
- package/esm/connectors/connectors-manager.d.ts.map +0 -1
- package/esm/connectors/connectors-manager.js +0 -94
- package/esm/connectors/connectors-manager.js.map +0 -1
- package/esm/connectors/database-connector.d.ts +0 -23
- package/esm/connectors/database-connector.d.ts.map +0 -1
- package/esm/connectors/database-connector.js +0 -52
- package/esm/connectors/database-connector.js.map +0 -1
- package/esm/connectors/herald-connector.d.ts +0 -23
- package/esm/connectors/herald-connector.d.ts.map +0 -1
- package/esm/connectors/herald-connector.js +0 -57
- package/esm/connectors/herald-connector.js.map +0 -1
- package/esm/connectors/http-connector.d.ts +0 -31
- package/esm/connectors/http-connector.d.ts.map +0 -1
- package/esm/connectors/http-connector.js +0 -85
- package/esm/connectors/http-connector.js.map +0 -1
- package/esm/connectors/index.d.ts +0 -16
- package/esm/connectors/index.d.ts.map +0 -1
- package/esm/connectors/logger-connector.d.ts +0 -23
- package/esm/connectors/logger-connector.d.ts.map +0 -1
- package/esm/connectors/logger-connector.js +0 -45
- package/esm/connectors/logger-connector.js.map +0 -1
- package/esm/connectors/mail-connector.d.ts +0 -23
- package/esm/connectors/mail-connector.d.ts.map +0 -1
- package/esm/connectors/mail-connector.js +0 -45
- package/esm/connectors/mail-connector.js.map +0 -1
- package/esm/connectors/socket-connector.d.ts +0 -25
- package/esm/connectors/socket-connector.d.ts.map +0 -1
- package/esm/connectors/socket-connector.js +0 -57
- package/esm/connectors/socket-connector.js.map +0 -1
- package/esm/connectors/storage.connector.d.ts +0 -23
- package/esm/connectors/storage.connector.d.ts.map +0 -1
- package/esm/connectors/storage.connector.js +0 -30
- package/esm/connectors/storage.connector.js.map +0 -1
- package/esm/connectors/types.d.ts +0 -55
- package/esm/connectors/types.d.ts.map +0 -1
- package/esm/connectors/types.js +0 -14
- package/esm/connectors/types.js.map +0 -1
- package/esm/container/index.d.ts +0 -38
- package/esm/container/index.d.ts.map +0 -1
- package/esm/container/index.js +0 -22
- package/esm/container/index.js.map +0 -1
- package/esm/database/create-database-action.d.ts +0 -3
- package/esm/database/create-database-action.d.ts.map +0 -1
- package/esm/database/create-database-action.js +0 -28
- package/esm/database/create-database-action.js.map +0 -1
- package/esm/database/drop-tables-action.d.ts +0 -3
- package/esm/database/drop-tables-action.d.ts.map +0 -1
- package/esm/database/drop-tables-action.js +0 -29
- package/esm/database/drop-tables-action.js.map +0 -1
- package/esm/database/index.d.ts +0 -4
- package/esm/database/index.d.ts.map +0 -1
- package/esm/database/migrate-action.d.ts +0 -8
- package/esm/database/migrate-action.d.ts.map +0 -1
- package/esm/database/migrate-action.js +0 -118
- package/esm/database/migrate-action.js.map +0 -1
- package/esm/database/models/database-log/database-log.d.ts +0 -16
- package/esm/database/models/database-log/database-log.d.ts.map +0 -1
- package/esm/database/models/database-log/database-log.js +0 -17
- package/esm/database/models/database-log/database-log.js.map +0 -1
- package/esm/database/models/database-log/index.d.ts +0 -2
- package/esm/database/models/database-log/index.d.ts.map +0 -1
- package/esm/database/seed-command-action.d.ts +0 -16
- package/esm/database/seed-command-action.d.ts.map +0 -1
- package/esm/database/seed-command-action.js +0 -68
- package/esm/database/seed-command-action.js.map +0 -1
- package/esm/database/seeds/index.d.ts +0 -3
- package/esm/database/seeds/index.d.ts.map +0 -1
- package/esm/database/seeds/seeder.d.ts +0 -40
- package/esm/database/seeds/seeder.d.ts.map +0 -1
- package/esm/database/seeds/seeder.js +0 -6
- package/esm/database/seeds/seeder.js.map +0 -1
- package/esm/database/seeds/seeders.manager.d.ts +0 -51
- package/esm/database/seeds/seeders.manager.d.ts.map +0 -1
- package/esm/database/seeds/seeders.manager.js +0 -150
- package/esm/database/seeds/seeders.manager.js.map +0 -1
- package/esm/database/seeds/seeds-table-migration.d.ts +0 -8
- package/esm/database/seeds/seeds-table-migration.d.ts.map +0 -1
- package/esm/database/seeds/seeds-table-migration.js +0 -18
- package/esm/database/seeds/seeds-table-migration.js.map +0 -1
- package/esm/database/seeds/types.d.ts +0 -13
- package/esm/database/seeds/types.d.ts.map +0 -1
- package/esm/database/seeds/utils.d.ts +0 -2
- package/esm/database/seeds/utils.d.ts.map +0 -1
- package/esm/database/seeds/utils.js +0 -1
- package/esm/database/seeds/utils.js.map +0 -1
- package/esm/database/utils.d.ts +0 -17
- package/esm/database/utils.d.ts.map +0 -1
- package/esm/database/utils.js +0 -30
- package/esm/database/utils.js.map +0 -1
- package/esm/dev-server/create-worker.d.ts +0 -34
- package/esm/dev-server/create-worker.d.ts.map +0 -1
- package/esm/dev-server/create-worker.js +0 -37
- package/esm/dev-server/create-worker.js.map +0 -1
- package/esm/dev-server/dependency-graph.d.ts +0 -102
- package/esm/dev-server/dependency-graph.d.ts.map +0 -1
- package/esm/dev-server/dependency-graph.js +0 -310
- package/esm/dev-server/dependency-graph.js.map +0 -1
- package/esm/dev-server/dev-logger.d.ts +0 -14
- package/esm/dev-server/dev-logger.d.ts.map +0 -1
- package/esm/dev-server/dev-logger.js +0 -130
- package/esm/dev-server/dev-logger.js.map +0 -1
- package/esm/dev-server/development-server.d.ts +0 -55
- package/esm/dev-server/development-server.d.ts.map +0 -1
- package/esm/dev-server/development-server.js +0 -199
- package/esm/dev-server/development-server.js.map +0 -1
- package/esm/dev-server/events.d.ts +0 -5
- package/esm/dev-server/events.d.ts.map +0 -1
- package/esm/dev-server/events.js +0 -4
- package/esm/dev-server/events.js.map +0 -1
- package/esm/dev-server/export-analyzer.d.ts +0 -84
- package/esm/dev-server/export-analyzer.d.ts.map +0 -1
- package/esm/dev-server/export-analyzer.js +0 -206
- package/esm/dev-server/export-analyzer.js.map +0 -1
- package/esm/dev-server/file-event-handler.d.ts +0 -156
- package/esm/dev-server/file-event-handler.d.ts.map +0 -1
- package/esm/dev-server/file-event-handler.js +0 -309
- package/esm/dev-server/file-event-handler.js.map +0 -1
- package/esm/dev-server/file-manager.d.ts +0 -394
- package/esm/dev-server/file-manager.d.ts.map +0 -1
- package/esm/dev-server/file-manager.js +0 -603
- package/esm/dev-server/file-manager.js.map +0 -1
- package/esm/dev-server/file-operations.d.ts +0 -203
- package/esm/dev-server/file-operations.d.ts.map +0 -1
- package/esm/dev-server/file-operations.js +0 -365
- package/esm/dev-server/file-operations.js.map +0 -1
- package/esm/dev-server/files-orchestrator.d.ts +0 -153
- package/esm/dev-server/files-orchestrator.d.ts.map +0 -1
- package/esm/dev-server/files-orchestrator.js +0 -349
- package/esm/dev-server/files-orchestrator.js.map +0 -1
- package/esm/dev-server/files-watcher.d.ts +0 -67
- package/esm/dev-server/files-watcher.d.ts.map +0 -1
- package/esm/dev-server/files-watcher.js +0 -121
- package/esm/dev-server/files-watcher.js.map +0 -1
- package/esm/dev-server/flags.d.ts +0 -10
- package/esm/dev-server/flags.d.ts.map +0 -1
- package/esm/dev-server/flags.js +0 -9
- package/esm/dev-server/flags.js.map +0 -1
- package/esm/dev-server/health-checker/checkers/base-health-checker.d.ts +0 -52
- package/esm/dev-server/health-checker/checkers/base-health-checker.d.ts.map +0 -1
- package/esm/dev-server/health-checker/checkers/base-health-checker.js +0 -71
- package/esm/dev-server/health-checker/checkers/base-health-checker.js.map +0 -1
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.d.ts +0 -40
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.d.ts.map +0 -1
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.js +0 -217
- package/esm/dev-server/health-checker/checkers/eslint-health-checker.js.map +0 -1
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.d.ts +0 -56
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.d.ts.map +0 -1
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.js +0 -279
- package/esm/dev-server/health-checker/checkers/typescript-health-checker.js.map +0 -1
- package/esm/dev-server/health-checker/file-health-checker.contract.d.ts +0 -59
- package/esm/dev-server/health-checker/file-health-checker.contract.d.ts.map +0 -1
- package/esm/dev-server/health-checker/file-health-result.d.ts +0 -68
- package/esm/dev-server/health-checker/file-health-result.d.ts.map +0 -1
- package/esm/dev-server/health-checker/file-health-result.js +0 -40
- package/esm/dev-server/health-checker/file-health-result.js.map +0 -1
- package/esm/dev-server/health-checker/files-healthcare.manager.d.ts +0 -115
- package/esm/dev-server/health-checker/files-healthcare.manager.d.ts.map +0 -1
- package/esm/dev-server/health-checker/files-healthcare.manager.js +0 -422
- package/esm/dev-server/health-checker/files-healthcare.manager.js.map +0 -1
- package/esm/dev-server/health-checker/index.d.ts +0 -6
- package/esm/dev-server/health-checker/index.d.ts.map +0 -1
- package/esm/dev-server/health-checker/workers/eslint-health.worker.d.ts +0 -2
- package/esm/dev-server/health-checker/workers/eslint-health.worker.d.ts.map +0 -1
- package/esm/dev-server/health-checker/workers/eslint-health.worker.js +0 -214
- package/esm/dev-server/health-checker/workers/eslint-health.worker.js.map +0 -1
- package/esm/dev-server/health-checker/workers/ts-health.worker.d.ts +0 -2
- package/esm/dev-server/health-checker/workers/ts-health.worker.d.ts.map +0 -1
- package/esm/dev-server/health-checker/workers/ts-health.worker.js +0 -261
- package/esm/dev-server/health-checker/workers/ts-health.worker.js.map +0 -1
- package/esm/dev-server/import-deduplicator.d.ts +0 -75
- package/esm/dev-server/import-deduplicator.d.ts.map +0 -1
- package/esm/dev-server/import-deduplicator.js +0 -288
- package/esm/dev-server/import-deduplicator.js.map +0 -1
- package/esm/dev-server/import-deduplicator.test.d.ts +0 -7
- package/esm/dev-server/import-deduplicator.test.d.ts.map +0 -1
- package/esm/dev-server/import-transformer.d.ts +0 -17
- package/esm/dev-server/import-transformer.d.ts.map +0 -1
- package/esm/dev-server/import-transformer.js +0 -221
- package/esm/dev-server/import-transformer.js.map +0 -1
- package/esm/dev-server/index.d.ts +0 -1
- package/esm/dev-server/index.d.ts.map +0 -1
- package/esm/dev-server/layer-executor.d.ts +0 -64
- package/esm/dev-server/layer-executor.d.ts.map +0 -1
- package/esm/dev-server/layer-executor.js +0 -338
- package/esm/dev-server/layer-executor.js.map +0 -1
- package/esm/dev-server/manifest-manager.d.ts +0 -80
- package/esm/dev-server/manifest-manager.d.ts.map +0 -1
- package/esm/dev-server/manifest-manager.js +0 -107
- package/esm/dev-server/manifest-manager.js.map +0 -1
- package/esm/dev-server/module-loader.d.ts +0 -111
- package/esm/dev-server/module-loader.d.ts.map +0 -1
- package/esm/dev-server/module-loader.js +0 -276
- package/esm/dev-server/module-loader.js.map +0 -1
- package/esm/dev-server/package-json-manager.d.ts +0 -16
- package/esm/dev-server/package-json-manager.d.ts.map +0 -1
- package/esm/dev-server/package-json-manager.js +0 -20
- package/esm/dev-server/package-json-manager.js.map +0 -1
- package/esm/dev-server/parse-imports.d.ts +0 -34
- package/esm/dev-server/parse-imports.d.ts.map +0 -1
- package/esm/dev-server/parse-imports.js +0 -426
- package/esm/dev-server/parse-imports.js.map +0 -1
- package/esm/dev-server/path.d.ts +0 -39
- package/esm/dev-server/path.d.ts.map +0 -1
- package/esm/dev-server/path.js +0 -56
- package/esm/dev-server/path.js.map +0 -1
- package/esm/dev-server/runtime-import-helper.d.ts +0 -8
- package/esm/dev-server/runtime-import-helper.d.ts.map +0 -1
- package/esm/dev-server/runtime-import-helper.js +0 -158
- package/esm/dev-server/runtime-import-helper.js.map +0 -1
- package/esm/dev-server/special-files-collector.d.ts +0 -114
- package/esm/dev-server/special-files-collector.d.ts.map +0 -1
- package/esm/dev-server/special-files-collector.js +0 -212
- package/esm/dev-server/special-files-collector.js.map +0 -1
- package/esm/dev-server/start-development-server.d.ts +0 -7
- package/esm/dev-server/start-development-server.d.ts.map +0 -1
- package/esm/dev-server/start-development-server.js +0 -21
- package/esm/dev-server/start-development-server.js.map +0 -1
- package/esm/dev-server/transpile-file.d.ts +0 -11
- package/esm/dev-server/transpile-file.d.ts.map +0 -1
- package/esm/dev-server/transpile-file.js +0 -30
- package/esm/dev-server/transpile-file.js.map +0 -1
- package/esm/dev-server/tsconfig-manager.d.ts +0 -45
- package/esm/dev-server/tsconfig-manager.d.ts.map +0 -1
- package/esm/dev-server/tsconfig-manager.js +0 -107
- package/esm/dev-server/tsconfig-manager.js.map +0 -1
- package/esm/dev-server/type-generator.d.ts +0 -115
- package/esm/dev-server/type-generator.d.ts.map +0 -1
- package/esm/dev-server/type-generator.js +0 -566
- package/esm/dev-server/type-generator.js.map +0 -1
- package/esm/dev-server/types.d.ts +0 -30
- package/esm/dev-server/types.d.ts.map +0 -1
- package/esm/dev-server/utils.d.ts +0 -15
- package/esm/dev-server/utils.d.ts.map +0 -1
- package/esm/dev-server/utils.js +0 -41
- package/esm/dev-server/utils.js.map +0 -1
- package/esm/encryption/encrypt.d.ts +0 -23
- package/esm/encryption/encrypt.d.ts.map +0 -1
- package/esm/encryption/encrypt.js +0 -85
- package/esm/encryption/encrypt.js.map +0 -1
- package/esm/encryption/hash.d.ts +0 -17
- package/esm/encryption/hash.d.ts.map +0 -1
- package/esm/encryption/hash.js +0 -26
- package/esm/encryption/hash.js.map +0 -1
- package/esm/encryption/index.d.ts +0 -5
- package/esm/encryption/index.d.ts.map +0 -1
- package/esm/encryption/password.d.ts +0 -23
- package/esm/encryption/password.d.ts.map +0 -1
- package/esm/encryption/password.js +0 -72
- package/esm/encryption/password.js.map +0 -1
- package/esm/encryption/types.d.ts +0 -51
- package/esm/encryption/types.d.ts.map +0 -1
- package/esm/generations/add-command.action.d.ts +0 -3
- package/esm/generations/add-command.action.d.ts.map +0 -1
- package/esm/generations/add-command.action.js +0 -382
- package/esm/generations/add-command.action.js.map +0 -1
- package/esm/generations/stubs.d.ts +0 -2
- package/esm/generations/stubs.d.ts.map +0 -1
- package/esm/generations/stubs.js +0 -81
- package/esm/generations/stubs.js.map +0 -1
- package/esm/http/config.d.ts +0 -10
- package/esm/http/config.d.ts.map +0 -1
- package/esm/http/config.js +0 -22
- package/esm/http/config.js.map +0 -1
- package/esm/http/context/request-context.d.ts +0 -47
- package/esm/http/context/request-context.d.ts.map +0 -1
- package/esm/http/context/request-context.js +0 -52
- package/esm/http/context/request-context.js.map +0 -1
- package/esm/http/createHttpApplication.d.ts +0 -3
- package/esm/http/createHttpApplication.d.ts.map +0 -1
- package/esm/http/createHttpApplication.js +0 -28
- package/esm/http/createHttpApplication.js.map +0 -1
- package/esm/http/database/RequestLog.d.ts +0 -16
- package/esm/http/database/RequestLog.d.ts.map +0 -1
- package/esm/http/database/RequestLog.js +0 -26
- package/esm/http/database/RequestLog.js.map +0 -1
- package/esm/http/errors/errors.d.ts +0 -39
- package/esm/http/errors/errors.d.ts.map +0 -1
- package/esm/http/errors/errors.js +0 -76
- package/esm/http/errors/errors.js.map +0 -1
- package/esm/http/errors/index.d.ts +0 -2
- package/esm/http/errors/index.d.ts.map +0 -1
- package/esm/http/events.d.ts +0 -4
- package/esm/http/events.d.ts.map +0 -1
- package/esm/http/events.js +0 -26
- package/esm/http/events.js.map +0 -1
- package/esm/http/index.d.ts +0 -17
- package/esm/http/index.d.ts.map +0 -1
- package/esm/http/middleware/cache-response-middleware.d.ts +0 -34
- package/esm/http/middleware/cache-response-middleware.d.ts.map +0 -1
- package/esm/http/middleware/cache-response-middleware.js +0 -45
- package/esm/http/middleware/cache-response-middleware.js.map +0 -1
- package/esm/http/middleware/index.d.ts +0 -3
- package/esm/http/middleware/index.d.ts.map +0 -1
- package/esm/http/middleware/inject-request-context.d.ts +0 -21
- package/esm/http/middleware/inject-request-context.d.ts.map +0 -1
- package/esm/http/middleware/inject-request-context.js +0 -119
- package/esm/http/middleware/inject-request-context.js.map +0 -1
- package/esm/http/plugins.d.ts +0 -3
- package/esm/http/plugins.d.ts.map +0 -1
- package/esm/http/plugins.js +0 -36
- package/esm/http/plugins.js.map +0 -1
- package/esm/http/request-controller.d.ts +0 -11
- package/esm/http/request-controller.d.ts.map +0 -1
- package/esm/http/request-controller.js +0 -9
- package/esm/http/request-controller.js.map +0 -1
- package/esm/http/request.d.ts +0 -400
- package/esm/http/request.d.ts.map +0 -1
- package/esm/http/request.js +0 -768
- package/esm/http/request.js.map +0 -1
- package/esm/http/response.d.ts +0 -379
- package/esm/http/response.d.ts.map +0 -1
- package/esm/http/response.js +0 -983
- package/esm/http/response.js.map +0 -1
- package/esm/http/server.d.ts +0 -8
- package/esm/http/server.d.ts.map +0 -1
- package/esm/http/server.js +0 -15
- package/esm/http/server.js.map +0 -1
- package/esm/http/types.d.ts +0 -230
- package/esm/http/types.d.ts.map +0 -1
- package/esm/http/uploaded-file.d.ts +0 -459
- package/esm/http/uploaded-file.d.ts.map +0 -1
- package/esm/http/uploaded-file.js +0 -709
- package/esm/http/uploaded-file.js.map +0 -1
- package/esm/http/uploads-config.d.ts +0 -26
- package/esm/http/uploads-config.d.ts.map +0 -1
- package/esm/http/uploads-config.js +0 -35
- package/esm/http/uploads-config.js.map +0 -1
- package/esm/http/uploads-types.d.ts +0 -236
- package/esm/http/uploads-types.d.ts.map +0 -1
- package/esm/image/image.d.ts +0 -388
- package/esm/image/image.d.ts.map +0 -1
- package/esm/image/image.js +0 -608
- package/esm/image/image.js.map +0 -1
- package/esm/image/index.d.ts +0 -2
- package/esm/image/index.d.ts.map +0 -1
- package/esm/index.d.ts +0 -36
- package/esm/index.d.ts.map +0 -1
- package/esm/index.js +0 -1
- package/esm/index.js.map +0 -1
- package/esm/logger/index.d.ts +0 -3
- package/esm/logger/index.d.ts.map +0 -1
- package/esm/logger/logger.d.ts +0 -3
- package/esm/logger/logger.d.ts.map +0 -1
- package/esm/logger/logger.js +0 -16
- package/esm/logger/logger.js.map +0 -1
- package/esm/logger/types.d.ts +0 -39
- package/esm/logger/types.d.ts.map +0 -1
- package/esm/mail/config.d.ts +0 -80
- package/esm/mail/config.d.ts.map +0 -1
- package/esm/mail/config.js +0 -158
- package/esm/mail/config.js.map +0 -1
- package/esm/mail/events.d.ts +0 -96
- package/esm/mail/events.d.ts.map +0 -1
- package/esm/mail/events.js +0 -123
- package/esm/mail/events.js.map +0 -1
- package/esm/mail/index.d.ts +0 -10
- package/esm/mail/index.d.ts.map +0 -1
- package/esm/mail/mail.d.ts +0 -175
- package/esm/mail/mail.d.ts.map +0 -1
- package/esm/mail/mail.js +0 -286
- package/esm/mail/mail.js.map +0 -1
- package/esm/mail/mailer-pool.d.ts +0 -27
- package/esm/mail/mailer-pool.d.ts.map +0 -1
- package/esm/mail/mailer-pool.js +0 -215
- package/esm/mail/mailer-pool.js.map +0 -1
- package/esm/mail/react-mail.d.ts +0 -12
- package/esm/mail/react-mail.d.ts.map +0 -1
- package/esm/mail/react-mail.js +0 -40
- package/esm/mail/react-mail.js.map +0 -1
- package/esm/mail/send-mail.d.ts +0 -33
- package/esm/mail/send-mail.d.ts.map +0 -1
- package/esm/mail/send-mail.js +0 -313
- package/esm/mail/send-mail.js.map +0 -1
- package/esm/mail/test-mailbox.d.ts +0 -110
- package/esm/mail/test-mailbox.d.ts.map +0 -1
- package/esm/mail/test-mailbox.js +0 -143
- package/esm/mail/test-mailbox.js.map +0 -1
- package/esm/mail/types.d.ts +0 -264
- package/esm/mail/types.d.ts.map +0 -1
- package/esm/mail/types.js +0 -13
- package/esm/mail/types.js.map +0 -1
- package/esm/manifest/manifest-manager.d.ts +0 -74
- package/esm/manifest/manifest-manager.d.ts.map +0 -1
- package/esm/manifest/manifest-manager.js +0 -88
- package/esm/manifest/manifest-manager.js.map +0 -1
- package/esm/production/build-app-production.d.ts +0 -6
- package/esm/production/build-app-production.d.ts.map +0 -1
- package/esm/production/build-app-production.js +0 -8
- package/esm/production/build-app-production.js.map +0 -1
- package/esm/production/esbuild-plugins.d.ts +0 -5
- package/esm/production/esbuild-plugins.d.ts.map +0 -1
- package/esm/production/esbuild-plugins.js +0 -23
- package/esm/production/esbuild-plugins.js.map +0 -1
- package/esm/production/production-builder.d.ts +0 -76
- package/esm/production/production-builder.d.ts.map +0 -1
- package/esm/production/production-builder.js +0 -254
- package/esm/production/production-builder.js.map +0 -1
- package/esm/react/index.d.ts +0 -14
- package/esm/react/index.d.ts.map +0 -1
- package/esm/react/index.js +0 -65
- package/esm/react/index.js.map +0 -1
- package/esm/repositories/adapters/cascade/cascade-adapter.d.ts +0 -85
- package/esm/repositories/adapters/cascade/cascade-adapter.d.ts.map +0 -1
- package/esm/repositories/adapters/cascade/cascade-adapter.js +0 -179
- package/esm/repositories/adapters/cascade/cascade-adapter.js.map +0 -1
- package/esm/repositories/adapters/cascade/cascade-query-builder.d.ts +0 -141
- package/esm/repositories/adapters/cascade/cascade-query-builder.d.ts.map +0 -1
- package/esm/repositories/adapters/cascade/cascade-query-builder.js +0 -281
- package/esm/repositories/adapters/cascade/cascade-query-builder.js.map +0 -1
- package/esm/repositories/adapters/cascade/filter-applicator.d.ts +0 -126
- package/esm/repositories/adapters/cascade/filter-applicator.d.ts.map +0 -1
- package/esm/repositories/adapters/cascade/filter-applicator.js +0 -549
- package/esm/repositories/adapters/cascade/filter-applicator.js.map +0 -1
- package/esm/repositories/adapters/cascade/index.d.ts +0 -7
- package/esm/repositories/adapters/cascade/index.d.ts.map +0 -1
- package/esm/repositories/contracts/index.d.ts +0 -8
- package/esm/repositories/contracts/index.d.ts.map +0 -1
- package/esm/repositories/contracts/query-builder.contract.d.ts +0 -320
- package/esm/repositories/contracts/query-builder.contract.d.ts.map +0 -1
- package/esm/repositories/contracts/repository-adapter.contract.d.ts +0 -183
- package/esm/repositories/contracts/repository-adapter.contract.d.ts.map +0 -1
- package/esm/repositories/contracts/types.d.ts +0 -328
- package/esm/repositories/contracts/types.d.ts.map +0 -1
- package/esm/repositories/index.d.ts +0 -8
- package/esm/repositories/index.d.ts.map +0 -1
- package/esm/repositories/repository.manager.d.ts +0 -694
- package/esm/repositories/repository.manager.d.ts.map +0 -1
- package/esm/repositories/repository.manager.js +0 -1123
- package/esm/repositories/repository.manager.js.map +0 -1
- package/esm/resource/define-resource.d.ts +0 -65
- package/esm/resource/define-resource.d.ts.map +0 -1
- package/esm/resource/define-resource.js +0 -62
- package/esm/resource/define-resource.js.map +0 -1
- package/esm/resource/index.d.ts +0 -6
- package/esm/resource/index.d.ts.map +0 -1
- package/esm/resource/register-resource.d.ts +0 -21
- package/esm/resource/register-resource.d.ts.map +0 -1
- package/esm/resource/register-resource.js +0 -23
- package/esm/resource/register-resource.js.map +0 -1
- package/esm/resource/resource-field-builder.d.ts +0 -104
- package/esm/resource/resource-field-builder.d.ts.map +0 -1
- package/esm/resource/resource-field-builder.js +0 -260
- package/esm/resource/resource-field-builder.js.map +0 -1
- package/esm/resource/resource.d.ts +0 -217
- package/esm/resource/resource.d.ts.map +0 -1
- package/esm/resource/resource.js +0 -307
- package/esm/resource/resource.js.map +0 -1
- package/esm/resource/types.d.ts +0 -74
- package/esm/resource/types.d.ts.map +0 -1
- package/esm/restful/index.d.ts +0 -2
- package/esm/restful/index.d.ts.map +0 -1
- package/esm/restful/restful.d.ts +0 -110
- package/esm/restful/restful.d.ts.map +0 -1
- package/esm/restful/restful.js +0 -317
- package/esm/restful/restful.js.map +0 -1
- package/esm/retry/index.d.ts +0 -3
- package/esm/retry/index.d.ts.map +0 -1
- package/esm/retry/retry.d.ts +0 -21
- package/esm/retry/retry.d.ts.map +0 -1
- package/esm/retry/retry.js +0 -39
- package/esm/retry/retry.js.map +0 -1
- package/esm/retry/types.d.ts +0 -27
- package/esm/retry/types.d.ts.map +0 -1
- package/esm/router/index.d.ts +0 -3
- package/esm/router/index.d.ts.map +0 -1
- package/esm/router/route-builder.d.ts +0 -120
- package/esm/router/route-builder.d.ts.map +0 -1
- package/esm/router/route-builder.js +0 -201
- package/esm/router/route-builder.js.map +0 -1
- package/esm/router/route-registry.d.ts +0 -30
- package/esm/router/route-registry.d.ts.map +0 -1
- package/esm/router/route-registry.js +0 -67
- package/esm/router/route-registry.js.map +0 -1
- package/esm/router/route.d.ts +0 -34
- package/esm/router/route.d.ts.map +0 -1
- package/esm/router/router.d.ts +0 -188
- package/esm/router/router.d.ts.map +0 -1
- package/esm/router/router.js +0 -606
- package/esm/router/router.js.map +0 -1
- package/esm/router/types.d.ts +0 -254
- package/esm/router/types.d.ts.map +0 -1
- package/esm/socket/index.d.ts +0 -3
- package/esm/socket/index.d.ts.map +0 -1
- package/esm/socket/types.d.ts +0 -16
- package/esm/socket/types.d.ts.map +0 -1
- package/esm/socket/utils.d.ts +0 -6
- package/esm/socket/utils.d.ts.map +0 -1
- package/esm/socket/utils.js +0 -9
- package/esm/socket/utils.js.map +0 -1
- package/esm/storage/config.d.ts +0 -15
- package/esm/storage/config.d.ts.map +0 -1
- package/esm/storage/config.js +0 -32
- package/esm/storage/config.js.map +0 -1
- package/esm/storage/context/storage-driver-context.d.ts +0 -69
- package/esm/storage/context/storage-driver-context.d.ts.map +0 -1
- package/esm/storage/context/storage-driver-context.js +0 -80
- package/esm/storage/context/storage-driver-context.js.map +0 -1
- package/esm/storage/drivers/cloud-driver.d.ts +0 -206
- package/esm/storage/drivers/cloud-driver.d.ts.map +0 -1
- package/esm/storage/drivers/cloud-driver.js +0 -721
- package/esm/storage/drivers/cloud-driver.js.map +0 -1
- package/esm/storage/drivers/do-spaces-driver.d.ts +0 -43
- package/esm/storage/drivers/do-spaces-driver.d.ts.map +0 -1
- package/esm/storage/drivers/do-spaces-driver.js +0 -50
- package/esm/storage/drivers/do-spaces-driver.js.map +0 -1
- package/esm/storage/drivers/local-driver.d.ts +0 -155
- package/esm/storage/drivers/local-driver.d.ts.map +0 -1
- package/esm/storage/drivers/local-driver.js +0 -450
- package/esm/storage/drivers/local-driver.js.map +0 -1
- package/esm/storage/drivers/r2-driver.d.ts +0 -47
- package/esm/storage/drivers/r2-driver.d.ts.map +0 -1
- package/esm/storage/drivers/r2-driver.js +0 -60
- package/esm/storage/drivers/r2-driver.js.map +0 -1
- package/esm/storage/drivers/s3-driver.d.ts +0 -32
- package/esm/storage/drivers/s3-driver.d.ts.map +0 -1
- package/esm/storage/drivers/s3-driver.js +0 -37
- package/esm/storage/drivers/s3-driver.js.map +0 -1
- package/esm/storage/index.d.ts +0 -13
- package/esm/storage/index.d.ts.map +0 -1
- package/esm/storage/scoped-storage.d.ts +0 -547
- package/esm/storage/scoped-storage.d.ts.map +0 -1
- package/esm/storage/scoped-storage.js +0 -739
- package/esm/storage/scoped-storage.js.map +0 -1
- package/esm/storage/storage-file.d.ts +0 -250
- package/esm/storage/storage-file.d.ts.map +0 -1
- package/esm/storage/storage-file.js +0 -417
- package/esm/storage/storage-file.js.map +0 -1
- package/esm/storage/storage.d.ts +0 -576
- package/esm/storage/storage.d.ts.map +0 -1
- package/esm/storage/storage.js +0 -939
- package/esm/storage/storage.js.map +0 -1
- package/esm/storage/types.d.ts +0 -966
- package/esm/storage/types.d.ts.map +0 -1
- package/esm/storage/utils/mime.d.ts +0 -33
- package/esm/storage/utils/mime.d.ts.map +0 -1
- package/esm/storage/utils/mime.js +0 -45
- package/esm/storage/utils/mime.js.map +0 -1
- package/esm/tests/index.d.ts +0 -9
- package/esm/tests/index.d.ts.map +0 -1
- package/esm/tests/start-http-development-server.d.ts +0 -15
- package/esm/tests/start-http-development-server.d.ts.map +0 -1
- package/esm/tests/start-http-development-server.js +0 -69
- package/esm/tests/start-http-development-server.js.map +0 -1
- package/esm/tests/test-helpers.d.ts +0 -43
- package/esm/tests/test-helpers.d.ts.map +0 -1
- package/esm/tests/test-helpers.js +0 -86
- package/esm/tests/test-helpers.js.map +0 -1
- package/esm/tests/vitest-setup.d.ts +0 -10
- package/esm/tests/vitest-setup.d.ts.map +0 -1
- package/esm/tests/vitest-setup.js +0 -36
- package/esm/tests/vitest-setup.js.map +0 -1
- package/esm/use-cases/index.d.ts +0 -7
- package/esm/use-cases/index.d.ts.map +0 -1
- package/esm/use-cases/types.d.ts +0 -267
- package/esm/use-cases/types.d.ts.map +0 -1
- package/esm/use-cases/use-case-events.d.ts +0 -33
- package/esm/use-cases/use-case-events.d.ts.map +0 -1
- package/esm/use-cases/use-case-events.js +0 -65
- package/esm/use-cases/use-case-events.js.map +0 -1
- package/esm/use-cases/use-case-pipeline.d.ts +0 -29
- package/esm/use-cases/use-case-pipeline.d.ts.map +0 -1
- package/esm/use-cases/use-case-pipeline.js +0 -45
- package/esm/use-cases/use-case-pipeline.js.map +0 -1
- package/esm/use-cases/use-case.d.ts +0 -27
- package/esm/use-cases/use-case.d.ts.map +0 -1
- package/esm/use-cases/use-case.errors.d.ts +0 -6
- package/esm/use-cases/use-case.errors.d.ts.map +0 -1
- package/esm/use-cases/use-case.errors.js +0 -8
- package/esm/use-cases/use-case.errors.js.map +0 -1
- package/esm/use-cases/use-case.js +0 -138
- package/esm/use-cases/use-case.js.map +0 -1
- package/esm/use-cases/use-cases-registry.d.ts +0 -38
- package/esm/use-cases/use-cases-registry.d.ts.map +0 -1
- package/esm/use-cases/use-cases-registry.js +0 -92
- package/esm/use-cases/use-cases-registry.js.map +0 -1
- package/esm/utils/app-log.d.ts +0 -8
- package/esm/utils/app-log.d.ts.map +0 -1
- package/esm/utils/app-log.js +0 -7
- package/esm/utils/app-log.js.map +0 -1
- package/esm/utils/cleanup-temp-files.d.ts +0 -5
- package/esm/utils/cleanup-temp-files.d.ts.map +0 -1
- package/esm/utils/database-log.d.ts +0 -25
- package/esm/utils/database-log.d.ts.map +0 -1
- package/esm/utils/database-log.js +0 -43
- package/esm/utils/database-log.js.map +0 -1
- package/esm/utils/download-file.d.ts +0 -3
- package/esm/utils/download-file.d.ts.map +0 -1
- package/esm/utils/environment.d.ts +0 -4
- package/esm/utils/environment.d.ts.map +0 -1
- package/esm/utils/environment.js +0 -6
- package/esm/utils/environment.js.map +0 -1
- package/esm/utils/framework-vesion.d.ts +0 -6
- package/esm/utils/framework-vesion.d.ts.map +0 -1
- package/esm/utils/framework-vesion.js +0 -18
- package/esm/utils/framework-vesion.js.map +0 -1
- package/esm/utils/get-localized.d.ts +0 -10
- package/esm/utils/get-localized.d.ts.map +0 -1
- package/esm/utils/get-localized.js +0 -15
- package/esm/utils/get-localized.js.map +0 -1
- package/esm/utils/index.d.ts +0 -12
- package/esm/utils/index.d.ts.map +0 -1
- package/esm/utils/internal.d.ts +0 -4
- package/esm/utils/internal.d.ts.map +0 -1
- package/esm/utils/paths.d.ts +0 -55
- package/esm/utils/paths.d.ts.map +0 -1
- package/esm/utils/paths.js +0 -89
- package/esm/utils/paths.js.map +0 -1
- package/esm/utils/promise-all-object.d.ts +0 -8
- package/esm/utils/promise-all-object.d.ts.map +0 -1
- package/esm/utils/promise-all-object.js +0 -12
- package/esm/utils/promise-all-object.js.map +0 -1
- package/esm/utils/queue.d.ts +0 -49
- package/esm/utils/queue.d.ts.map +0 -1
- package/esm/utils/queue.js +0 -89
- package/esm/utils/queue.js.map +0 -1
- package/esm/utils/sleep.d.ts +0 -2
- package/esm/utils/sleep.d.ts.map +0 -1
- package/esm/utils/sleep.js +0 -3
- package/esm/utils/sleep.js.map +0 -1
- package/esm/utils/sluggable.d.ts +0 -5
- package/esm/utils/sluggable.d.ts.map +0 -1
- package/esm/utils/sluggable.js +0 -15
- package/esm/utils/sluggable.js.map +0 -1
- package/esm/utils/to-json.d.ts +0 -2
- package/esm/utils/to-json.d.ts.map +0 -1
- package/esm/utils/to-json.js +0 -26
- package/esm/utils/to-json.js.map +0 -1
- package/esm/utils/types.d.ts +0 -22
- package/esm/utils/types.d.ts.map +0 -1
- package/esm/utils/urls.d.ts +0 -21
- package/esm/utils/urls.d.ts.map +0 -1
- package/esm/utils/urls.js +0 -31
- package/esm/utils/urls.js.map +0 -1
- package/esm/validation/database/exists-except-current-id.d.ts +0 -7
- package/esm/validation/database/exists-except-current-id.d.ts.map +0 -1
- package/esm/validation/database/exists-except-current-id.js +0 -24
- package/esm/validation/database/exists-except-current-id.js.map +0 -1
- package/esm/validation/database/exists-except-current-user.d.ts +0 -7
- package/esm/validation/database/exists-except-current-user.d.ts.map +0 -1
- package/esm/validation/database/exists-except-current-user.js +0 -26
- package/esm/validation/database/exists-except-current-user.js.map +0 -1
- package/esm/validation/database/exists.d.ts +0 -7
- package/esm/validation/database/exists.d.ts.map +0 -1
- package/esm/validation/database/exists.js +0 -22
- package/esm/validation/database/exists.js.map +0 -1
- package/esm/validation/database/index.d.ts +0 -12
- package/esm/validation/database/index.d.ts.map +0 -1
- package/esm/validation/database/types.d.ts +0 -68
- package/esm/validation/database/types.d.ts.map +0 -1
- package/esm/validation/database/unique-except-current-id.d.ts +0 -7
- package/esm/validation/database/unique-except-current-id.d.ts.map +0 -1
- package/esm/validation/database/unique-except-current-id.js +0 -24
- package/esm/validation/database/unique-except-current-id.js.map +0 -1
- package/esm/validation/database/unique-except-current-user.d.ts +0 -7
- package/esm/validation/database/unique-except-current-user.d.ts.map +0 -1
- package/esm/validation/database/unique-except-current-user.js +0 -29
- package/esm/validation/database/unique-except-current-user.js.map +0 -1
- package/esm/validation/database/unique.d.ts +0 -7
- package/esm/validation/database/unique.d.ts.map +0 -1
- package/esm/validation/database/unique.js +0 -31
- package/esm/validation/database/unique.js.map +0 -1
- package/esm/validation/file/file.d.ts +0 -22
- package/esm/validation/file/file.d.ts.map +0 -1
- package/esm/validation/file/file.js +0 -60
- package/esm/validation/file/file.js.map +0 -1
- package/esm/validation/file/index.d.ts +0 -6
- package/esm/validation/file/index.d.ts.map +0 -1
- package/esm/validation/index.d.ts +0 -16
- package/esm/validation/index.d.ts.map +0 -1
- package/esm/validation/init.d.ts +0 -7
- package/esm/validation/init.d.ts.map +0 -1
- package/esm/validation/init.js +0 -36
- package/esm/validation/init.js.map +0 -1
- package/esm/validation/plugins/database-plugin.d.ts +0 -14
- package/esm/validation/plugins/database-plugin.d.ts.map +0 -1
- package/esm/validation/plugins/database-plugin.js +0 -83
- package/esm/validation/plugins/database-plugin.js.map +0 -1
- package/esm/validation/plugins/file-plugin.d.ts +0 -11
- package/esm/validation/plugins/file-plugin.d.ts.map +0 -1
- package/esm/validation/plugins/file-plugin.js +0 -17
- package/esm/validation/plugins/file-plugin.js.map +0 -1
- package/esm/validation/plugins/index.d.ts +0 -9
- package/esm/validation/plugins/index.d.ts.map +0 -1
- package/esm/validation/plugins/localized-plugin.d.ts +0 -11
- package/esm/validation/plugins/localized-plugin.d.ts.map +0 -1
- package/esm/validation/plugins/localized-plugin.js +0 -19
- package/esm/validation/plugins/localized-plugin.js.map +0 -1
- package/esm/validation/types.d.ts +0 -87
- package/esm/validation/types.d.ts.map +0 -1
- package/esm/validation/validateAll.d.ts +0 -7
- package/esm/validation/validateAll.d.ts.map +0 -1
- package/esm/validation/validateAll.js +0 -60
- package/esm/validation/validateAll.js.map +0 -1
- package/esm/validation/validators/file-validator.d.ts +0 -62
- package/esm/validation/validators/file-validator.d.ts.map +0 -1
- package/esm/validation/validators/file-validator.js +0 -136
- package/esm/validation/validators/file-validator.js.map +0 -1
- package/esm/validation/validators/index.d.ts +0 -7
- package/esm/validation/validators/index.d.ts.map +0 -1
- package/esm/warlock-config/default-configurations.d.ts +0 -3
- package/esm/warlock-config/default-configurations.d.ts.map +0 -1
- package/esm/warlock-config/default-configurations.js +0 -8
- package/esm/warlock-config/default-configurations.js.map +0 -1
- package/esm/warlock-config/define-config.d.ts +0 -3
- package/esm/warlock-config/define-config.d.ts.map +0 -1
- package/esm/warlock-config/define-config.js +0 -3
- package/esm/warlock-config/define-config.js.map +0 -1
- package/esm/warlock-config/index.d.ts +0 -4
- package/esm/warlock-config/index.d.ts.map +0 -1
- package/esm/warlock-config/types.d.ts +0 -129
- package/esm/warlock-config/types.d.ts.map +0 -1
- package/esm/warlock-config/warlock-config.manager.d.ts +0 -83
- package/esm/warlock-config/warlock-config.manager.d.ts.map +0 -1
- package/esm/warlock-config/warlock-config.manager.js +0 -141
- package/esm/warlock-config/warlock-config.manager.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scoped-storage.mjs","names":["fs"],"sources":["../../../../../../@warlock.js/core/src/storage/scoped-storage.ts"],"sourcesContent":["import { fileExistsAsync } from \"@warlock.js/fs\";\r\nimport { createReadStream } from \"fs\";\r\nimport fs from \"fs/promises\";\r\nimport path from \"path\";\r\nimport type { Readable } from \"stream\";\r\nimport type { UploadedFile } from \"../http\";\r\nimport { StorageFile } from \"./storage-file\";\r\nimport type {\r\n DeleteManyResult,\r\n ListOptions,\r\n PutDirectoryOptions,\r\n PutDirectoryResult,\r\n PutOptions,\r\n ScopedStorageContract,\r\n StorageDriverContract,\r\n StorageDriverType,\r\n StorageFileInfo,\r\n} from \"./types\";\r\n\r\n/**\r\n * ScopedStorage - Base class for storage operations\r\n *\r\n * Wraps a storage driver and provides a consistent, developer-friendly API\r\n * that returns `StorageFile` instances instead of raw data objects.\r\n *\r\n * This class serves as the base for both direct driver usage and the\r\n * full `Storage` manager class.\r\n *\r\n * @example\r\n * ```typescript\r\n * // Using via storage.use()\r\n * const s3Storage = storage.use(\"s3\");\r\n * const file = await s3Storage.put(buffer, \"images/photo.jpg\");\r\n *\r\n * // file is a StorageFile instance with rich API\r\n * console.log(file.name); // \"photo.jpg\"\r\n * console.log(file.url); // \"https://...\"\r\n * await file.copy(\"backup/photo.jpg\");\r\n * ```\r\n */\r\nexport class ScopedStorage implements ScopedStorageContract {\r\n /**\r\n * The underlying storage driver instance\r\n * @internal\r\n */\r\n protected _driver: StorageDriverContract;\r\n\r\n /**\r\n * Create a new ScopedStorage instance\r\n *\r\n * @param driver - The storage driver to wrap\r\n */\r\n public constructor(driver: StorageDriverContract) {\r\n this._driver = driver;\r\n }\r\n\r\n // ============================================================\r\n // Properties\r\n // ============================================================\r\n\r\n /**\r\n * Get the driver name\r\n *\r\n * @returns The name identifier of the underlying driver (e.g., \"local\", \"s3\", \"r2\")\r\n */\r\n public get name(): StorageDriverType {\r\n return this.activeDriver.name;\r\n }\r\n\r\n /**\r\n * Get the default driver instance\r\n *\r\n * Use this for advanced operations that require direct driver access.\r\n *\r\n * @returns The raw storage driver\r\n */\r\n public get defaultDriver(): StorageDriverContract {\r\n return this._driver;\r\n }\r\n\r\n /**\r\n * Get the currently active driver\r\n *\r\n * Returns the driver being used for storage operations.\r\n * Can be overridden in subclasses for dynamic driver resolution (e.g., multi-tenant contexts).\r\n *\r\n * @returns The active storage driver\r\n */\r\n public get activeDriver(): StorageDriverContract {\r\n return this._driver;\r\n }\r\n\r\n // ============================================================\r\n // File Operations\r\n // ============================================================\r\n\r\n /**\r\n * Store a file in storage\r\n *\r\n * Accepts multiple input types and stores the file at the specified location.\r\n * Returns a `StorageFile` instance for further operations.\r\n *\r\n * @param file - File content as Buffer, string path, UploadedFile, or Readable stream\r\n * @param location - Destination path in storage (e.g., \"uploads/images/photo.jpg\")\r\n * @param options - Optional storage options\r\n * @returns StorageFile instance with cached metadata\r\n *\r\n * @example\r\n * ```typescript\r\n * // From buffer\r\n * const file = await storage.put(buffer, \"documents/report.pdf\");\r\n *\r\n * // From uploaded file\r\n * const file = await storage.put(uploadedFile, \"avatars/user-123.jpg\");\r\n *\r\n * // With options\r\n * const file = await storage.put(buffer, \"images/photo.jpg\", {\r\n * mimeType: \"image/jpeg\",\r\n * cacheControl: \"max-age=31536000\"\r\n * });\r\n * ```\r\n */\r\n public async put(\r\n file: UploadedFile | Buffer | string | Readable,\r\n location: string,\r\n options?: PutOptions,\r\n ): Promise<StorageFile> {\r\n const buffer = await this.toBuffer(file);\r\n const data = await this.activeDriver.put(buffer, location, options);\r\n return StorageFile.fromData(data, this.activeDriver);\r\n }\r\n\r\n /**\r\n * Store a file from a readable stream\r\n *\r\n * Optimized for large files - streams data directly without full buffering.\r\n * Ideal for file uploads, remote file fetching, or processing pipelines.\r\n *\r\n * @param stream - Readable stream of file content\r\n * @param location - Destination path in storage\r\n * @param options - Optional storage options\r\n * @returns StorageFile instance with cached metadata\r\n *\r\n * @example\r\n * ```typescript\r\n * import { createReadStream } from \"fs\";\r\n *\r\n * const stream = createReadStream(\"./large-video.mp4\");\r\n * const file = await storage.putStream(stream, \"videos/upload.mp4\");\r\n * ```\r\n */\r\n public async putStream(\r\n stream: Readable,\r\n location: string,\r\n options?: PutOptions,\r\n ): Promise<StorageFile> {\r\n const data = await this.activeDriver.putStream(stream, location, options);\r\n return StorageFile.fromData(data, this.activeDriver);\r\n }\r\n\r\n /**\r\n * Store a file from a URL\r\n *\r\n * Downloads the file from the URL and stores it.\r\n *\r\n * @param url - URL to download from\r\n * @param location - Destination path in storage\r\n * @param options - Optional storage options\r\n * @returns StorageFile instance\r\n *\r\n * @example\r\n * ```typescript\r\n * const file = await storage.putFromUrl(\r\n * \"https://example.com/image.jpg\",\r\n * \"images/downloaded.jpg\"\r\n * );\r\n * ```\r\n */\r\n public async putFromUrl(\r\n url: string,\r\n location: string,\r\n options?: PutOptions,\r\n ): Promise<StorageFile> {\r\n const response = await fetch(url);\r\n\r\n if (!response.ok) {\r\n throw new Error(`Failed to fetch file from ${url}: ${response.statusText}`);\r\n }\r\n\r\n const buffer = Buffer.from(await response.arrayBuffer());\r\n return this.put(buffer, location, options);\r\n }\r\n\r\n /**\r\n * Store a file from base64 data URL\r\n *\r\n * @param dataUrl - Data URL (data:image/png;base64,iVBORw0KG...)\r\n * @param location - Destination path in storage\r\n * @param options - Optional storage options\r\n * @returns StorageFile instance\r\n *\r\n * @example\r\n * ```typescript\r\n * const file = await storage.putFromBase64(\r\n * \"data:image/png;base64,iVBORw0KGgoAAAANS...\",\r\n * \"images/upload.png\"\r\n * );\r\n * ```\r\n */\r\n public async putFromBase64(\r\n dataUrl: string,\r\n location: string,\r\n options?: PutOptions,\r\n ): Promise<StorageFile> {\r\n // Parse data URL: data:image/png;base64,iVBORw0KG...\r\n const matches = dataUrl.match(/^data:([^;]+);base64,(.+)$/);\r\n\r\n if (!matches) {\r\n throw new Error(\"Invalid base64 data URL format. Expected: data:mime/type;base64,<data>\");\r\n }\r\n\r\n const [, mimeType, base64Data] = matches;\r\n const buffer = Buffer.from(base64Data, \"base64\");\r\n\r\n return this.put(buffer, location, {\r\n ...options,\r\n mimeType: options?.mimeType || mimeType,\r\n });\r\n }\r\n\r\n /**\r\n * Retrieve file contents as a Buffer\r\n *\r\n * Downloads the entire file into memory. For large files,\r\n * consider using `getStream()` instead.\r\n *\r\n * @param location - Path to the file in storage\r\n * @returns Buffer containing file contents\r\n * @throws Error if file not found\r\n *\r\n * @example\r\n * ```typescript\r\n * const buffer = await storage.get(\"documents/report.pdf\");\r\n * const content = buffer.toString(\"utf-8\");\r\n * ```\r\n */\r\n public async get(location: string): Promise<Buffer> {\r\n return this.activeDriver.get(location);\r\n }\r\n\r\n /**\r\n * Retrieve file contents as a readable stream\r\n *\r\n * Streams file data without loading entire file into memory.\r\n * Ideal for large files or when piping to a response.\r\n *\r\n * @param location - Path to the file in storage\r\n * @returns Readable stream of file contents\r\n * @throws Error if file not found\r\n *\r\n * @example\r\n * ```typescript\r\n * const stream = await storage.getStream(\"videos/large.mp4\");\r\n * stream.pipe(response.raw);\r\n * ```\r\n */\r\n public async getStream(location: string): Promise<Readable> {\r\n return this.activeDriver.getStream(location);\r\n }\r\n\r\n /**\r\n * Delete a file from storage\r\n *\r\n * @param location - Path to the file, or a StorageFile instance\r\n * @returns `true` if deleted, `false` if file not found\r\n *\r\n * @example\r\n * ```typescript\r\n * // By path\r\n * await storage.delete(\"temp/old-file.txt\");\r\n *\r\n * // From StorageFile instance\r\n * const file = await storage.put(buffer, \"temp/file.txt\");\r\n * await storage.delete(file);\r\n * ```\r\n */\r\n public async delete(location: string | StorageFile): Promise<boolean> {\r\n const path = typeof location === \"string\" ? location : location.path;\r\n return this.activeDriver.delete(path);\r\n }\r\n\r\n /**\r\n * Delete multiple files at once\r\n *\r\n * Performs batch deletion for efficiency. Returns results for each file\r\n * including success/failure status.\r\n *\r\n * @param locations - Array of file paths to delete\r\n * @returns Array of delete results with status for each file\r\n *\r\n * @example\r\n * ```typescript\r\n * const results = await storage.deleteMany([\r\n * \"temp/file1.txt\",\r\n * \"temp/file2.txt\",\r\n * \"temp/file3.txt\"\r\n * ]);\r\n *\r\n * for (const result of results) {\r\n * console.log(`${result.location}: ${result.deleted ? \"deleted\" : result.error}`);\r\n * }\r\n * ```\r\n */\r\n public async deleteMany(locations: string[]): Promise<DeleteManyResult[]> {\r\n return this.activeDriver.deleteMany(locations);\r\n }\r\n\r\n /**\r\n * Delete a directory\r\n *\r\n * @param directoryPath - Path to the directory\r\n */\r\n public async deleteDirectory(directoryPath: string): Promise<boolean> {\r\n return await this.activeDriver.deleteDirectory(directoryPath);\r\n }\r\n\r\n /**\r\n * Check if a file exists in storage\r\n *\r\n * @param location - Path to check\r\n * @returns `true` if file exists, `false` otherwise\r\n *\r\n * @example\r\n * ```typescript\r\n * if (await storage.exists(\"config/settings.json\")) {\r\n * const config = await storage.get(\"config/settings.json\");\r\n * }\r\n * ```\r\n */\r\n public async exists(location: string): Promise<boolean> {\r\n return this.activeDriver.exists(location);\r\n }\r\n\r\n /**\r\n * Copy a file to a new location\r\n *\r\n * Creates a copy of the file at the destination path.\r\n * The original file remains unchanged.\r\n *\r\n * @param from - Source path or StorageFile instance\r\n * @param to - Destination path\r\n * @returns StorageFile instance at the new location\r\n *\r\n * @example\r\n * ```typescript\r\n * // Copy by path\r\n * const backup = await storage.copy(\"documents/report.pdf\", \"backups/report.pdf\");\r\n *\r\n * // Copy from StorageFile\r\n * const original = await storage.file(\"documents/report.pdf\");\r\n * const backup = await storage.copy(original, \"backups/report.pdf\");\r\n * ```\r\n */\r\n public async copy(from: string | StorageFile, to: string): Promise<StorageFile> {\r\n const fromPath = typeof from === \"string\" ? from : from.path;\r\n const data = await this.activeDriver.copy(fromPath, to);\r\n return StorageFile.fromData(data, this.activeDriver);\r\n }\r\n\r\n /**\r\n * Move a file to a new location\r\n *\r\n * Moves the file to the destination path. The original file\r\n * is deleted after successful copy.\r\n *\r\n * @param from - Source path or StorageFile instance\r\n * @param to - Destination path\r\n * @returns StorageFile instance at the new location\r\n *\r\n * @example\r\n * ```typescript\r\n * // Move by path\r\n * const file = await storage.move(\"uploads/temp.jpg\", \"images/photo.jpg\");\r\n *\r\n * // Move from StorageFile\r\n * const temp = await storage.file(\"uploads/temp.jpg\");\r\n * const final = await storage.move(temp, \"images/photo.jpg\");\r\n * ```\r\n */\r\n public async move(from: string | StorageFile, to: string): Promise<StorageFile> {\r\n const fromPath = typeof from === \"string\" ? from : from.path;\r\n const data = await this.activeDriver.move(fromPath, to);\r\n return StorageFile.fromData(data, this.activeDriver);\r\n }\r\n\r\n /**\r\n * Copy an entire directory recursively\r\n *\r\n * Copies all files from the source directory to the destination directory,\r\n * preserving the directory structure.\r\n *\r\n * @param from - Source directory path\r\n * @param to - Destination directory path\r\n * @param options - Optional concurrency control\r\n * @returns Number of files copied\r\n *\r\n * @example\r\n * ```typescript\r\n * // Copy entire directory\r\n * const count = await storage.copyDirectory(\"uploads/temp\", \"uploads/final\");\r\n * console.log(`Copied ${count} files`);\r\n *\r\n * // With concurrency limit\r\n * const count = await storage.copyDirectory(\"large-dir\", \"backup\", {\r\n * concurrency: 10\r\n * });\r\n * ```\r\n */\r\n public async copyDirectory(\r\n from: string,\r\n to: string,\r\n options?: { concurrency?: number },\r\n ): Promise<number> {\r\n const concurrency = options?.concurrency || 5;\r\n\r\n // List all files recursively\r\n const files = await this.list(from, { recursive: true });\r\n const filesToCopy = files.filter((f) => !f.isDirectory);\r\n\r\n // Copy files in batches for efficiency\r\n let copied = 0;\r\n for (let i = 0; i < filesToCopy.length; i += concurrency) {\r\n const batch = filesToCopy.slice(i, i + concurrency);\r\n await Promise.all(\r\n batch.map(async (file) => {\r\n // Calculate relative path and new destination\r\n const relativePath = file.path.substring(from.length).replace(/^\\//, \"\");\r\n const newPath = `${to}/${relativePath}`;\r\n await this.copy(file.path, newPath);\r\n copied++;\r\n }),\r\n );\r\n }\r\n\r\n return copied;\r\n }\r\n\r\n /**\r\n * Move an entire directory recursively\r\n *\r\n * Moves all files from the source directory to the destination directory,\r\n * then deletes the source directory.\r\n *\r\n * @param from - Source directory path\r\n * @param to - Destination directory path\r\n * @param options - Optional concurrency control\r\n * @returns Number of files moved\r\n *\r\n * @example\r\n * ```typescript\r\n * const count = await storage.moveDirectory(\"uploads/temp\", \"uploads/final\");\r\n * console.log(`Moved ${count} files`);\r\n * ```\r\n */\r\n public async moveDirectory(\r\n from: string,\r\n to: string,\r\n options?: { concurrency?: number },\r\n ): Promise<number> {\r\n // Copy all files first\r\n const count = await this.copyDirectory(from, to, options);\r\n\r\n // Delete source directory\r\n await this.deleteDirectory(from);\r\n\r\n return count;\r\n }\r\n\r\n /**\r\n * Upload a local filesystem directory into storage\r\n *\r\n * Recursively walks the local directory, applies an optional filter, then\r\n * streams each file into storage. Uploads run in concurrent batches for\r\n * efficiency. Failures are collected — a single failed file never aborts\r\n * the entire operation (mirrors the contract of `deleteMany`).\r\n *\r\n * @param localDirPath - Absolute path of the local directory to upload\r\n * @param destination - Target prefix in storage (e.g. \"uploads/assets\")\r\n * @param options - Concurrency, filter, progress callback, put options\r\n * @returns - { uploaded, failed, total }\r\n *\r\n * @example\r\n * ```typescript\r\n * const result = await storage.putDirectory(\"./public/assets\", \"cdn/assets\", {\r\n * concurrency: 10,\r\n * filter: (_, rel) => !rel.startsWith(\".\"),\r\n * onProgress: (done, total) => console.log(`${done}/${total}`),\r\n * });\r\n *\r\n * console.log(`Uploaded: ${result.uploaded.length}, Failed: ${result.failed.length}`);\r\n * ```\r\n */\r\n public async putDirectory(\r\n localDirPath: string,\r\n destination: string,\r\n options?: PutDirectoryOptions,\r\n ): Promise<PutDirectoryResult> {\r\n const concurrency = options?.concurrency ?? 5;\r\n\r\n // Collect all local file paths recursively\r\n const localFiles = await this.walkLocalDirectory(localDirPath);\r\n\r\n // Apply the user-supplied filter if any\r\n const filteredFiles = options?.filter\r\n ? localFiles.filter(({ absolute, relative }) => options.filter!(absolute, relative))\r\n : localFiles;\r\n\r\n const total = filteredFiles.length;\r\n const uploaded: StorageFile[] = [];\r\n const failed: Array<{ localPath: string; error: Error }> = [];\r\n let doneCount = 0;\r\n\r\n // Upload in concurrent batches\r\n for (let i = 0; i < filteredFiles.length; i += concurrency) {\r\n const batch = filteredFiles.slice(i, i + concurrency);\r\n\r\n await Promise.all(\r\n batch.map(async ({ absolute, relative }) => {\r\n const storagePath = `${destination.replace(/\\/$/, \"\")}/${relative}`;\r\n\r\n try {\r\n const stream = createReadStream(absolute);\r\n const file = await this.putStream(stream, storagePath, options?.putOptions);\r\n uploaded.push(file);\r\n doneCount++;\r\n options?.onProgress?.(doneCount, total, file);\r\n } catch (err) {\r\n failed.push({\r\n localPath: absolute,\r\n error: err instanceof Error ? err : new Error(String(err)),\r\n });\r\n }\r\n }),\r\n );\r\n }\r\n\r\n return { uploaded, failed, total };\r\n }\r\n\r\n /**\r\n * Walk a local directory recursively and return all file paths\r\n *\r\n * @param dirPath - Absolute local directory path\r\n * @returns Array of { absolute, relative } file path pairs\r\n * @internal\r\n */\r\n private async walkLocalDirectory(\r\n dirPath: string,\r\n baseDir?: string,\r\n ): Promise<Array<{ absolute: string; relative: string }>> {\r\n const root = baseDir ?? dirPath;\r\n const entries = await fs.readdir(dirPath, { withFileTypes: true });\r\n const results: Array<{ absolute: string; relative: string }> = [];\r\n\r\n for (const entry of entries) {\r\n const absolute = path.join(dirPath, entry.name);\r\n const relative = path.relative(root, absolute).replace(/\\\\/g, \"/\");\r\n\r\n if (entry.isDirectory()) {\r\n const nested = await this.walkLocalDirectory(absolute, root);\r\n results.push(...nested);\r\n } else if (entry.isFile()) {\r\n results.push({ absolute, relative });\r\n }\r\n // Symlinks are intentionally skipped\r\n }\r\n\r\n return results;\r\n }\r\n\r\n /**\r\n * Empty a directory without deleting the directory itself\r\n *\r\n * Deletes all files within the directory but preserves the directory structure.\r\n *\r\n * @param path - Directory path to empty\r\n * @returns Number of files deleted\r\n *\r\n * @example\r\n * ```typescript\r\n * const count = await storage.emptyDirectory(\"uploads/temp\");\r\n * console.log(`Deleted ${count} files`);\r\n * ```\r\n */\r\n public async emptyDirectory(path: string): Promise<number> {\r\n // List all files in directory\r\n const files = await this.list(path, { recursive: true });\r\n const filePaths = files.filter((f) => !f.isDirectory).map((f) => f.path);\r\n\r\n if (filePaths.length === 0) {\r\n return 0;\r\n }\r\n\r\n // Delete all files\r\n await this.deleteMany(filePaths);\r\n\r\n return filePaths.length;\r\n }\r\n\r\n /**\r\n * List files in a directory\r\n *\r\n * Returns file information for all files in the specified directory.\r\n * Supports recursive listing and pagination.\r\n *\r\n * @param directory - Directory path (defaults to root)\r\n * @param options - List options (recursive, limit, cursor)\r\n * @returns Array of file information objects\r\n *\r\n * @example\r\n * ```typescript\r\n * // List all files in uploads\r\n * const files = await storage.list(\"uploads\");\r\n *\r\n * // Recursive listing with limit\r\n * const files = await storage.list(\"uploads\", {\r\n * recursive: true,\r\n * limit: 100\r\n * });\r\n * ```\r\n */\r\n public async list(directory?: string, options?: ListOptions): Promise<StorageFileInfo[]> {\r\n return this.activeDriver.list(directory || \"\", options);\r\n }\r\n\r\n // ============================================================\r\n // URL Operations\r\n // ============================================================\r\n\r\n /**\r\n * Get the public URL for a file\r\n *\r\n * Returns the URL where the file can be accessed. For local storage,\r\n * this is typically a path prefix. For cloud storage, this is the\r\n * bucket URL or CDN URL.\r\n *\r\n * @param location - File path\r\n * @returns Public URL string\r\n *\r\n * @example\r\n * ```typescript\r\n * const url = storage.url(\"images/photo.jpg\");\r\n * // Local: \"/uploads/images/photo.jpg\"\r\n * // S3: \"https://bucket.s3.amazonaws.com/images/photo.jpg\"\r\n * ```\r\n */\r\n public url(location: string): string {\r\n return this.activeDriver.url(location);\r\n }\r\n\r\n /**\r\n * Get a temporary signed URL with expiration\r\n *\r\n * Creates a URL that provides temporary access to the file.\r\n * For cloud storage, this uses presigned URLs.\r\n * For local storage, this uses HMAC-signed tokens.\r\n *\r\n * @param location - File path\r\n * @param expiresIn - Seconds until URL expires (default: 3600)\r\n * @returns Signed URL string\r\n *\r\n * @example\r\n * ```typescript\r\n * // URL valid for 1 hour\r\n * const url = await storage.temporaryUrl(\"private/document.pdf\");\r\n *\r\n * // URL valid for 24 hours\r\n * const url = await storage.temporaryUrl(\"private/document.pdf\", 86400);\r\n * ```\r\n */\r\n public async temporaryUrl(location: string, expiresIn?: number): Promise<string> {\r\n return this.activeDriver.temporaryUrl(location, expiresIn);\r\n }\r\n\r\n // ============================================================\r\n // Metadata Operations\r\n // ============================================================\r\n\r\n /**\r\n * Get file metadata without downloading the file\r\n *\r\n * Retrieves information about a file including size, last modified date,\r\n * and MIME type without downloading the file contents.\r\n *\r\n * @param location - File path\r\n * @returns File information object\r\n * @throws Error if file not found\r\n *\r\n * @example\r\n * ```typescript\r\n * const info = await storage.metadata(\"documents/report.pdf\");\r\n * console.log(`Size: ${info.size} bytes`);\r\n * console.log(`Type: ${info.mimeType}`);\r\n * console.log(`Modified: ${info.lastModified}`);\r\n * ```\r\n */\r\n public async metadata(location: string): Promise<StorageFileInfo> {\r\n return this.activeDriver.metadata(location);\r\n }\r\n\r\n /**\r\n * Get file size in bytes\r\n *\r\n * Shortcut for `metadata(location).size`.\r\n *\r\n * @param location - File path\r\n * @returns File size in bytes\r\n * @throws Error if file not found\r\n */\r\n public async size(location: string): Promise<number> {\r\n return this.activeDriver.size(location);\r\n }\r\n\r\n /**\r\n * Get a StorageFile instance for OOP-style operations\r\n *\r\n * Creates a `StorageFile` wrapper for the specified path,\r\n * allowing fluent method chaining for file operations.\r\n *\r\n * @param location - File path\r\n * @returns StorageFile instance\r\n *\r\n * @example\r\n * ```typescript\r\n * const file = await storage.file(\"uploads/image.jpg\");\r\n *\r\n * // Properties\r\n * console.log(file.name); // \"image.jpg\"\r\n * console.log(file.extension); // \"jpg\"\r\n *\r\n * // Operations\r\n * await file.copy(\"backup/image.jpg\");\r\n * await file.delete();\r\n * ```\r\n */\r\n public file(location: string): StorageFile {\r\n return new StorageFile(location, this.activeDriver);\r\n }\r\n\r\n // ============================================================\r\n // Utilities\r\n // ============================================================\r\n\r\n /**\r\n * Convert various input types to Buffer\r\n *\r\n * @param file - Input file in various formats\r\n * @returns Buffer containing file contents\r\n * @internal\r\n */\r\n protected async toBuffer(file: UploadedFile | Buffer | string | Readable): Promise<Buffer> {\r\n // Already a buffer\r\n if (Buffer.isBuffer(file)) {\r\n return file;\r\n }\r\n\r\n // Readable stream - collect into buffer\r\n if (this.isReadable(file)) {\r\n return this.streamToBuffer(file as Readable);\r\n }\r\n\r\n // String content\r\n if (typeof file === \"string\") {\r\n if (await fileExistsAsync(file)) {\r\n return fs.readFile(file);\r\n }\r\n\r\n return Buffer.from(file);\r\n }\r\n\r\n // UploadedFile\r\n return (file as UploadedFile).buffer();\r\n }\r\n\r\n /**\r\n * Check if value is a Readable stream\r\n *\r\n * @param value - Value to check\r\n * @returns True if value is a Readable stream\r\n * @internal\r\n */\r\n protected isReadable(value: unknown): value is Readable {\r\n return (\r\n typeof value === \"object\" &&\r\n value !== null &&\r\n \"pipe\" in value &&\r\n typeof (value as Readable).pipe === \"function\"\r\n );\r\n }\r\n\r\n /**\r\n * Convert a Readable stream to Buffer\r\n *\r\n * @param stream - Readable stream\r\n * @returns Buffer containing stream contents\r\n * @internal\r\n */\r\n protected async streamToBuffer(stream: Readable): Promise<Buffer> {\r\n const chunks: Buffer[] = [];\r\n for await (const chunk of stream) {\r\n chunks.push(Buffer.isBuffer(chunk) ? chunk : Buffer.from(chunk));\r\n }\r\n return Buffer.concat(chunks as unknown as Uint8Array[]);\r\n }\r\n\r\n /**\r\n * Prepend a prefix to a location path\r\n *\r\n * Useful for organizing files into directories.\r\n *\r\n * @param prefix - Prefix to add (e.g., \"uploads\")\r\n * @param location - Original location path\r\n * @returns Combined path with prefix\r\n *\r\n * @example\r\n * ```typescript\r\n * storage.prepend(\"uploads\", \"image.jpg\"); // \"uploads/image.jpg\"\r\n * storage.prepend(\"uploads/\", \"/image.jpg\"); // \"uploads/image.jpg\"\r\n * ```\r\n */\r\n public prepend(prefix: string, location: string): string {\r\n return `${prefix.replace(/\\/$/, \"\")}/${location.replace(/^\\//, \"\")}`;\r\n }\r\n\r\n /**\r\n * Append a suffix to a location path (before extension)\r\n *\r\n * Useful for creating variants of files (thumbnails, etc.).\r\n *\r\n * @param location - Original location path\r\n * @param suffix - Suffix to add before extension\r\n * @returns Path with suffix added before extension\r\n *\r\n * @example\r\n * ```typescript\r\n * storage.append(\"image.jpg\", \"_thumb\"); // \"image_thumb.jpg\"\r\n * storage.append(\"document.pdf\", \"_v2\"); // \"document_v2.pdf\"\r\n * ```\r\n */\r\n public append(location: string, suffix: string): string {\r\n const lastDot = location.lastIndexOf(\".\");\r\n if (lastDot === -1) {\r\n return `${location}${suffix}`;\r\n }\r\n return `${location.substring(0, lastDot)}${suffix}${location.substring(lastDot)}`;\r\n }\r\n}\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwCA,IAAa,gBAAb,MAA4D;;;;;;CAY1D,AAAO,YAAY,QAA+B;EAChD,KAAK,UAAU;CACjB;;;;;;CAWA,IAAW,OAA0B;EACnC,OAAO,KAAK,aAAa;CAC3B;;;;;;;;CASA,IAAW,gBAAuC;EAChD,OAAO,KAAK;CACd;;;;;;;;;CAUA,IAAW,eAAsC;EAC/C,OAAO,KAAK;CACd;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgCA,MAAa,IACX,MACA,UACA,SACsB;EACtB,MAAM,SAAS,MAAM,KAAK,SAAS,IAAI;EACvC,MAAM,OAAO,MAAM,KAAK,aAAa,IAAI,QAAQ,UAAU,OAAO;EAClE,OAAO,YAAY,SAAS,MAAM,KAAK,YAAY;CACrD;;;;;;;;;;;;;;;;;;;;CAqBA,MAAa,UACX,QACA,UACA,SACsB;EACtB,MAAM,OAAO,MAAM,KAAK,aAAa,UAAU,QAAQ,UAAU,OAAO;EACxE,OAAO,YAAY,SAAS,MAAM,KAAK,YAAY;CACrD;;;;;;;;;;;;;;;;;;;CAoBA,MAAa,WACX,KACA,UACA,SACsB;EACtB,MAAM,WAAW,MAAM,MAAM,GAAG;EAEhC,IAAI,CAAC,SAAS,IACZ,MAAM,IAAI,MAAM,6BAA6B,IAAI,IAAI,SAAS,YAAY;EAG5E,MAAM,SAAS,OAAO,KAAK,MAAM,SAAS,YAAY,CAAC;EACvD,OAAO,KAAK,IAAI,QAAQ,UAAU,OAAO;CAC3C;;;;;;;;;;;;;;;;;CAkBA,MAAa,cACX,SACA,UACA,SACsB;EAEtB,MAAM,UAAU,QAAQ,MAAM,4BAA4B;EAE1D,IAAI,CAAC,SACH,MAAM,IAAI,MAAM,wEAAwE;EAG1F,MAAM,GAAG,UAAU,cAAc;EACjC,MAAM,SAAS,OAAO,KAAK,YAAY,QAAQ;EAE/C,OAAO,KAAK,IAAI,QAAQ,UAAU;GAChC,GAAG;GACH,UAAU,SAAS,YAAY;EACjC,CAAC;CACH;;;;;;;;;;;;;;;;;CAkBA,MAAa,IAAI,UAAmC;EAClD,OAAO,KAAK,aAAa,IAAI,QAAQ;CACvC;;;;;;;;;;;;;;;;;CAkBA,MAAa,UAAU,UAAqC;EAC1D,OAAO,KAAK,aAAa,UAAU,QAAQ;CAC7C;;;;;;;;;;;;;;;;;CAkBA,MAAa,OAAO,UAAkD;EACpE,MAAM,OAAO,OAAO,aAAa,WAAW,WAAW,SAAS;EAChE,OAAO,KAAK,aAAa,OAAO,IAAI;CACtC;;;;;;;;;;;;;;;;;;;;;;;CAwBA,MAAa,WAAW,WAAkD;EACxE,OAAO,KAAK,aAAa,WAAW,SAAS;CAC/C;;;;;;CAOA,MAAa,gBAAgB,eAAyC;EACpE,OAAO,MAAM,KAAK,aAAa,gBAAgB,aAAa;CAC9D;;;;;;;;;;;;;;CAeA,MAAa,OAAO,UAAoC;EACtD,OAAO,KAAK,aAAa,OAAO,QAAQ;CAC1C;;;;;;;;;;;;;;;;;;;;;CAsBA,MAAa,KAAK,MAA4B,IAAkC;EAC9E,MAAM,WAAW,OAAO,SAAS,WAAW,OAAO,KAAK;EACxD,MAAM,OAAO,MAAM,KAAK,aAAa,KAAK,UAAU,EAAE;EACtD,OAAO,YAAY,SAAS,MAAM,KAAK,YAAY;CACrD;;;;;;;;;;;;;;;;;;;;;CAsBA,MAAa,KAAK,MAA4B,IAAkC;EAC9E,MAAM,WAAW,OAAO,SAAS,WAAW,OAAO,KAAK;EACxD,MAAM,OAAO,MAAM,KAAK,aAAa,KAAK,UAAU,EAAE;EACtD,OAAO,YAAY,SAAS,MAAM,KAAK,YAAY;CACrD;;;;;;;;;;;;;;;;;;;;;;;;CAyBA,MAAa,cACX,MACA,IACA,SACiB;EACjB,MAAM,cAAc,SAAS,eAAe;EAI5C,MAAM,eAAc,MADA,KAAK,KAAK,MAAM,EAAE,WAAW,KAAK,CAAC,GAC7B,QAAQ,MAAM,CAAC,EAAE,WAAW;EAGtD,IAAI,SAAS;EACb,KAAK,IAAI,IAAI,GAAG,IAAI,YAAY,QAAQ,KAAK,aAAa;GACxD,MAAM,QAAQ,YAAY,MAAM,GAAG,IAAI,WAAW;GAClD,MAAM,QAAQ,IACZ,MAAM,IAAI,OAAO,SAAS;IAGxB,MAAM,UAAU,GAAG,GAAG,GADD,KAAK,KAAK,UAAU,KAAK,MAAM,EAAE,QAAQ,OAAO,EACjC;IACpC,MAAM,KAAK,KAAK,KAAK,MAAM,OAAO;IAClC;GACF,CAAC,CACH;EACF;EAEA,OAAO;CACT;;;;;;;;;;;;;;;;;;CAmBA,MAAa,cACX,MACA,IACA,SACiB;EAEjB,MAAM,QAAQ,MAAM,KAAK,cAAc,MAAM,IAAI,OAAO;EAGxD,MAAM,KAAK,gBAAgB,IAAI;EAE/B,OAAO;CACT;;;;;;;;;;;;;;;;;;;;;;;;;CA0BA,MAAa,aACX,cACA,aACA,SAC6B;EAC7B,MAAM,cAAc,SAAS,eAAe;EAG5C,MAAM,aAAa,MAAM,KAAK,mBAAmB,YAAY;EAG7D,MAAM,gBAAgB,SAAS,SAC3B,WAAW,QAAQ,EAAE,UAAU,eAAe,QAAQ,OAAQ,UAAU,QAAQ,CAAC,IACjF;EAEJ,MAAM,QAAQ,cAAc;EAC5B,MAAM,WAA0B,CAAC;EACjC,MAAM,SAAqD,CAAC;EAC5D,IAAI,YAAY;EAGhB,KAAK,IAAI,IAAI,GAAG,IAAI,cAAc,QAAQ,KAAK,aAAa;GAC1D,MAAM,QAAQ,cAAc,MAAM,GAAG,IAAI,WAAW;GAEpD,MAAM,QAAQ,IACZ,MAAM,IAAI,OAAO,EAAE,UAAU,eAAe;IAC1C,MAAM,cAAc,GAAG,YAAY,QAAQ,OAAO,EAAE,EAAE,GAAG;IAEzD,IAAI;KACF,MAAM,SAAS,iBAAiB,QAAQ;KACxC,MAAM,OAAO,MAAM,KAAK,UAAU,QAAQ,aAAa,SAAS,UAAU;KAC1E,SAAS,KAAK,IAAI;KAClB;KACA,SAAS,aAAa,WAAW,OAAO,IAAI;IAC9C,SAAS,KAAK;KACZ,OAAO,KAAK;MACV,WAAW;MACX,OAAO,eAAe,QAAQ,MAAM,IAAI,MAAM,OAAO,GAAG,CAAC;KAC3D,CAAC;IACH;GACF,CAAC,CACH;EACF;EAEA,OAAO;GAAE;GAAU;GAAQ;EAAM;CACnC;;;;;;;;CASA,MAAc,mBACZ,SACA,SACwD;EACxD,MAAM,OAAO,WAAW;EACxB,MAAM,UAAU,MAAMA,KAAG,QAAQ,SAAS,EAAE,eAAe,KAAK,CAAC;EACjE,MAAM,UAAyD,CAAC;EAEhE,KAAK,MAAM,SAAS,SAAS;GAC3B,MAAM,WAAW,KAAK,KAAK,SAAS,MAAM,IAAI;GAC9C,MAAM,WAAW,KAAK,SAAS,MAAM,QAAQ,EAAE,QAAQ,OAAO,GAAG;GAEjE,IAAI,MAAM,YAAY,GAAG;IACvB,MAAM,SAAS,MAAM,KAAK,mBAAmB,UAAU,IAAI;IAC3D,QAAQ,KAAK,GAAG,MAAM;GACxB,OAAO,IAAI,MAAM,OAAO,GACtB,QAAQ,KAAK;IAAE;IAAU;GAAS,CAAC;EAGvC;EAEA,OAAO;CACT;;;;;;;;;;;;;;;CAgBA,MAAa,eAAe,MAA+B;EAGzD,MAAM,aAAY,MADE,KAAK,KAAK,MAAM,EAAE,WAAW,KAAK,CAAC,GAC/B,QAAQ,MAAM,CAAC,EAAE,WAAW,EAAE,KAAK,MAAM,EAAE,IAAI;EAEvE,IAAI,UAAU,WAAW,GACvB,OAAO;EAIT,MAAM,KAAK,WAAW,SAAS;EAE/B,OAAO,UAAU;CACnB;;;;;;;;;;;;;;;;;;;;;;;CAwBA,MAAa,KAAK,WAAoB,SAAmD;EACvF,OAAO,KAAK,aAAa,KAAK,aAAa,IAAI,OAAO;CACxD;;;;;;;;;;;;;;;;;;CAuBA,AAAO,IAAI,UAA0B;EACnC,OAAO,KAAK,aAAa,IAAI,QAAQ;CACvC;;;;;;;;;;;;;;;;;;;;;CAsBA,MAAa,aAAa,UAAkB,WAAqC;EAC/E,OAAO,KAAK,aAAa,aAAa,UAAU,SAAS;CAC3D;;;;;;;;;;;;;;;;;;;CAwBA,MAAa,SAAS,UAA4C;EAChE,OAAO,KAAK,aAAa,SAAS,QAAQ;CAC5C;;;;;;;;;;CAWA,MAAa,KAAK,UAAmC;EACnD,OAAO,KAAK,aAAa,KAAK,QAAQ;CACxC;;;;;;;;;;;;;;;;;;;;;;;CAwBA,AAAO,KAAK,UAA+B;EACzC,OAAO,IAAI,YAAY,UAAU,KAAK,YAAY;CACpD;;;;;;;;CAaA,MAAgB,SAAS,MAAkE;EAEzF,IAAI,OAAO,SAAS,IAAI,GACtB,OAAO;EAIT,IAAI,KAAK,WAAW,IAAI,GACtB,OAAO,KAAK,eAAe,IAAgB;EAI7C,IAAI,OAAO,SAAS,UAAU;GAC5B,IAAI,MAAM,gBAAgB,IAAI,GAC5B,OAAOA,KAAG,SAAS,IAAI;GAGzB,OAAO,OAAO,KAAK,IAAI;EACzB;EAGA,OAAQ,KAAsB,OAAO;CACvC;;;;;;;;CASA,AAAU,WAAW,OAAmC;EACtD,OACE,OAAO,UAAU,YACjB,UAAU,QACV,UAAU,SACV,OAAQ,MAAmB,SAAS;CAExC;;;;;;;;CASA,MAAgB,eAAe,QAAmC;EAChE,MAAM,SAAmB,CAAC;EAC1B,WAAW,MAAM,SAAS,QACxB,OAAO,KAAK,OAAO,SAAS,KAAK,IAAI,QAAQ,OAAO,KAAK,KAAK,CAAC;EAEjE,OAAO,OAAO,OAAO,MAAiC;CACxD;;;;;;;;;;;;;;;;CAiBA,AAAO,QAAQ,QAAgB,UAA0B;EACvD,OAAO,GAAG,OAAO,QAAQ,OAAO,EAAE,EAAE,GAAG,SAAS,QAAQ,OAAO,EAAE;CACnE;;;;;;;;;;;;;;;;CAiBA,AAAO,OAAO,UAAkB,QAAwB;EACtD,MAAM,UAAU,SAAS,YAAY,GAAG;EACxC,IAAI,YAAY,IACd,OAAO,GAAG,WAAW;EAEvB,OAAO,GAAG,SAAS,UAAU,GAAG,OAAO,IAAI,SAAS,SAAS,UAAU,OAAO;CAChF;AACF"}
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
import { CloudStorageFileData, FileVisibility, StorageDriverContract, StorageFileData, StorageFileInfo } from "./types.mjs";
|
|
2
|
+
import { Readable } from "stream";
|
|
3
|
+
|
|
4
|
+
//#region ../../@warlock.js/core/src/storage/storage-file.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* StorageFile class - OOP wrapper for storage file operations
|
|
7
|
+
*
|
|
8
|
+
* Provides a fluent interface for working with files in storage,
|
|
9
|
+
* wrapping the underlying driver operations.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```typescript
|
|
13
|
+
* const file = await storage.put(buffer, "uploads/image.jpg");
|
|
14
|
+
*
|
|
15
|
+
* // Properties (sync, from cached data)
|
|
16
|
+
* file.name // "image.jpg"
|
|
17
|
+
* file.extension // "jpg"
|
|
18
|
+
* file.path // "uploads/image.jpg"
|
|
19
|
+
* file.hash // "sha256:abc123..."
|
|
20
|
+
*
|
|
21
|
+
* // Operations
|
|
22
|
+
* await file.copy("uploads/backup.jpg")
|
|
23
|
+
* await file.move("archive/image.jpg")
|
|
24
|
+
* await file.delete()
|
|
25
|
+
*
|
|
26
|
+
* // Content
|
|
27
|
+
* const buffer = await file.contents();
|
|
28
|
+
* const stream = await file.stream();
|
|
29
|
+
* ```
|
|
30
|
+
*/
|
|
31
|
+
declare class StorageFile {
|
|
32
|
+
/**
|
|
33
|
+
* Relative file path
|
|
34
|
+
*/
|
|
35
|
+
protected _path: string;
|
|
36
|
+
/**
|
|
37
|
+
* The driver instance
|
|
38
|
+
*/
|
|
39
|
+
protected _driver: StorageDriverContract;
|
|
40
|
+
/**
|
|
41
|
+
* Cached file data (from put operations or lazy loaded)
|
|
42
|
+
*/
|
|
43
|
+
protected _data?: StorageFileData;
|
|
44
|
+
/**
|
|
45
|
+
* Whether the file has been deleted
|
|
46
|
+
*/
|
|
47
|
+
protected _deleted: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Create a new StorageFile instance
|
|
50
|
+
*
|
|
51
|
+
* @param path - Relative file path
|
|
52
|
+
* @param driver - Driver instance
|
|
53
|
+
* @param data - Optional initial data from put/copy operations
|
|
54
|
+
*/
|
|
55
|
+
constructor(path: string, driver: StorageDriverContract, data?: StorageFileData);
|
|
56
|
+
/**
|
|
57
|
+
* Get the relative file path
|
|
58
|
+
*/
|
|
59
|
+
get path(): string;
|
|
60
|
+
/**
|
|
61
|
+
* Get the file name (with extension)
|
|
62
|
+
*/
|
|
63
|
+
get name(): string;
|
|
64
|
+
/**
|
|
65
|
+
* Get the file extension (without dot)
|
|
66
|
+
*/
|
|
67
|
+
get extension(): string;
|
|
68
|
+
/**
|
|
69
|
+
* Get the directory path
|
|
70
|
+
*/
|
|
71
|
+
get directory(): string;
|
|
72
|
+
/**
|
|
73
|
+
* Get the driver name
|
|
74
|
+
*/
|
|
75
|
+
get driver(): string;
|
|
76
|
+
/**
|
|
77
|
+
* Check if file has been deleted
|
|
78
|
+
*/
|
|
79
|
+
get isDeleted(): boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Get public URL (sync if data cached, otherwise computed)
|
|
82
|
+
*/
|
|
83
|
+
get url(): string;
|
|
84
|
+
/**
|
|
85
|
+
* Get the absolute filesystem path (local driver only)
|
|
86
|
+
*/
|
|
87
|
+
get absolutePath(): string | undefined;
|
|
88
|
+
/**
|
|
89
|
+
* Get file hash (SHA-256, available from put operations)
|
|
90
|
+
*/
|
|
91
|
+
get hash(): string | undefined;
|
|
92
|
+
/**
|
|
93
|
+
* Get cached file data, or fetch it if not available
|
|
94
|
+
*/
|
|
95
|
+
data(): Promise<StorageFileData>;
|
|
96
|
+
/**
|
|
97
|
+
* Get file size in bytes
|
|
98
|
+
*/
|
|
99
|
+
size(): Promise<number>;
|
|
100
|
+
/**
|
|
101
|
+
* Get MIME type
|
|
102
|
+
*/
|
|
103
|
+
mimeType(): Promise<string>;
|
|
104
|
+
/**
|
|
105
|
+
* Get last modified date (fetches from driver)
|
|
106
|
+
*/
|
|
107
|
+
lastModified(): Promise<Date | undefined>;
|
|
108
|
+
/**
|
|
109
|
+
* Get ETag (cloud drivers, fetches from driver)
|
|
110
|
+
*/
|
|
111
|
+
etag(): Promise<string | undefined>;
|
|
112
|
+
/**
|
|
113
|
+
* Get file contents as Buffer
|
|
114
|
+
*/
|
|
115
|
+
contents(): Promise<Buffer>;
|
|
116
|
+
/**
|
|
117
|
+
* Get file contents as readable stream
|
|
118
|
+
*/
|
|
119
|
+
stream(): Promise<Readable>;
|
|
120
|
+
/**
|
|
121
|
+
* Get file contents as UTF-8 text
|
|
122
|
+
*/
|
|
123
|
+
text(): Promise<string>;
|
|
124
|
+
/**
|
|
125
|
+
* Get file contents as base64 string
|
|
126
|
+
*/
|
|
127
|
+
base64(): Promise<string>;
|
|
128
|
+
/**
|
|
129
|
+
* Get file contents as data URL
|
|
130
|
+
*/
|
|
131
|
+
dataUrl(): Promise<string>;
|
|
132
|
+
/**
|
|
133
|
+
* Get a temporary signed URL
|
|
134
|
+
*
|
|
135
|
+
* @param expiresIn - Seconds until expiration (default: 3600)
|
|
136
|
+
*/
|
|
137
|
+
temporaryUrl(expiresIn?: number): Promise<string>;
|
|
138
|
+
/**
|
|
139
|
+
* Check if the file exists
|
|
140
|
+
*/
|
|
141
|
+
exists(): Promise<boolean>;
|
|
142
|
+
/**
|
|
143
|
+
* Copy the file to a new location
|
|
144
|
+
*
|
|
145
|
+
* @param destination - Destination path
|
|
146
|
+
* @returns New StorageFile instance at destination
|
|
147
|
+
*/
|
|
148
|
+
copy(destination: string): Promise<StorageFile>;
|
|
149
|
+
/**
|
|
150
|
+
* Move the file to a new location
|
|
151
|
+
*
|
|
152
|
+
* @param destination - Destination path
|
|
153
|
+
* @returns This StorageFile instance with updated path
|
|
154
|
+
*/
|
|
155
|
+
move(destination: string): Promise<this>;
|
|
156
|
+
/**
|
|
157
|
+
* Rename the file (move within same directory)
|
|
158
|
+
*
|
|
159
|
+
* @param newName - New file name
|
|
160
|
+
* @returns This StorageFile instance with updated path
|
|
161
|
+
*/
|
|
162
|
+
rename(newName: string): Promise<this>;
|
|
163
|
+
/**
|
|
164
|
+
* Delete the file
|
|
165
|
+
*
|
|
166
|
+
* @returns true if deleted, false if not found
|
|
167
|
+
*/
|
|
168
|
+
delete(): Promise<boolean>;
|
|
169
|
+
/**
|
|
170
|
+
* Set file visibility (cloud drivers only)
|
|
171
|
+
*
|
|
172
|
+
* @param visibility - "public" or "private"
|
|
173
|
+
* @throws Error if driver doesn't support visibility
|
|
174
|
+
*/
|
|
175
|
+
setVisibility(visibility: FileVisibility): Promise<this>;
|
|
176
|
+
/**
|
|
177
|
+
* Get file visibility (cloud drivers only)
|
|
178
|
+
*
|
|
179
|
+
* @throws Error if driver doesn't support visibility
|
|
180
|
+
*/
|
|
181
|
+
getVisibility(): Promise<FileVisibility>;
|
|
182
|
+
/**
|
|
183
|
+
* Set storage class (cloud drivers only)
|
|
184
|
+
*
|
|
185
|
+
* @param storageClass - Storage class (e.g., "STANDARD", "GLACIER")
|
|
186
|
+
* @throws Error if driver doesn't support storage class
|
|
187
|
+
*/
|
|
188
|
+
setStorageClass(storageClass: string): Promise<this>;
|
|
189
|
+
/**
|
|
190
|
+
* Ensure the file has not been deleted
|
|
191
|
+
*/
|
|
192
|
+
protected ensureNotDeleted(): void;
|
|
193
|
+
/**
|
|
194
|
+
* Create a StorageFile instance from StorageFileData
|
|
195
|
+
*
|
|
196
|
+
* @param data - Storage file data from put/copy/move operations
|
|
197
|
+
* @param driver - Driver instance
|
|
198
|
+
*/
|
|
199
|
+
static fromData(data: StorageFileData | CloudStorageFileData, driver: StorageDriverContract): StorageFile;
|
|
200
|
+
/**
|
|
201
|
+
* Get file metadata
|
|
202
|
+
*/
|
|
203
|
+
metadata(): Promise<StorageFileInfo>;
|
|
204
|
+
/**
|
|
205
|
+
* Determine if this file is an image type
|
|
206
|
+
*/
|
|
207
|
+
isImage(): Promise<boolean>;
|
|
208
|
+
/**
|
|
209
|
+
* Determine if this file is a document type
|
|
210
|
+
*/
|
|
211
|
+
isDocument(): Promise<boolean>;
|
|
212
|
+
/**
|
|
213
|
+
* Determine if this file is a pdf type
|
|
214
|
+
*/
|
|
215
|
+
isPdf(): Promise<boolean>;
|
|
216
|
+
/**
|
|
217
|
+
* Determine if this file is an excel file (any support excel file)
|
|
218
|
+
*/
|
|
219
|
+
isExcel(): Promise<boolean>;
|
|
220
|
+
/**
|
|
221
|
+
* Determine if this file is a doc file
|
|
222
|
+
*/
|
|
223
|
+
isDoc(): Promise<boolean>;
|
|
224
|
+
/**
|
|
225
|
+
* Determine if this file is an audio type
|
|
226
|
+
*/
|
|
227
|
+
isAudio(): Promise<boolean>;
|
|
228
|
+
/**
|
|
229
|
+
* Determine if this file is a video type
|
|
230
|
+
*/
|
|
231
|
+
isVideo(): Promise<boolean>;
|
|
232
|
+
/**
|
|
233
|
+
* Convert to plain object (returns cached data or constructs it)
|
|
234
|
+
*/
|
|
235
|
+
toJSON(): {
|
|
236
|
+
path: string;
|
|
237
|
+
name: string;
|
|
238
|
+
extension: string;
|
|
239
|
+
driver: string;
|
|
240
|
+
url: string;
|
|
241
|
+
hash?: string;
|
|
242
|
+
size?: number;
|
|
243
|
+
mimeType?: string;
|
|
244
|
+
};
|
|
245
|
+
/**
|
|
246
|
+
* String representation
|
|
247
|
+
*/
|
|
248
|
+
toString(): string;
|
|
249
|
+
}
|
|
250
|
+
//#endregion
|
|
251
|
+
export { StorageFile };
|
|
252
|
+
//# sourceMappingURL=storage-file.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"storage-file.d.mts","names":[],"sources":["../../../../../../@warlock.js/core/src/storage/storage-file.ts"],"mappings":";;;;;;AAqCA;;;;;;;;;;;;;;;;;;;;;;;;cAAa,WAAA;EA6P6B;;;EAAA,UAzP9B,KAAA;EAkS8C;;;EAAA,UA7R9C,OAAA,EAAS,qBAAA;EA4VX;;;EAAA,UAvVE,KAAA,GAAQ,eAAA;EAgWe;;;EAAA,UA3VvB,QAAA;EAmXQ;;;;;;;cA1WC,IAAA,UAAc,MAAA,EAAQ,qBAAA,EAAuB,IAAA,GAAO,eAAA;EAnB7D;;;EAAA,IAgCC,IAAA,CAAA;EAtBD;;;EAAA,IA6BC,IAAA,CAAA;EApBsB;;;EAAA,IA2BtB,SAAA,CAAA;EAPA;;;EAAA,IAcA,SAAA,CAAA;EAcA;;;EAAA,IAPA,MAAA,CAAA;EA6CE;;;EAAA,IAtCF,SAAA,CAAA;EA0DU;;;EAAA,IAnDV,GAAA,CAAA;EAmEkB;;;EAAA,IA3DlB,YAAA,CAAA;EAiFE;;;EAAA,IArEF,IAAA,CAAA;EA6EY;;;EAlEV,IAAA,CAAA,GAAQ,OAAA,CAAQ,eAAA;EAkFhB;;;EA9DA,IAAA,CAAA,GAAQ,OAAA;EAoFR;;;EA5EA,QAAA,CAAA,GAAY,OAAA;EAwFF;;;EAhFV,YAAA,CAAA,GAAgB,OAAA,CAAQ,IAAA;EA2FW;;;EAlFnC,IAAA,CAAA,GAAQ,OAAA;EA4GR;;;EA/FA,QAAA,CAAA,GAAY,OAAA,CAAQ,MAAA;EAyGV;;;EAjGV,MAAA,CAAA,GAAU,OAAA,CAAQ,QAAA;EAkHyB;;;EA1G3C,IAAA,CAAA,GAAQ,OAAA;EA0IR;;;EAlIA,MAAA,CAAA,GAAU,OAAA;EAgKT;;;EAxJD,OAAA,CAAA,GAAW,OAAA;EA0Jd;;;;;EA5IG,YAAA,CAAa,SAAA,YAAmB,OAAA;EA4JhC;;;EAhJA,MAAA,CAAA,GAAU,OAAA;EAgKV;;;;;;EArJA,IAAA,CAAK,WAAA,WAAsB,OAAA,CAAQ,WAAA;EAsL5B;;;;;;EA1KP,IAAA,CAAK,WAAA,WAAsB,OAAA;EA8LtC;;;;;;EAhLW,MAAA,CAAO,OAAA,WAAkB,OAAA;EAqMvB;;;;;EA3LF,MAAA,CAAA,GAAU,OAAA;;;;;;;EAiBV,aAAA,CAAc,UAAA,EAAY,cAAA,GAAiB,OAAA;;;;;;EAgB3C,aAAA,CAAA,GAAiB,OAAA,CAAQ,cAAA;;;;;;;EAgBzB,eAAA,CAAgB,YAAA,WAAuB,OAAA;;;;YAkB1C,gBAAA,CAAA;;;;;;;SAYI,QAAA,CACZ,IAAA,EAAM,eAAA,GAAkB,oBAAA,EACxB,MAAA,EAAQ,qBAAA,GACP,WAAA;;;;EAOU,QAAA,CAAA,GAAY,OAAA,CAAQ,eAAA;;;;EAQpB,OAAA,CAAA,GAAO,OAAA;;;;EAQP,UAAA,CAAA,GAAU,OAAA;;;;EAQV,KAAA,CAAA,GAAK,OAAA;;;;EAQL,OAAA,CAAA,GAAO,OAAA;;;;EAYP,KAAA,CAAA,GAAK,OAAA;;;;EAaL,OAAA,CAAA,GAAO,OAAA;;;;EAQP,OAAA,CAAA,GAAO,OAAA;;;;EAQb,MAAA,CAAA;IACL,IAAA;IACA,IAAA;IACA,SAAA;IACA,MAAA;IACA,GAAA;IACA,IAAA;IACA,IAAA;IACA,QAAA;EAAA;;;;EAiBK,QAAA,CAAA;AAAA"}
|
|
@@ -0,0 +1,363 @@
|
|
|
1
|
+
import { basename, dirname, extname } from "path";
|
|
2
|
+
|
|
3
|
+
//#region ../../@warlock.js/core/src/storage/storage-file.ts
|
|
4
|
+
/**
|
|
5
|
+
* StorageFile class - OOP wrapper for storage file operations
|
|
6
|
+
*
|
|
7
|
+
* Provides a fluent interface for working with files in storage,
|
|
8
|
+
* wrapping the underlying driver operations.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```typescript
|
|
12
|
+
* const file = await storage.put(buffer, "uploads/image.jpg");
|
|
13
|
+
*
|
|
14
|
+
* // Properties (sync, from cached data)
|
|
15
|
+
* file.name // "image.jpg"
|
|
16
|
+
* file.extension // "jpg"
|
|
17
|
+
* file.path // "uploads/image.jpg"
|
|
18
|
+
* file.hash // "sha256:abc123..."
|
|
19
|
+
*
|
|
20
|
+
* // Operations
|
|
21
|
+
* await file.copy("uploads/backup.jpg")
|
|
22
|
+
* await file.move("archive/image.jpg")
|
|
23
|
+
* await file.delete()
|
|
24
|
+
*
|
|
25
|
+
* // Content
|
|
26
|
+
* const buffer = await file.contents();
|
|
27
|
+
* const stream = await file.stream();
|
|
28
|
+
* ```
|
|
29
|
+
*/
|
|
30
|
+
var StorageFile = class StorageFile {
|
|
31
|
+
/**
|
|
32
|
+
* Create a new StorageFile instance
|
|
33
|
+
*
|
|
34
|
+
* @param path - Relative file path
|
|
35
|
+
* @param driver - Driver instance
|
|
36
|
+
* @param data - Optional initial data from put/copy operations
|
|
37
|
+
*/
|
|
38
|
+
constructor(path, driver, data) {
|
|
39
|
+
this._deleted = false;
|
|
40
|
+
this._path = path;
|
|
41
|
+
this._driver = driver;
|
|
42
|
+
this._data = data;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Get the relative file path
|
|
46
|
+
*/
|
|
47
|
+
get path() {
|
|
48
|
+
return this._path;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Get the file name (with extension)
|
|
52
|
+
*/
|
|
53
|
+
get name() {
|
|
54
|
+
return basename(this._path);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Get the file extension (without dot)
|
|
58
|
+
*/
|
|
59
|
+
get extension() {
|
|
60
|
+
return extname(this._path).slice(1).toLowerCase();
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Get the directory path
|
|
64
|
+
*/
|
|
65
|
+
get directory() {
|
|
66
|
+
return dirname(this._path);
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Get the driver name
|
|
70
|
+
*/
|
|
71
|
+
get driver() {
|
|
72
|
+
return this._driver.name;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Check if file has been deleted
|
|
76
|
+
*/
|
|
77
|
+
get isDeleted() {
|
|
78
|
+
return this._deleted;
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Get public URL (sync if data cached, otherwise computed)
|
|
82
|
+
*/
|
|
83
|
+
get url() {
|
|
84
|
+
this.ensureNotDeleted();
|
|
85
|
+
return this._data?.url || this._driver.url(this._path);
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Get the absolute filesystem path (local driver only)
|
|
89
|
+
*/
|
|
90
|
+
get absolutePath() {
|
|
91
|
+
this.ensureNotDeleted();
|
|
92
|
+
if ("path" in this._driver && typeof this._driver.path === "function") return this._driver.path(this._path);
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* Get file hash (SHA-256, available from put operations)
|
|
96
|
+
*/
|
|
97
|
+
get hash() {
|
|
98
|
+
return this._data?.hash;
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* Get cached file data, or fetch it if not available
|
|
102
|
+
*/
|
|
103
|
+
async data() {
|
|
104
|
+
this.ensureNotDeleted();
|
|
105
|
+
if (!this._data) {
|
|
106
|
+
const info = await this.metadata();
|
|
107
|
+
this._data = {
|
|
108
|
+
path: info.path,
|
|
109
|
+
url: this._driver.url(this._path),
|
|
110
|
+
size: info.size,
|
|
111
|
+
hash: "",
|
|
112
|
+
mimeType: info.mimeType || "application/octet-stream",
|
|
113
|
+
driver: this._driver.name
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
return this._data;
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Get file size in bytes
|
|
120
|
+
*/
|
|
121
|
+
async size() {
|
|
122
|
+
return (await this.data()).size;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Get MIME type
|
|
126
|
+
*/
|
|
127
|
+
async mimeType() {
|
|
128
|
+
return (await this.data()).mimeType;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Get last modified date (fetches from driver)
|
|
132
|
+
*/
|
|
133
|
+
async lastModified() {
|
|
134
|
+
this.ensureNotDeleted();
|
|
135
|
+
return (await this.metadata()).lastModified;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Get ETag (cloud drivers, fetches from driver)
|
|
139
|
+
*/
|
|
140
|
+
async etag() {
|
|
141
|
+
this.ensureNotDeleted();
|
|
142
|
+
return (await this.metadata()).etag;
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Get file contents as Buffer
|
|
146
|
+
*/
|
|
147
|
+
async contents() {
|
|
148
|
+
this.ensureNotDeleted();
|
|
149
|
+
return this._driver.get(this._path);
|
|
150
|
+
}
|
|
151
|
+
/**
|
|
152
|
+
* Get file contents as readable stream
|
|
153
|
+
*/
|
|
154
|
+
async stream() {
|
|
155
|
+
this.ensureNotDeleted();
|
|
156
|
+
return this._driver.getStream(this._path);
|
|
157
|
+
}
|
|
158
|
+
/**
|
|
159
|
+
* Get file contents as UTF-8 text
|
|
160
|
+
*/
|
|
161
|
+
async text() {
|
|
162
|
+
return (await this.contents()).toString("utf-8");
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* Get file contents as base64 string
|
|
166
|
+
*/
|
|
167
|
+
async base64() {
|
|
168
|
+
return (await this.contents()).toString("base64");
|
|
169
|
+
}
|
|
170
|
+
/**
|
|
171
|
+
* Get file contents as data URL
|
|
172
|
+
*/
|
|
173
|
+
async dataUrl() {
|
|
174
|
+
const [buffer, data] = await Promise.all([this.contents(), this.data()]);
|
|
175
|
+
return `data:${data.mimeType};base64,${buffer.toString("base64")}`;
|
|
176
|
+
}
|
|
177
|
+
/**
|
|
178
|
+
* Get a temporary signed URL
|
|
179
|
+
*
|
|
180
|
+
* @param expiresIn - Seconds until expiration (default: 3600)
|
|
181
|
+
*/
|
|
182
|
+
async temporaryUrl(expiresIn = 3600) {
|
|
183
|
+
this.ensureNotDeleted();
|
|
184
|
+
return this._driver.temporaryUrl(this._path, expiresIn);
|
|
185
|
+
}
|
|
186
|
+
/**
|
|
187
|
+
* Check if the file exists
|
|
188
|
+
*/
|
|
189
|
+
async exists() {
|
|
190
|
+
if (this._deleted) return false;
|
|
191
|
+
return this._driver.exists(this._path);
|
|
192
|
+
}
|
|
193
|
+
/**
|
|
194
|
+
* Copy the file to a new location
|
|
195
|
+
*
|
|
196
|
+
* @param destination - Destination path
|
|
197
|
+
* @returns New StorageFile instance at destination
|
|
198
|
+
*/
|
|
199
|
+
async copy(destination) {
|
|
200
|
+
this.ensureNotDeleted();
|
|
201
|
+
const result = await this._driver.copy(this._path, destination);
|
|
202
|
+
return new StorageFile(destination, this._driver, result);
|
|
203
|
+
}
|
|
204
|
+
/**
|
|
205
|
+
* Move the file to a new location
|
|
206
|
+
*
|
|
207
|
+
* @param destination - Destination path
|
|
208
|
+
* @returns This StorageFile instance with updated path
|
|
209
|
+
*/
|
|
210
|
+
async move(destination) {
|
|
211
|
+
this.ensureNotDeleted();
|
|
212
|
+
const result = await this._driver.move(this._path, destination);
|
|
213
|
+
this._path = destination;
|
|
214
|
+
this._data = result;
|
|
215
|
+
return this;
|
|
216
|
+
}
|
|
217
|
+
/**
|
|
218
|
+
* Rename the file (move within same directory)
|
|
219
|
+
*
|
|
220
|
+
* @param newName - New file name
|
|
221
|
+
* @returns This StorageFile instance with updated path
|
|
222
|
+
*/
|
|
223
|
+
async rename(newName) {
|
|
224
|
+
const newPath = this.directory === "." ? newName : `${this.directory}/${newName}`;
|
|
225
|
+
return this.move(newPath);
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* Delete the file
|
|
229
|
+
*
|
|
230
|
+
* @returns true if deleted, false if not found
|
|
231
|
+
*/
|
|
232
|
+
async delete() {
|
|
233
|
+
this.ensureNotDeleted();
|
|
234
|
+
const result = await this._driver.delete(this._path);
|
|
235
|
+
this._deleted = true;
|
|
236
|
+
return result;
|
|
237
|
+
}
|
|
238
|
+
/**
|
|
239
|
+
* Set file visibility (cloud drivers only)
|
|
240
|
+
*
|
|
241
|
+
* @param visibility - "public" or "private"
|
|
242
|
+
* @throws Error if driver doesn't support visibility
|
|
243
|
+
*/
|
|
244
|
+
async setVisibility(visibility) {
|
|
245
|
+
this.ensureNotDeleted();
|
|
246
|
+
if (!("setVisibility" in this._driver)) throw new Error("setVisibility is only available for cloud storage drivers");
|
|
247
|
+
await this._driver.setVisibility(this._path, visibility);
|
|
248
|
+
return this;
|
|
249
|
+
}
|
|
250
|
+
/**
|
|
251
|
+
* Get file visibility (cloud drivers only)
|
|
252
|
+
*
|
|
253
|
+
* @throws Error if driver doesn't support visibility
|
|
254
|
+
*/
|
|
255
|
+
async getVisibility() {
|
|
256
|
+
this.ensureNotDeleted();
|
|
257
|
+
if (!("getVisibility" in this._driver)) throw new Error("getVisibility is only available for cloud storage drivers");
|
|
258
|
+
return this._driver.getVisibility(this._path);
|
|
259
|
+
}
|
|
260
|
+
/**
|
|
261
|
+
* Set storage class (cloud drivers only)
|
|
262
|
+
*
|
|
263
|
+
* @param storageClass - Storage class (e.g., "STANDARD", "GLACIER")
|
|
264
|
+
* @throws Error if driver doesn't support storage class
|
|
265
|
+
*/
|
|
266
|
+
async setStorageClass(storageClass) {
|
|
267
|
+
this.ensureNotDeleted();
|
|
268
|
+
if (!("setStorageClass" in this._driver)) throw new Error("setStorageClass is only available for cloud storage drivers");
|
|
269
|
+
await this._driver.setStorageClass(this._path, storageClass);
|
|
270
|
+
return this;
|
|
271
|
+
}
|
|
272
|
+
/**
|
|
273
|
+
* Ensure the file has not been deleted
|
|
274
|
+
*/
|
|
275
|
+
ensureNotDeleted() {
|
|
276
|
+
if (this._deleted) throw new Error(`File "${this._path}" has been deleted`);
|
|
277
|
+
}
|
|
278
|
+
/**
|
|
279
|
+
* Create a StorageFile instance from StorageFileData
|
|
280
|
+
*
|
|
281
|
+
* @param data - Storage file data from put/copy/move operations
|
|
282
|
+
* @param driver - Driver instance
|
|
283
|
+
*/
|
|
284
|
+
static fromData(data, driver) {
|
|
285
|
+
return new StorageFile(data.path, driver, data);
|
|
286
|
+
}
|
|
287
|
+
/**
|
|
288
|
+
* Get file metadata
|
|
289
|
+
*/
|
|
290
|
+
async metadata() {
|
|
291
|
+
this.ensureNotDeleted();
|
|
292
|
+
return this._driver.metadata(this._path);
|
|
293
|
+
}
|
|
294
|
+
/**
|
|
295
|
+
* Determine if this file is an image type
|
|
296
|
+
*/
|
|
297
|
+
async isImage() {
|
|
298
|
+
return (await this.metadata()).mimeType.startsWith("image/");
|
|
299
|
+
}
|
|
300
|
+
/**
|
|
301
|
+
* Determine if this file is a document type
|
|
302
|
+
*/
|
|
303
|
+
async isDocument() {
|
|
304
|
+
return (await this.metadata()).mimeType.startsWith("application/");
|
|
305
|
+
}
|
|
306
|
+
/**
|
|
307
|
+
* Determine if this file is a pdf type
|
|
308
|
+
*/
|
|
309
|
+
async isPdf() {
|
|
310
|
+
return (await this.metadata()).mimeType.startsWith("application/pdf");
|
|
311
|
+
}
|
|
312
|
+
/**
|
|
313
|
+
* Determine if this file is an excel file (any support excel file)
|
|
314
|
+
*/
|
|
315
|
+
async isExcel() {
|
|
316
|
+
const metadata = await this.metadata();
|
|
317
|
+
return metadata.mimeType.startsWith("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet") || metadata.mimeType.startsWith("application/vnd.ms-excel");
|
|
318
|
+
}
|
|
319
|
+
/**
|
|
320
|
+
* Determine if this file is a doc file
|
|
321
|
+
*/
|
|
322
|
+
async isDoc() {
|
|
323
|
+
const metadata = await this.metadata();
|
|
324
|
+
return metadata.mimeType.startsWith("application/msword") || metadata.mimeType.startsWith("application/vnd.openxmlformats-officedocument.wordprocessingml.document");
|
|
325
|
+
}
|
|
326
|
+
/**
|
|
327
|
+
* Determine if this file is an audio type
|
|
328
|
+
*/
|
|
329
|
+
async isAudio() {
|
|
330
|
+
return (await this.metadata()).mimeType.startsWith("audio/");
|
|
331
|
+
}
|
|
332
|
+
/**
|
|
333
|
+
* Determine if this file is a video type
|
|
334
|
+
*/
|
|
335
|
+
async isVideo() {
|
|
336
|
+
return (await this.metadata()).mimeType.startsWith("video/");
|
|
337
|
+
}
|
|
338
|
+
/**
|
|
339
|
+
* Convert to plain object (returns cached data or constructs it)
|
|
340
|
+
*/
|
|
341
|
+
toJSON() {
|
|
342
|
+
return {
|
|
343
|
+
path: this._path,
|
|
344
|
+
name: this.name,
|
|
345
|
+
extension: this.extension,
|
|
346
|
+
driver: this._driver.name,
|
|
347
|
+
url: this._deleted ? "" : this.url,
|
|
348
|
+
hash: this._data?.hash,
|
|
349
|
+
size: this._data?.size,
|
|
350
|
+
mimeType: this._data?.mimeType
|
|
351
|
+
};
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* String representation
|
|
355
|
+
*/
|
|
356
|
+
toString() {
|
|
357
|
+
return this._path;
|
|
358
|
+
}
|
|
359
|
+
};
|
|
360
|
+
|
|
361
|
+
//#endregion
|
|
362
|
+
export { StorageFile };
|
|
363
|
+
//# sourceMappingURL=storage-file.mjs.map
|