@daiso-tech/core 0.14.0 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/_module.js +3 -2
- package/dist/cjs/_module.js.map +1 -1
- package/dist/cjs/async/_module.js +20 -0
- package/dist/cjs/async/_module.js.map +1 -0
- package/dist/cjs/{utilities/async/_shared.js → async/async.errors.js} +1 -1
- package/dist/cjs/async/async.errors.js.map +1 -0
- package/dist/cjs/{utilities → async}/backof-policies/_module.js +4 -4
- package/dist/cjs/async/backof-policies/_module.js.map +1 -0
- package/dist/cjs/async/backof-policies/_shared.js.map +1 -0
- package/dist/cjs/{serializer/implementations/sql-serializer → async/backof-policies/constant-backoff-policy}/_module.js +1 -1
- package/dist/cjs/async/backof-policies/constant-backoff-policy/_module.js.map +1 -0
- package/dist/cjs/{utilities → async}/backof-policies/constant-backoff-policy/constant-backoff-policy.js +1 -1
- package/dist/cjs/async/backof-policies/constant-backoff-policy/constant-backoff-policy.js.map +1 -0
- package/dist/cjs/{serializer/implementations/_shared/test-utilities → async/backof-policies/exponential-backoff-policy}/_module.js +1 -1
- package/dist/cjs/async/backof-policies/exponential-backoff-policy/_module.js.map +1 -0
- package/dist/cjs/{utilities → async}/backof-policies/exponential-backoff-policy/exponential-backoff-policy.js +1 -1
- package/dist/cjs/async/backof-policies/exponential-backoff-policy/exponential-backoff-policy.js.map +1 -0
- package/dist/cjs/{serializer/implementations/mongodb-serializer → async/backof-policies/linear-backoff-policy}/_module.js +1 -1
- package/dist/cjs/async/backof-policies/linear-backoff-policy/_module.js.map +1 -0
- package/dist/cjs/{utilities → async}/backof-policies/linear-backoff-policy/linear-backoff-policy.js +1 -1
- package/dist/cjs/async/backof-policies/linear-backoff-policy/linear-backoff-policy.js.map +1 -0
- package/dist/cjs/async/backof-policies/polynomial-backoff-policy/_module.js +18 -0
- package/dist/cjs/async/backof-policies/polynomial-backoff-policy/_module.js.map +1 -0
- package/dist/cjs/{utilities → async}/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.js +1 -1
- package/dist/cjs/async/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.js.map +1 -0
- package/dist/cjs/{event-bus/implementations/_shared/test-utilities → async/utilities}/_module.js +2 -1
- package/dist/cjs/async/utilities/_module.js.map +1 -0
- package/dist/cjs/async/utilities/abort/_module.js +19 -0
- package/dist/cjs/async/utilities/abort/_module.js.map +1 -0
- package/dist/cjs/async/utilities/abort/abort-and-fail.js +45 -0
- package/dist/cjs/async/utilities/abort/abort-and-fail.js.map +1 -0
- package/dist/cjs/async/utilities/abort/abort.js +18 -0
- package/dist/cjs/async/utilities/abort/abort.js.map +1 -0
- package/dist/cjs/{utilities/async → async/utilities}/delay/_module.js +1 -1
- package/dist/cjs/async/utilities/delay/_module.js.map +1 -0
- package/dist/cjs/async/utilities/delay/delay.js +20 -0
- package/dist/cjs/async/utilities/delay/delay.js.map +1 -0
- package/dist/cjs/{utilities/async → async/utilities}/lazy-promise/_module.js +1 -1
- package/dist/cjs/async/utilities/lazy-promise/_module.js.map +1 -0
- package/dist/cjs/async/utilities/lazy-promise/lazy-promise.js +110 -0
- package/dist/cjs/async/utilities/lazy-promise/lazy-promise.js.map +1 -0
- package/dist/cjs/async/utilities/retry/_module.js +19 -0
- package/dist/cjs/async/utilities/retry/_module.js.map +1 -0
- package/dist/cjs/async/utilities/retry/retry-or-fail.js +36 -0
- package/dist/cjs/async/utilities/retry/retry-or-fail.js.map +1 -0
- package/dist/cjs/async/utilities/retry/retry.js +18 -0
- package/dist/cjs/async/utilities/retry/retry.js.map +1 -0
- package/dist/cjs/{utilities/async → async/utilities}/timeout/_module.js +2 -1
- package/dist/cjs/async/utilities/timeout/_module.js.map +1 -0
- package/dist/cjs/async/utilities/timeout/timeout-and-fail.js +25 -0
- package/dist/cjs/async/utilities/timeout/timeout-and-fail.js.map +1 -0
- package/dist/cjs/async/utilities/timeout/timeout.js +18 -0
- package/dist/cjs/async/utilities/timeout/timeout.js.map +1 -0
- package/dist/cjs/cache/contracts/cache.events.js +0 -11
- package/dist/cjs/cache/contracts/cache.events.js.map +1 -1
- package/dist/cjs/cache/implementations/_shared/cache-adapter.test-suite.js +257 -177
- package/dist/cjs/cache/implementations/_shared/cache-adapter.test-suite.js.map +1 -1
- package/dist/cjs/cache/implementations/_shared/cache.test-suite.js +59 -37
- package/dist/cjs/cache/implementations/_shared/cache.test-suite.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/kysely-sqlite-cache-adapter/kysely-sqlite-cache-adapter.js +59 -18
- package/dist/cjs/cache/implementations/adapters/kysely-sqlite-cache-adapter/kysely-sqlite-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/libsql-cache-adapter/libsql-cache-adapter.js +16 -6
- package/dist/cjs/cache/implementations/adapters/libsql-cache-adapter/libsql-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/memory-cache-adapter/memory-cache-adapter.js +58 -39
- package/dist/cjs/cache/implementations/adapters/memory-cache-adapter/memory-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/mongodb-cache-adapter/mongodb-cache-adapter.js +63 -26
- package/dist/cjs/cache/implementations/adapters/mongodb-cache-adapter/mongodb-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/no-op-cache-adapter/no-op-cache-adapter.js +10 -1
- package/dist/cjs/cache/implementations/adapters/no-op-cache-adapter/no-op-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/redis-cache-adapter/redis-cache-adapter.js +44 -19
- package/dist/cjs/cache/implementations/adapters/redis-cache-adapter/redis-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/adapters/sqlite-cache-adapter/sqlite-cache-adapter.js +17 -7
- package/dist/cjs/cache/implementations/adapters/sqlite-cache-adapter/sqlite-cache-adapter.js.map +1 -1
- package/dist/cjs/cache/implementations/derivables/_module.js +0 -1
- package/dist/cjs/cache/implementations/derivables/_module.js.map +1 -1
- package/dist/cjs/cache/implementations/derivables/cache-factory.js +4 -7
- package/dist/cjs/cache/implementations/derivables/cache-factory.js.map +1 -1
- package/dist/cjs/cache/implementations/derivables/cache.js +303 -61
- package/dist/cjs/cache/implementations/derivables/cache.js.map +1 -1
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/_module.js +4 -1
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/_module.js.map +1 -1
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-delay-iterable.js +27 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-delay-iterable.js.map +1 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-merge-iterable.js +14 -7
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-merge-iterable.js.map +1 -1
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-retry-iterable.js +33 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-retry-iterable.js.map +1 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-take-until-abort-iterable.js +36 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-take-until-abort-iterable.js.map +1 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-take-until-timeout-iterable.js +48 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-take-until-timeout-iterable.js.map +1 -0
- package/dist/cjs/collection/implementations/async-iterable-collection/async-iterable-collection.js +63 -42
- package/dist/cjs/collection/implementations/async-iterable-collection/async-iterable-collection.js.map +1 -1
- package/dist/cjs/collection/implementations/iterable-collection/_shared/merge-iterable.js +6 -7
- package/dist/cjs/collection/implementations/iterable-collection/_shared/merge-iterable.js.map +1 -1
- package/dist/cjs/collection/implementations/iterable-collection/iterable-collection.js +16 -7
- package/dist/cjs/collection/implementations/iterable-collection/iterable-collection.js.map +1 -1
- package/dist/cjs/collection/implementations/list-collection/list-collection.js +18 -5
- package/dist/cjs/collection/implementations/list-collection/list-collection.js.map +1 -1
- package/dist/cjs/event-bus/contracts/event-bus.errors.js +3 -3
- package/dist/cjs/event-bus/contracts/event-bus.errors.js.map +1 -1
- package/dist/cjs/event-bus/implementations/_module.js +1 -1
- package/dist/cjs/event-bus/implementations/_module.js.map +1 -1
- package/dist/cjs/event-bus/implementations/_shared/_module.js +19 -0
- package/dist/cjs/event-bus/implementations/_shared/_module.js.map +1 -0
- package/dist/cjs/event-bus/implementations/_shared/event-bus-adapter.test-suite.js +96 -0
- package/dist/cjs/event-bus/implementations/_shared/event-bus-adapter.test-suite.js.map +1 -0
- package/dist/cjs/event-bus/implementations/_shared/event-bus.test-suite.js +335 -0
- package/dist/cjs/event-bus/implementations/_shared/event-bus.test-suite.js.map +1 -0
- package/dist/cjs/event-bus/implementations/adapters/_module.js +1 -1
- package/dist/cjs/event-bus/implementations/adapters/_module.js.map +1 -1
- package/dist/cjs/event-bus/implementations/adapters/memory-event-bus-adapter/memory-event-bus-adapter.js +19 -9
- package/dist/cjs/event-bus/implementations/adapters/memory-event-bus-adapter/memory-event-bus-adapter.js.map +1 -1
- package/dist/cjs/event-bus/implementations/adapters/no-op-event-bus-adapter/no-op-event-bus-adapter.js +7 -1
- package/dist/cjs/event-bus/implementations/adapters/no-op-event-bus-adapter/no-op-event-bus-adapter.js.map +1 -1
- package/dist/cjs/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/_module.js.map +1 -0
- package/dist/cjs/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/redis-pub-sub-event-bus-adapter.js +52 -0
- package/dist/cjs/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/redis-pub-sub-event-bus-adapter.js.map +1 -0
- package/dist/cjs/event-bus/implementations/derivables/event-bus-factory.js +6 -7
- package/dist/cjs/event-bus/implementations/derivables/event-bus-factory.js.map +1 -1
- package/dist/cjs/event-bus/implementations/derivables/event-bus.js +96 -33
- package/dist/cjs/event-bus/implementations/derivables/event-bus.js.map +1 -1
- package/dist/cjs/{utilities/async/retry → serde/contracts}/_module.js +2 -1
- package/dist/cjs/serde/contracts/_module.js.map +1 -0
- package/dist/cjs/{serializer/contracts/serializer.contract.js → serde/contracts/serde.contract.js} +1 -1
- package/dist/cjs/serde/contracts/serde.contract.js.map +1 -0
- package/dist/cjs/{serializer/contracts/serializer.errors.js → serde/contracts/serde.errors.js} +7 -7
- package/dist/cjs/serde/contracts/serde.errors.js.map +1 -0
- package/dist/cjs/{_shared/redis → serde/implementations}/_module.js +5 -3
- package/dist/cjs/serde/implementations/_module.js.map +1 -0
- package/dist/cjs/{serializer/implementations/redis-serializer → serde/implementations/_shared/test-utilities}/_module.js +1 -1
- package/dist/cjs/serde/implementations/_shared/test-utilities/_module.js.map +1 -0
- package/dist/{esm/serializer/implementations/_shared/test-utilities/serializer.test-suite.js → cjs/serde/implementations/_shared/test-utilities/serde.test-suite.js} +65 -62
- package/dist/cjs/serde/implementations/_shared/test-utilities/serde.test-suite.js.map +1 -0
- package/dist/cjs/{_shared/kysely → serde/implementations/mongodb-serde}/_module.js +1 -1
- package/dist/cjs/serde/implementations/mongodb-serde/_module.js.map +1 -0
- package/dist/cjs/serde/implementations/mongodb-serde/mongodb-serde.js +36 -0
- package/dist/cjs/serde/implementations/mongodb-serde/mongodb-serde.js.map +1 -0
- package/dist/cjs/{utilities/async/delay-iterable → serde/implementations/redis-serde}/_module.js +1 -1
- package/dist/cjs/serde/implementations/redis-serde/_module.js.map +1 -0
- package/dist/cjs/serde/implementations/redis-serde/redis-serde.js +37 -0
- package/dist/cjs/serde/implementations/redis-serde/redis-serde.js.map +1 -0
- package/dist/cjs/{utilities/async/abortable → serde/implementations/sql-serde}/_module.js +1 -1
- package/dist/cjs/serde/implementations/sql-serde/_module.js.map +1 -0
- package/dist/cjs/serde/implementations/sql-serde/sql-serde.js +37 -0
- package/dist/cjs/serde/implementations/sql-serde/sql-serde.js.map +1 -0
- package/dist/cjs/{utilities/async/abortable-iterable → serde/implementations/super-json-serde}/_module.js +1 -1
- package/dist/cjs/serde/implementations/super-json-serde/_module.js.map +1 -0
- package/dist/cjs/{serializer/implementations/super-json-serializer/super-json-serializer.js → serde/implementations/super-json-serde/super-json-serde.js} +74 -100
- package/dist/cjs/serde/implementations/super-json-serde/super-json-serde.js.map +1 -0
- package/dist/cjs/utilities/_module.js +5 -4
- package/dist/cjs/utilities/_module.js.map +1 -1
- package/dist/cjs/{serializer → utilities}/contracts/_module.js +2 -2
- package/dist/cjs/utilities/contracts/_module.js.map +1 -0
- package/dist/cjs/utilities/contracts/deinitizable.contract.js +3 -0
- package/dist/cjs/utilities/contracts/deinitizable.contract.js.map +1 -0
- package/dist/cjs/utilities/contracts/initizable.contract.js +3 -0
- package/dist/cjs/utilities/contracts/initizable.contract.js.map +1 -0
- package/dist/cjs/utilities/{global-errors.js → errors.js} +1 -1
- package/dist/cjs/utilities/errors.js.map +1 -0
- package/dist/cjs/{_shared/utilities.js → utilities/functions.js} +6 -6
- package/dist/cjs/utilities/functions.js.map +1 -0
- package/dist/cjs/utilities/kysely/_module.js +18 -0
- package/dist/cjs/utilities/kysely/_module.js.map +1 -0
- package/dist/cjs/utilities/kysely/kysely-table-name-transformer-plugin.js.map +1 -0
- package/dist/cjs/utilities/time-span/time-span.js +8 -0
- package/dist/cjs/utilities/time-span/time-span.js.map +1 -1
- package/dist/cjs/{_shared → utilities}/types.js.map +1 -1
- package/dist/esm/_module.js +3 -2
- package/dist/esm/_module.js.map +1 -1
- package/dist/esm/async/_module.js +4 -0
- package/dist/esm/async/_module.js.map +1 -0
- package/dist/esm/{utilities/async/_shared.js → async/async.errors.js} +1 -1
- package/dist/esm/async/async.errors.js.map +1 -0
- package/dist/esm/async/backof-policies/_module.js +5 -0
- package/dist/esm/async/backof-policies/_module.js.map +1 -0
- package/dist/esm/async/backof-policies/_shared.js.map +1 -0
- package/dist/esm/async/backof-policies/constant-backoff-policy/_module.js +2 -0
- package/dist/esm/async/backof-policies/constant-backoff-policy/_module.js.map +1 -0
- package/dist/esm/{utilities → async}/backof-policies/constant-backoff-policy/constant-backoff-policy.js +1 -1
- package/dist/esm/async/backof-policies/constant-backoff-policy/constant-backoff-policy.js.map +1 -0
- package/dist/esm/async/backof-policies/exponential-backoff-policy/_module.js +2 -0
- package/dist/esm/async/backof-policies/exponential-backoff-policy/_module.js.map +1 -0
- package/dist/esm/{utilities → async}/backof-policies/exponential-backoff-policy/exponential-backoff-policy.js +1 -1
- package/dist/esm/async/backof-policies/exponential-backoff-policy/exponential-backoff-policy.js.map +1 -0
- package/dist/esm/async/backof-policies/linear-backoff-policy/_module.js +2 -0
- package/dist/esm/async/backof-policies/linear-backoff-policy/_module.js.map +1 -0
- package/dist/esm/{utilities → async}/backof-policies/linear-backoff-policy/linear-backoff-policy.js +1 -1
- package/dist/esm/async/backof-policies/linear-backoff-policy/linear-backoff-policy.js.map +1 -0
- package/dist/esm/async/backof-policies/polynomial-backoff-policy/_module.js +2 -0
- package/dist/esm/async/backof-policies/polynomial-backoff-policy/_module.js.map +1 -0
- package/dist/esm/{utilities → async}/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.js +1 -1
- package/dist/esm/async/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.js.map +1 -0
- package/dist/esm/async/utilities/_module.js +3 -0
- package/dist/esm/async/utilities/_module.js.map +1 -0
- package/dist/esm/async/utilities/abort/_module.js +3 -0
- package/dist/esm/async/utilities/abort/_module.js.map +1 -0
- package/dist/esm/{utilities/async/abortable/abortable.js → async/utilities/abort/abort-and-fail.js} +13 -16
- package/dist/esm/async/utilities/abort/abort-and-fail.js.map +1 -0
- package/dist/esm/async/utilities/abort/abort.js +15 -0
- package/dist/esm/async/utilities/abort/abort.js.map +1 -0
- package/dist/esm/async/utilities/delay/_module.js +2 -0
- package/dist/esm/async/utilities/delay/_module.js.map +1 -0
- package/dist/esm/async/utilities/delay/delay.js +17 -0
- package/dist/esm/async/utilities/delay/delay.js.map +1 -0
- package/dist/esm/async/utilities/lazy-promise/_module.js +2 -0
- package/dist/esm/async/utilities/lazy-promise/_module.js.map +1 -0
- package/dist/esm/async/utilities/lazy-promise/lazy-promise.js +106 -0
- package/dist/esm/async/utilities/lazy-promise/lazy-promise.js.map +1 -0
- package/dist/esm/async/utilities/retry/_module.js +3 -0
- package/dist/esm/async/utilities/retry/_module.js.map +1 -0
- package/dist/esm/async/utilities/retry/retry-or-fail.js +33 -0
- package/dist/esm/async/utilities/retry/retry-or-fail.js.map +1 -0
- package/dist/esm/async/utilities/retry/retry.js +15 -0
- package/dist/esm/async/utilities/retry/retry.js.map +1 -0
- package/dist/esm/async/utilities/timeout/_module.js +3 -0
- package/dist/esm/async/utilities/timeout/_module.js.map +1 -0
- package/dist/esm/async/utilities/timeout/timeout-and-fail.js +22 -0
- package/dist/esm/async/utilities/timeout/timeout-and-fail.js.map +1 -0
- package/dist/esm/async/utilities/timeout/timeout.js +15 -0
- package/dist/esm/async/utilities/timeout/timeout.js.map +1 -0
- package/dist/esm/cache/contracts/cache.events.js +0 -10
- package/dist/esm/cache/contracts/cache.events.js.map +1 -1
- package/dist/esm/cache/implementations/_shared/cache-adapter.test-suite.js +258 -178
- package/dist/esm/cache/implementations/_shared/cache-adapter.test-suite.js.map +1 -1
- package/dist/esm/cache/implementations/_shared/cache.test-suite.js +25 -3
- package/dist/esm/cache/implementations/_shared/cache.test-suite.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/kysely-sqlite-cache-adapter/kysely-sqlite-cache-adapter.js +60 -19
- package/dist/esm/cache/implementations/adapters/kysely-sqlite-cache-adapter/kysely-sqlite-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/libsql-cache-adapter/libsql-cache-adapter.js +16 -6
- package/dist/esm/cache/implementations/adapters/libsql-cache-adapter/libsql-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/memory-cache-adapter/memory-cache-adapter.js +58 -39
- package/dist/esm/cache/implementations/adapters/memory-cache-adapter/memory-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/mongodb-cache-adapter/mongodb-cache-adapter.js +63 -23
- package/dist/esm/cache/implementations/adapters/mongodb-cache-adapter/mongodb-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/no-op-cache-adapter/no-op-cache-adapter.js +10 -1
- package/dist/esm/cache/implementations/adapters/no-op-cache-adapter/no-op-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/redis-cache-adapter/redis-cache-adapter.js +44 -19
- package/dist/esm/cache/implementations/adapters/redis-cache-adapter/redis-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/adapters/sqlite-cache-adapter/sqlite-cache-adapter.js +16 -6
- package/dist/esm/cache/implementations/adapters/sqlite-cache-adapter/sqlite-cache-adapter.js.map +1 -1
- package/dist/esm/cache/implementations/derivables/_module.js +0 -1
- package/dist/esm/cache/implementations/derivables/_module.js.map +1 -1
- package/dist/esm/cache/implementations/derivables/cache-factory.js +2 -5
- package/dist/esm/cache/implementations/derivables/cache-factory.js.map +1 -1
- package/dist/esm/cache/implementations/derivables/cache.js +304 -62
- package/dist/esm/cache/implementations/derivables/cache.js.map +1 -1
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/_module.js +4 -1
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/_module.js.map +1 -1
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-delay-iterable.js +23 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-delay-iterable.js.map +1 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-merge-iterable.js +14 -7
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-merge-iterable.js.map +1 -1
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-retry-iterable.js +29 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-retry-iterable.js.map +1 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-take-until-abort-iterable.js +32 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-take-until-abort-iterable.js.map +1 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-take-until-timeout-iterable.js +44 -0
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-take-until-timeout-iterable.js.map +1 -0
- package/dist/esm/collection/implementations/async-iterable-collection/async-iterable-collection.js +61 -40
- package/dist/esm/collection/implementations/async-iterable-collection/async-iterable-collection.js.map +1 -1
- package/dist/esm/collection/implementations/iterable-collection/_shared/merge-iterable.js +6 -7
- package/dist/esm/collection/implementations/iterable-collection/_shared/merge-iterable.js.map +1 -1
- package/dist/esm/collection/implementations/iterable-collection/iterable-collection.js +12 -3
- package/dist/esm/collection/implementations/iterable-collection/iterable-collection.js.map +1 -1
- package/dist/esm/collection/implementations/list-collection/list-collection.js +14 -1
- package/dist/esm/collection/implementations/list-collection/list-collection.js.map +1 -1
- package/dist/esm/event-bus/contracts/event-bus.errors.js +3 -3
- package/dist/esm/event-bus/contracts/event-bus.errors.js.map +1 -1
- package/dist/esm/event-bus/implementations/_module.js +1 -1
- package/dist/esm/event-bus/implementations/_module.js.map +1 -1
- package/dist/esm/event-bus/implementations/_shared/_module.js +3 -0
- package/dist/esm/event-bus/implementations/_shared/_module.js.map +1 -0
- package/dist/esm/event-bus/implementations/_shared/event-bus-adapter.test-suite.js +93 -0
- package/dist/esm/event-bus/implementations/_shared/event-bus-adapter.test-suite.js.map +1 -0
- package/dist/esm/event-bus/implementations/_shared/event-bus.test-suite.js +332 -0
- package/dist/esm/event-bus/implementations/_shared/event-bus.test-suite.js.map +1 -0
- package/dist/esm/event-bus/implementations/adapters/_module.js +1 -1
- package/dist/esm/event-bus/implementations/adapters/_module.js.map +1 -1
- package/dist/esm/event-bus/implementations/adapters/memory-event-bus-adapter/memory-event-bus-adapter.js +19 -9
- package/dist/esm/event-bus/implementations/adapters/memory-event-bus-adapter/memory-event-bus-adapter.js.map +1 -1
- package/dist/esm/event-bus/implementations/adapters/no-op-event-bus-adapter/no-op-event-bus-adapter.js +7 -1
- package/dist/esm/event-bus/implementations/adapters/no-op-event-bus-adapter/no-op-event-bus-adapter.js.map +1 -1
- package/dist/esm/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/_module.js.map +1 -0
- package/dist/esm/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/redis-pub-sub-event-bus-adapter.js +48 -0
- package/dist/esm/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/redis-pub-sub-event-bus-adapter.js.map +1 -0
- package/dist/esm/event-bus/implementations/derivables/event-bus-factory.js +4 -5
- package/dist/esm/event-bus/implementations/derivables/event-bus-factory.js.map +1 -1
- package/dist/esm/event-bus/implementations/derivables/event-bus.js +97 -34
- package/dist/esm/event-bus/implementations/derivables/event-bus.js.map +1 -1
- package/dist/esm/serde/contracts/_module.js +3 -0
- package/dist/esm/serde/contracts/_module.js.map +1 -0
- package/dist/esm/serde/contracts/serde.contract.js +1 -0
- package/dist/esm/serde/contracts/serde.contract.js.map +1 -0
- package/dist/esm/{serializer/contracts/serializer.errors.js → serde/contracts/serde.errors.js} +5 -5
- package/dist/esm/serde/contracts/serde.errors.js.map +1 -0
- package/dist/esm/serde/implementations/_module.js +6 -0
- package/dist/esm/serde/implementations/_module.js.map +1 -0
- package/dist/esm/serde/implementations/_shared/test-utilities/_module.js +2 -0
- package/dist/esm/serde/implementations/_shared/test-utilities/_module.js.map +1 -0
- package/dist/{cjs/serializer/implementations/_shared/test-utilities/serializer.test-suite.js → esm/serde/implementations/_shared/test-utilities/serde.test-suite.js} +62 -65
- package/dist/esm/serde/implementations/_shared/test-utilities/serde.test-suite.js.map +1 -0
- package/dist/esm/serde/implementations/mongodb-serde/_module.js +2 -0
- package/dist/esm/serde/implementations/mongodb-serde/_module.js.map +1 -0
- package/dist/esm/{serializer/implementations/mongodb-serializer/mongodb-serializer.js → serde/implementations/mongodb-serde/mongodb-serde.js} +10 -10
- package/dist/esm/serde/implementations/mongodb-serde/mongodb-serde.js.map +1 -0
- package/dist/esm/serde/implementations/redis-serde/_module.js +2 -0
- package/dist/esm/serde/implementations/redis-serde/_module.js.map +1 -0
- package/dist/esm/{serializer/implementations/sql-serializer/sql-serializer.js → serde/implementations/redis-serde/redis-serde.js} +10 -10
- package/dist/esm/serde/implementations/redis-serde/redis-serde.js.map +1 -0
- package/dist/esm/serde/implementations/sql-serde/_module.js +2 -0
- package/dist/esm/serde/implementations/sql-serde/_module.js.map +1 -0
- package/dist/esm/{serializer/implementations/redis-serializer/redis-serializer.js → serde/implementations/sql-serde/sql-serde.js} +10 -10
- package/dist/esm/serde/implementations/sql-serde/sql-serde.js.map +1 -0
- package/dist/esm/serde/implementations/super-json-serde/_module.js +2 -0
- package/dist/esm/serde/implementations/super-json-serde/_module.js.map +1 -0
- package/dist/esm/{serializer/implementations/super-json-serializer/super-json-serializer.js → serde/implementations/super-json-serde/super-json-serde.js} +52 -55
- package/dist/esm/serde/implementations/super-json-serde/super-json-serde.js.map +1 -0
- package/dist/esm/utilities/_module.js +5 -4
- package/dist/esm/utilities/_module.js.map +1 -1
- package/dist/esm/utilities/contracts/_module.js +3 -0
- package/dist/esm/utilities/contracts/_module.js.map +1 -0
- package/dist/esm/utilities/contracts/deinitizable.contract.js +1 -0
- package/dist/esm/utilities/contracts/deinitizable.contract.js.map +1 -0
- package/dist/esm/utilities/contracts/initizable.contract.js +1 -0
- package/dist/esm/utilities/contracts/initizable.contract.js.map +1 -0
- package/dist/esm/utilities/{global-errors.js → errors.js} +1 -1
- package/dist/esm/utilities/errors.js.map +1 -0
- package/dist/esm/{_shared/utilities.js → utilities/functions.js} +5 -5
- package/dist/esm/utilities/functions.js.map +1 -0
- package/dist/esm/utilities/kysely/_module.js +2 -0
- package/dist/esm/utilities/kysely/_module.js.map +1 -0
- package/dist/esm/utilities/kysely/kysely-table-name-transformer-plugin.js.map +1 -0
- package/dist/esm/utilities/time-span/time-span.js +8 -0
- package/dist/esm/utilities/time-span/time-span.js.map +1 -1
- package/dist/esm/{_shared → utilities}/types.js.map +1 -1
- package/dist/types/_module.d.ts +3 -2
- package/dist/types/async/_module.d.ts +3 -0
- package/dist/types/{utilities/async/_shared.d.ts → async/async.errors.d.ts} +6 -6
- package/dist/types/async/backof-policies/_module.d.ts +5 -0
- package/dist/types/{utilities → async}/backof-policies/_shared.d.ts +1 -1
- package/dist/types/async/backof-policies/constant-backoff-policy/_module.d.ts +1 -0
- package/dist/types/{utilities → async}/backof-policies/constant-backoff-policy/constant-backoff-policy.d.ts +2 -2
- package/dist/types/async/backof-policies/exponential-backoff-policy/_module.d.ts +1 -0
- package/dist/types/{utilities → async}/backof-policies/exponential-backoff-policy/exponential-backoff-policy.d.ts +2 -2
- package/dist/types/async/backof-policies/linear-backoff-policy/_module.d.ts +1 -0
- package/dist/types/{utilities → async}/backof-policies/linear-backoff-policy/linear-backoff-policy.d.ts +2 -2
- package/dist/types/async/backof-policies/polynomial-backoff-policy/_module.d.ts +1 -0
- package/dist/types/{utilities → async}/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.d.ts +2 -2
- package/dist/types/async/utilities/_module.d.ts +2 -0
- package/dist/types/async/utilities/abort/_module.d.ts +2 -0
- package/dist/types/async/utilities/abort/abort-and-fail.d.ts +4 -0
- package/dist/types/async/utilities/abort/abort.d.ts +9 -0
- package/dist/types/async/utilities/delay/_module.d.ts +1 -0
- package/dist/types/async/utilities/delay/delay.d.ts +19 -0
- package/dist/types/async/utilities/lazy-promise/_module.d.ts +1 -0
- package/dist/types/async/utilities/lazy-promise/lazy-promise.d.ts +222 -0
- package/dist/types/async/utilities/retry/_module.d.ts +2 -0
- package/dist/types/async/utilities/retry/retry-or-fail.d.ts +23 -0
- package/dist/types/async/utilities/retry/retry.d.ts +10 -0
- package/dist/types/async/utilities/timeout/_module.d.ts +2 -0
- package/dist/types/async/utilities/timeout/timeout-and-fail.d.ts +5 -0
- package/dist/types/async/utilities/timeout/timeout.d.ts +10 -0
- package/dist/types/cache/contracts/cache-adapter.contract.d.ts +20 -6
- package/dist/types/cache/contracts/cache-factory.contract.d.ts +4 -4
- package/dist/types/cache/contracts/cache.contract.d.ts +25 -43
- package/dist/types/cache/contracts/cache.events.d.ts +38 -91
- package/dist/types/cache/implementations/_shared/cache-adapter.test-suite.d.ts +34 -25
- package/dist/types/cache/implementations/_shared/cache.test-suite.d.ts +54 -43
- package/dist/types/cache/implementations/adapters/kysely-sqlite-cache-adapter/kysely-sqlite-cache-adapter.d.ts +11 -5
- package/dist/types/cache/implementations/adapters/libsql-cache-adapter/libsql-cache-adapter.d.ts +22 -9
- package/dist/types/cache/implementations/adapters/memory-cache-adapter/memory-cache-adapter.d.ts +12 -6
- package/dist/types/cache/implementations/adapters/mongodb-cache-adapter/mongodb-cache-adapter.d.ts +24 -11
- package/dist/types/cache/implementations/adapters/no-op-cache-adapter/no-op-cache-adapter.d.ts +5 -2
- package/dist/types/cache/implementations/adapters/redis-cache-adapter/redis-cache-adapter.d.ts +20 -13
- package/dist/types/cache/implementations/adapters/sqlite-cache-adapter/sqlite-cache-adapter.d.ts +22 -9
- package/dist/types/cache/implementations/derivables/_module.d.ts +0 -1
- package/dist/types/cache/implementations/derivables/cache-factory.d.ts +5 -11
- package/dist/types/cache/implementations/derivables/cache.d.ts +37 -42
- package/dist/types/collection/contracts/async-collection.contract.d.ts +10 -6
- package/dist/types/collection/contracts/collection.contract.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/_module.d.ts +4 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-chunk-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-chunk-while-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-cross-join-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-delay-iterable.d.ts +13 -0
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-entries-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-group-by-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-insert-after-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-insert-before-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-merge-iterable.d.ts +5 -6
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-pad-end-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-pad-start-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-partion-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-repeat-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-retry-iterable.d.ts +13 -0
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-reverse-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-split-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-take-until-abort-iterable.d.ts +9 -0
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-take-until-timeout-iterable.d.ts +13 -0
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-zip-iterable.d.ts +1 -1
- package/dist/types/collection/implementations/async-iterable-collection/async-iterable-collection.d.ts +10 -4
- package/dist/types/collection/implementations/iterable-collection/_shared/merge-iterable.d.ts +4 -5
- package/dist/types/collection/implementations/iterable-collection/iterable-collection.d.ts +4 -1
- package/dist/types/collection/implementations/list-collection/list-collection.d.ts +4 -1
- package/dist/types/event-bus/contracts/_shared.d.ts +2 -5
- package/dist/types/event-bus/contracts/event-bus-adapter.contract.d.ts +12 -6
- package/dist/types/event-bus/contracts/event-bus-factory.contract.d.ts +4 -5
- package/dist/types/event-bus/contracts/event-bus.contract.d.ts +58 -27
- package/dist/types/event-bus/contracts/event-bus.errors.d.ts +3 -3
- package/dist/types/event-bus/implementations/_module.d.ts +1 -1
- package/dist/types/event-bus/implementations/_shared/_module.d.ts +2 -0
- package/dist/types/event-bus/implementations/_shared/event-bus-adapter.test-suite.d.ts +68 -0
- package/dist/types/event-bus/implementations/_shared/event-bus.test-suite.d.ts +72 -0
- package/dist/types/event-bus/implementations/adapters/_module.d.ts +1 -1
- package/dist/types/event-bus/implementations/adapters/memory-event-bus-adapter/memory-event-bus-adapter.d.ts +10 -5
- package/dist/types/event-bus/implementations/adapters/no-op-event-bus-adapter/no-op-event-bus-adapter.d.ts +4 -1
- package/dist/types/event-bus/implementations/adapters/redis-pub-sub-event-bus-adapter/redis-pub-sub-event-bus-adapter.d.ts +50 -0
- package/dist/types/event-bus/implementations/derivables/event-bus-factory.d.ts +7 -8
- package/dist/types/event-bus/implementations/derivables/event-bus.d.ts +20 -46
- package/dist/types/serde/contracts/_module.d.ts +2 -0
- package/dist/types/serde/contracts/serde.contract.d.ts +41 -0
- package/dist/types/{serializer/contracts/serializer.errors.d.ts → serde/contracts/serde.errors.d.ts} +4 -4
- package/dist/types/serde/implementations/_module.d.ts +5 -0
- package/dist/types/serde/implementations/_shared/test-utilities/_module.d.ts +1 -0
- package/dist/types/serde/implementations/_shared/test-utilities/serde.test-suite.d.ts +18 -0
- package/dist/types/serde/implementations/mongodb-serde/_module.d.ts +1 -0
- package/dist/types/serde/implementations/mongodb-serde/mongodb-serde.d.ts +13 -0
- package/dist/types/serde/implementations/redis-serde/_module.d.ts +1 -0
- package/dist/types/serde/implementations/redis-serde/redis-serde.d.ts +13 -0
- package/dist/types/serde/implementations/sql-serde/_module.d.ts +1 -0
- package/dist/types/serde/implementations/sql-serde/sql-serde.d.ts +13 -0
- package/dist/types/serde/implementations/super-json-serde/_module.d.ts +1 -0
- package/dist/types/serde/implementations/super-json-serde/super-json-serde.d.ts +25 -0
- package/dist/types/utilities/_module.d.ts +5 -4
- package/dist/types/utilities/contracts/_module.d.ts +2 -0
- package/dist/types/utilities/contracts/deinitizable.contract.d.ts +9 -0
- package/dist/types/utilities/contracts/initizable.contract.d.ts +9 -0
- package/dist/types/utilities/{global-errors.d.ts → errors.d.ts} +10 -1
- package/dist/types/{_shared/utilities.d.ts → utilities/functions.d.ts} +4 -4
- package/dist/types/utilities/kysely/_module.d.ts +1 -0
- package/dist/types/{_shared → utilities}/kysely/kysely-table-name-transformer-plugin.d.ts +1 -1
- package/dist/types/utilities/time-span/time-span.d.ts +11 -2
- package/dist/types/{_shared → utilities}/types.d.ts +3 -8
- package/package.json +3 -9
- package/dist/cjs/_shared/kysely/_module.js.map +0 -1
- package/dist/cjs/_shared/kysely/kysely-table-name-transformer-plugin.js.map +0 -1
- package/dist/cjs/_shared/redis/_module.js.map +0 -1
- package/dist/cjs/_shared/redis/clear-iterable.js +0 -25
- package/dist/cjs/_shared/redis/clear-iterable.js.map +0 -1
- package/dist/cjs/_shared/redis/escape-redis-chars.js +0 -41
- package/dist/cjs/_shared/redis/escape-redis-chars.js.map +0 -1
- package/dist/cjs/_shared/redis/is-redis-type-error.js +0 -9
- package/dist/cjs/_shared/redis/is-redis-type-error.js.map +0 -1
- package/dist/cjs/_shared/utilities.js.map +0 -1
- package/dist/cjs/cache/implementations/derivables/base-cache.js +0 -262
- package/dist/cjs/cache/implementations/derivables/base-cache.js.map +0 -1
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-error-handler-iterable.js +0 -31
- package/dist/cjs/collection/implementations/async-iterable-collection/_shared/async-error-handler-iterable.js.map +0 -1
- package/dist/cjs/event-bus/implementations/_shared/test-utilities/_module.js.map +0 -1
- package/dist/cjs/event-bus/implementations/_shared/test-utilities/event-bus-adapter.test-suite.js +0 -51
- package/dist/cjs/event-bus/implementations/_shared/test-utilities/event-bus-adapter.test-suite.js.map +0 -1
- package/dist/cjs/event-bus/implementations/adapters/redis-event-bus-adapter/_module.js.map +0 -1
- package/dist/cjs/event-bus/implementations/adapters/redis-event-bus-adapter/redis-event-bus-adapter.js +0 -45
- package/dist/cjs/event-bus/implementations/adapters/redis-event-bus-adapter/redis-event-bus-adapter.js.map +0 -1
- package/dist/cjs/event-bus/implementations/derivables/base-event-bus.js +0 -47
- package/dist/cjs/event-bus/implementations/derivables/base-event-bus.js.map +0 -1
- package/dist/cjs/event-bus/implementations/derivables/with-namespace-event-bus-adapter.js +0 -42
- package/dist/cjs/event-bus/implementations/derivables/with-namespace-event-bus-adapter.js.map +0 -1
- package/dist/cjs/serializer/contracts/_module.js.map +0 -1
- package/dist/cjs/serializer/contracts/serializer.contract.js.map +0 -1
- package/dist/cjs/serializer/contracts/serializer.errors.js.map +0 -1
- package/dist/cjs/serializer/implementations/_module.js +0 -22
- package/dist/cjs/serializer/implementations/_module.js.map +0 -1
- package/dist/cjs/serializer/implementations/_shared/test-utilities/_module.js.map +0 -1
- package/dist/cjs/serializer/implementations/_shared/test-utilities/serializer.test-suite.js.map +0 -1
- package/dist/cjs/serializer/implementations/mongodb-serializer/_module.js.map +0 -1
- package/dist/cjs/serializer/implementations/mongodb-serializer/mongodb-serializer.js +0 -36
- package/dist/cjs/serializer/implementations/mongodb-serializer/mongodb-serializer.js.map +0 -1
- package/dist/cjs/serializer/implementations/redis-serializer/_module.js.map +0 -1
- package/dist/cjs/serializer/implementations/redis-serializer/redis-serializer.js +0 -37
- package/dist/cjs/serializer/implementations/redis-serializer/redis-serializer.js.map +0 -1
- package/dist/cjs/serializer/implementations/sql-serializer/_module.js.map +0 -1
- package/dist/cjs/serializer/implementations/sql-serializer/sql-serializer.js +0 -37
- package/dist/cjs/serializer/implementations/sql-serializer/sql-serializer.js.map +0 -1
- package/dist/cjs/serializer/implementations/super-json-serializer/_module.js +0 -18
- package/dist/cjs/serializer/implementations/super-json-serializer/_module.js.map +0 -1
- package/dist/cjs/serializer/implementations/super-json-serializer/super-json-serializer.js.map +0 -1
- package/dist/cjs/utilities/async/_module.js +0 -29
- package/dist/cjs/utilities/async/_module.js.map +0 -1
- package/dist/cjs/utilities/async/_shared.js.map +0 -1
- package/dist/cjs/utilities/async/abortable/_module.js.map +0 -1
- package/dist/cjs/utilities/async/abortable/abortable.js +0 -48
- package/dist/cjs/utilities/async/abortable/abortable.js.map +0 -1
- package/dist/cjs/utilities/async/abortable-iterable/_module.js.map +0 -1
- package/dist/cjs/utilities/async/abortable-iterable/abortable-iterable.js +0 -32
- package/dist/cjs/utilities/async/abortable-iterable/abortable-iterable.js.map +0 -1
- package/dist/cjs/utilities/async/delay/_module.js.map +0 -1
- package/dist/cjs/utilities/async/delay/delay.js +0 -24
- package/dist/cjs/utilities/async/delay/delay.js.map +0 -1
- package/dist/cjs/utilities/async/delay-iterable/_module.js.map +0 -1
- package/dist/cjs/utilities/async/delay-iterable/delay-iterable.js +0 -36
- package/dist/cjs/utilities/async/delay-iterable/delay-iterable.js.map +0 -1
- package/dist/cjs/utilities/async/lazy-promise/_module.js.map +0 -1
- package/dist/cjs/utilities/async/lazy-promise/lazy-promise.js +0 -22
- package/dist/cjs/utilities/async/lazy-promise/lazy-promise.js.map +0 -1
- package/dist/cjs/utilities/async/retry/_module.js.map +0 -1
- package/dist/cjs/utilities/async/retry/retry.js +0 -43
- package/dist/cjs/utilities/async/retry/retry.js.map +0 -1
- package/dist/cjs/utilities/async/retry-iterable/_module.js +0 -18
- package/dist/cjs/utilities/async/retry-iterable/_module.js.map +0 -1
- package/dist/cjs/utilities/async/retry-iterable/retry-iterable.js +0 -32
- package/dist/cjs/utilities/async/retry-iterable/retry-iterable.js.map +0 -1
- package/dist/cjs/utilities/async/timeout/_module.js.map +0 -1
- package/dist/cjs/utilities/async/timeout/timeout.js +0 -28
- package/dist/cjs/utilities/async/timeout/timeout.js.map +0 -1
- package/dist/cjs/utilities/async/timeout-iterable/_module.js +0 -18
- package/dist/cjs/utilities/async/timeout-iterable/_module.js.map +0 -1
- package/dist/cjs/utilities/async/timeout-iterable/timeout-iterable.js +0 -11
- package/dist/cjs/utilities/async/timeout-iterable/timeout-iterable.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/_module.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/_shared.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/constant-backoff-policy/_module.js +0 -18
- package/dist/cjs/utilities/backof-policies/constant-backoff-policy/_module.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/constant-backoff-policy/constant-backoff-policy.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/exponential-backoff-policy/_module.js +0 -18
- package/dist/cjs/utilities/backof-policies/exponential-backoff-policy/_module.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/exponential-backoff-policy/exponential-backoff-policy.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/linear-backoff-policy/_module.js +0 -18
- package/dist/cjs/utilities/backof-policies/linear-backoff-policy/_module.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/linear-backoff-policy/linear-backoff-policy.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/polynomial-backoff-policy/_module.js +0 -18
- package/dist/cjs/utilities/backof-policies/polynomial-backoff-policy/_module.js.map +0 -1
- package/dist/cjs/utilities/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.js.map +0 -1
- package/dist/cjs/utilities/global-errors.js.map +0 -1
- package/dist/cjs/utilities/validation/_module.js +0 -22
- package/dist/cjs/utilities/validation/_module.js.map +0 -1
- package/dist/esm/_shared/kysely/_module.js +0 -2
- package/dist/esm/_shared/kysely/_module.js.map +0 -1
- package/dist/esm/_shared/kysely/kysely-table-name-transformer-plugin.js.map +0 -1
- package/dist/esm/_shared/redis/_module.js +0 -4
- package/dist/esm/_shared/redis/_module.js.map +0 -1
- package/dist/esm/_shared/redis/clear-iterable.js +0 -21
- package/dist/esm/_shared/redis/clear-iterable.js.map +0 -1
- package/dist/esm/_shared/redis/escape-redis-chars.js +0 -38
- package/dist/esm/_shared/redis/escape-redis-chars.js.map +0 -1
- package/dist/esm/_shared/redis/is-redis-type-error.js +0 -6
- package/dist/esm/_shared/redis/is-redis-type-error.js.map +0 -1
- package/dist/esm/_shared/utilities.js.map +0 -1
- package/dist/esm/cache/implementations/derivables/base-cache.js +0 -258
- package/dist/esm/cache/implementations/derivables/base-cache.js.map +0 -1
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-error-handler-iterable.js +0 -27
- package/dist/esm/collection/implementations/async-iterable-collection/_shared/async-error-handler-iterable.js.map +0 -1
- package/dist/esm/event-bus/implementations/_shared/test-utilities/_module.js +0 -2
- package/dist/esm/event-bus/implementations/_shared/test-utilities/_module.js.map +0 -1
- package/dist/esm/event-bus/implementations/_shared/test-utilities/event-bus-adapter.test-suite.js +0 -48
- package/dist/esm/event-bus/implementations/_shared/test-utilities/event-bus-adapter.test-suite.js.map +0 -1
- package/dist/esm/event-bus/implementations/adapters/redis-event-bus-adapter/_module.js.map +0 -1
- package/dist/esm/event-bus/implementations/adapters/redis-event-bus-adapter/redis-event-bus-adapter.js +0 -41
- package/dist/esm/event-bus/implementations/adapters/redis-event-bus-adapter/redis-event-bus-adapter.js.map +0 -1
- package/dist/esm/event-bus/implementations/derivables/base-event-bus.js +0 -43
- package/dist/esm/event-bus/implementations/derivables/base-event-bus.js.map +0 -1
- package/dist/esm/event-bus/implementations/derivables/with-namespace-event-bus-adapter.js +0 -38
- package/dist/esm/event-bus/implementations/derivables/with-namespace-event-bus-adapter.js.map +0 -1
- package/dist/esm/serializer/contracts/_module.js +0 -3
- package/dist/esm/serializer/contracts/_module.js.map +0 -1
- package/dist/esm/serializer/contracts/serializer.contract.js +0 -1
- package/dist/esm/serializer/contracts/serializer.contract.js.map +0 -1
- package/dist/esm/serializer/contracts/serializer.errors.js.map +0 -1
- package/dist/esm/serializer/implementations/_module.js +0 -6
- package/dist/esm/serializer/implementations/_module.js.map +0 -1
- package/dist/esm/serializer/implementations/_shared/test-utilities/_module.js +0 -2
- package/dist/esm/serializer/implementations/_shared/test-utilities/_module.js.map +0 -1
- package/dist/esm/serializer/implementations/_shared/test-utilities/serializer.test-suite.js.map +0 -1
- package/dist/esm/serializer/implementations/mongodb-serializer/_module.js +0 -2
- package/dist/esm/serializer/implementations/mongodb-serializer/_module.js.map +0 -1
- package/dist/esm/serializer/implementations/mongodb-serializer/mongodb-serializer.js.map +0 -1
- package/dist/esm/serializer/implementations/redis-serializer/_module.js +0 -2
- package/dist/esm/serializer/implementations/redis-serializer/_module.js.map +0 -1
- package/dist/esm/serializer/implementations/redis-serializer/redis-serializer.js.map +0 -1
- package/dist/esm/serializer/implementations/sql-serializer/_module.js +0 -2
- package/dist/esm/serializer/implementations/sql-serializer/_module.js.map +0 -1
- package/dist/esm/serializer/implementations/sql-serializer/sql-serializer.js.map +0 -1
- package/dist/esm/serializer/implementations/super-json-serializer/_module.js +0 -2
- package/dist/esm/serializer/implementations/super-json-serializer/_module.js.map +0 -1
- package/dist/esm/serializer/implementations/super-json-serializer/super-json-serializer.js.map +0 -1
- package/dist/esm/utilities/async/_module.js +0 -11
- package/dist/esm/utilities/async/_module.js.map +0 -1
- package/dist/esm/utilities/async/_shared.js.map +0 -1
- package/dist/esm/utilities/async/abortable/_module.js +0 -2
- package/dist/esm/utilities/async/abortable/_module.js.map +0 -1
- package/dist/esm/utilities/async/abortable/abortable.js.map +0 -1
- package/dist/esm/utilities/async/abortable-iterable/_module.js +0 -2
- package/dist/esm/utilities/async/abortable-iterable/_module.js.map +0 -1
- package/dist/esm/utilities/async/abortable-iterable/abortable-iterable.js +0 -29
- package/dist/esm/utilities/async/abortable-iterable/abortable-iterable.js.map +0 -1
- package/dist/esm/utilities/async/delay/_module.js +0 -2
- package/dist/esm/utilities/async/delay/_module.js.map +0 -1
- package/dist/esm/utilities/async/delay/delay.js +0 -21
- package/dist/esm/utilities/async/delay/delay.js.map +0 -1
- package/dist/esm/utilities/async/delay-iterable/_module.js +0 -2
- package/dist/esm/utilities/async/delay-iterable/_module.js.map +0 -1
- package/dist/esm/utilities/async/delay-iterable/delay-iterable.js +0 -33
- package/dist/esm/utilities/async/delay-iterable/delay-iterable.js.map +0 -1
- package/dist/esm/utilities/async/lazy-promise/_module.js +0 -2
- package/dist/esm/utilities/async/lazy-promise/_module.js.map +0 -1
- package/dist/esm/utilities/async/lazy-promise/lazy-promise.js +0 -17
- package/dist/esm/utilities/async/lazy-promise/lazy-promise.js.map +0 -1
- package/dist/esm/utilities/async/retry/_module.js +0 -2
- package/dist/esm/utilities/async/retry/_module.js.map +0 -1
- package/dist/esm/utilities/async/retry/retry.js +0 -40
- package/dist/esm/utilities/async/retry/retry.js.map +0 -1
- package/dist/esm/utilities/async/retry-iterable/_module.js +0 -2
- package/dist/esm/utilities/async/retry-iterable/_module.js.map +0 -1
- package/dist/esm/utilities/async/retry-iterable/retry-iterable.js +0 -29
- package/dist/esm/utilities/async/retry-iterable/retry-iterable.js.map +0 -1
- package/dist/esm/utilities/async/timeout/_module.js +0 -2
- package/dist/esm/utilities/async/timeout/_module.js.map +0 -1
- package/dist/esm/utilities/async/timeout/timeout.js +0 -25
- package/dist/esm/utilities/async/timeout/timeout.js.map +0 -1
- package/dist/esm/utilities/async/timeout-iterable/_module.js +0 -2
- package/dist/esm/utilities/async/timeout-iterable/_module.js.map +0 -1
- package/dist/esm/utilities/async/timeout-iterable/timeout-iterable.js +0 -8
- package/dist/esm/utilities/async/timeout-iterable/timeout-iterable.js.map +0 -1
- package/dist/esm/utilities/backof-policies/_module.js +0 -5
- package/dist/esm/utilities/backof-policies/_module.js.map +0 -1
- package/dist/esm/utilities/backof-policies/_shared.js.map +0 -1
- package/dist/esm/utilities/backof-policies/constant-backoff-policy/_module.js +0 -2
- package/dist/esm/utilities/backof-policies/constant-backoff-policy/_module.js.map +0 -1
- package/dist/esm/utilities/backof-policies/constant-backoff-policy/constant-backoff-policy.js.map +0 -1
- package/dist/esm/utilities/backof-policies/exponential-backoff-policy/_module.js +0 -2
- package/dist/esm/utilities/backof-policies/exponential-backoff-policy/_module.js.map +0 -1
- package/dist/esm/utilities/backof-policies/exponential-backoff-policy/exponential-backoff-policy.js.map +0 -1
- package/dist/esm/utilities/backof-policies/linear-backoff-policy/_module.js +0 -2
- package/dist/esm/utilities/backof-policies/linear-backoff-policy/_module.js.map +0 -1
- package/dist/esm/utilities/backof-policies/linear-backoff-policy/linear-backoff-policy.js.map +0 -1
- package/dist/esm/utilities/backof-policies/polynomial-backoff-policy/_module.js +0 -2
- package/dist/esm/utilities/backof-policies/polynomial-backoff-policy/_module.js.map +0 -1
- package/dist/esm/utilities/backof-policies/polynomial-backoff-policy/polynomial-backoff-policy.js.map +0 -1
- package/dist/esm/utilities/global-errors.js.map +0 -1
- package/dist/esm/utilities/validation/_module.js +0 -17
- package/dist/esm/utilities/validation/_module.js.map +0 -1
- package/dist/types/_shared/kysely/_module.d.ts +0 -1
- package/dist/types/_shared/redis/_module.d.ts +0 -3
- package/dist/types/_shared/redis/clear-iterable.d.ts +0 -13
- package/dist/types/_shared/redis/escape-redis-chars.d.ts +0 -7
- package/dist/types/_shared/redis/is-redis-type-error.d.ts +0 -7
- package/dist/types/cache/implementations/derivables/base-cache.d.ts +0 -57
- package/dist/types/collection/implementations/async-iterable-collection/_shared/async-error-handler-iterable.d.ts +0 -12
- package/dist/types/event-bus/implementations/_shared/test-utilities/_module.d.ts +0 -1
- package/dist/types/event-bus/implementations/_shared/test-utilities/event-bus-adapter.test-suite.d.ts +0 -36
- package/dist/types/event-bus/implementations/adapters/redis-event-bus-adapter/redis-event-bus-adapter.d.ts +0 -43
- package/dist/types/event-bus/implementations/derivables/base-event-bus.d.ts +0 -23
- package/dist/types/event-bus/implementations/derivables/with-namespace-event-bus-adapter.d.ts +0 -16
- package/dist/types/serializer/contracts/_module.d.ts +0 -2
- package/dist/types/serializer/contracts/serializer.contract.d.ts +0 -16
- package/dist/types/serializer/implementations/_module.d.ts +0 -5
- package/dist/types/serializer/implementations/_shared/test-utilities/_module.d.ts +0 -1
- package/dist/types/serializer/implementations/_shared/test-utilities/serializer.test-suite.d.ts +0 -18
- package/dist/types/serializer/implementations/mongodb-serializer/_module.d.ts +0 -1
- package/dist/types/serializer/implementations/mongodb-serializer/mongodb-serializer.d.ts +0 -13
- package/dist/types/serializer/implementations/redis-serializer/_module.d.ts +0 -1
- package/dist/types/serializer/implementations/redis-serializer/redis-serializer.d.ts +0 -13
- package/dist/types/serializer/implementations/sql-serializer/_module.d.ts +0 -1
- package/dist/types/serializer/implementations/sql-serializer/sql-serializer.d.ts +0 -13
- package/dist/types/serializer/implementations/super-json-serializer/_module.d.ts +0 -1
- package/dist/types/serializer/implementations/super-json-serializer/super-json-serializer.d.ts +0 -37
- package/dist/types/utilities/async/_module.d.ts +0 -10
- package/dist/types/utilities/async/abortable/_module.d.ts +0 -1
- package/dist/types/utilities/async/abortable/abortable.d.ts +0 -39
- package/dist/types/utilities/async/abortable-iterable/_module.d.ts +0 -1
- package/dist/types/utilities/async/abortable-iterable/abortable-iterable.d.ts +0 -36
- package/dist/types/utilities/async/delay/_module.d.ts +0 -1
- package/dist/types/utilities/async/delay/delay.d.ts +0 -38
- package/dist/types/utilities/async/delay-iterable/_module.d.ts +0 -1
- package/dist/types/utilities/async/delay-iterable/delay-iterable.d.ts +0 -57
- package/dist/types/utilities/async/lazy-promise/_module.d.ts +0 -1
- package/dist/types/utilities/async/lazy-promise/lazy-promise.d.ts +0 -28
- package/dist/types/utilities/async/retry/_module.d.ts +0 -1
- package/dist/types/utilities/async/retry/retry.d.ts +0 -89
- package/dist/types/utilities/async/retry-iterable/_module.d.ts +0 -1
- package/dist/types/utilities/async/retry-iterable/retry-iterable.d.ts +0 -86
- package/dist/types/utilities/async/timeout/_module.d.ts +0 -1
- package/dist/types/utilities/async/timeout/timeout.d.ts +0 -40
- package/dist/types/utilities/async/timeout-iterable/_module.d.ts +0 -1
- package/dist/types/utilities/async/timeout-iterable/timeout-iterable.d.ts +0 -64
- package/dist/types/utilities/backof-policies/_module.d.ts +0 -5
- package/dist/types/utilities/backof-policies/constant-backoff-policy/_module.d.ts +0 -1
- package/dist/types/utilities/backof-policies/exponential-backoff-policy/_module.d.ts +0 -1
- package/dist/types/utilities/backof-policies/linear-backoff-policy/_module.d.ts +0 -1
- package/dist/types/utilities/backof-policies/polynomial-backoff-policy/_module.d.ts +0 -1
- package/dist/types/utilities/validation/_module.d.ts +0 -32
- /package/dist/cjs/{utilities → async}/backof-policies/_shared.js +0 -0
- /package/dist/cjs/event-bus/implementations/adapters/{redis-event-bus-adapter → redis-pub-sub-event-bus-adapter}/_module.js +0 -0
- /package/dist/cjs/{_shared → utilities}/kysely/kysely-table-name-transformer-plugin.js +0 -0
- /package/dist/cjs/{_shared → utilities}/types.js +0 -0
- /package/dist/esm/{utilities → async}/backof-policies/_shared.js +0 -0
- /package/dist/esm/event-bus/implementations/adapters/{redis-event-bus-adapter → redis-pub-sub-event-bus-adapter}/_module.js +0 -0
- /package/dist/esm/{_shared → utilities}/kysely/kysely-table-name-transformer-plugin.js +0 -0
- /package/dist/esm/{_shared → utilities}/types.js +0 -0
- /package/dist/types/event-bus/implementations/adapters/{redis-event-bus-adapter → redis-pub-sub-event-bus-adapter}/_module.d.ts +0 -0
|
@@ -1,64 +1,127 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.EventBus = void 0;
|
|
4
|
-
const _module_1 = require("../../../
|
|
4
|
+
const _module_1 = require("../../../async/_module");
|
|
5
5
|
const _module_2 = require("../../../event-bus/contracts/_module");
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
const base_event_bus_1 = require("../../../event-bus/implementations/derivables/base-event-bus");
|
|
9
|
-
class EventBus extends base_event_bus_1.BaseEventBus {
|
|
6
|
+
const _module_3 = require("../../../utilities/_module");
|
|
7
|
+
class EventBus {
|
|
10
8
|
eventBusAdapter;
|
|
11
|
-
|
|
9
|
+
lazyPromiseSettings;
|
|
12
10
|
constructor(eventBusAdapter, settings = {}) {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
this.namespace = namespace;
|
|
17
|
-
this.eventBusAdapter = new with_namespace_event_bus_adapter_1.WithNamespaceEventBusAdapter(eventBusAdapter, this.namespace);
|
|
11
|
+
const { lazyPromiseSettings } = settings;
|
|
12
|
+
this.lazyPromiseSettings = lazyPromiseSettings;
|
|
13
|
+
this.eventBusAdapter = eventBusAdapter;
|
|
18
14
|
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
15
|
+
createLayPromise(asyncFn) {
|
|
16
|
+
return new _module_1.LazyPromise(asyncFn, this.lazyPromiseSettings);
|
|
17
|
+
}
|
|
18
|
+
withGroup(group) {
|
|
19
|
+
return new EventBus(this.eventBusAdapter.withGroup(group), {
|
|
20
|
+
lazyPromiseSettings: this.lazyPromiseSettings,
|
|
23
21
|
});
|
|
24
22
|
}
|
|
25
|
-
|
|
26
|
-
return this.
|
|
23
|
+
getGroup() {
|
|
24
|
+
return this.eventBusAdapter.getGroup();
|
|
27
25
|
}
|
|
28
|
-
addListener(
|
|
29
|
-
return
|
|
26
|
+
addListener(eventName, listener) {
|
|
27
|
+
return this.createLayPromise(async () => {
|
|
30
28
|
try {
|
|
31
|
-
|
|
29
|
+
if (typeof eventName !== "string") {
|
|
30
|
+
throw new _module_2.UnexpectedEventBusError(`The event name "${String(eventName)}" must be of string name`);
|
|
31
|
+
}
|
|
32
|
+
await this.eventBusAdapter.addListener(eventName, listener);
|
|
32
33
|
}
|
|
33
34
|
catch (error) {
|
|
34
|
-
throw new _module_2.AddListenerEventBusError(`A listener with name of "${listener.name}" could not added for "${String(
|
|
35
|
+
throw new _module_2.AddListenerEventBusError(`A listener with name of "${listener.name}" could not added for "${String(eventName)}" event`, error);
|
|
35
36
|
}
|
|
36
37
|
});
|
|
37
38
|
}
|
|
38
|
-
removeListener(
|
|
39
|
-
return
|
|
39
|
+
removeListener(eventName, listener) {
|
|
40
|
+
return this.createLayPromise(async () => {
|
|
41
|
+
if (typeof eventName !== "string") {
|
|
42
|
+
throw new _module_2.UnexpectedEventBusError(`The event name "${String(eventName)}" must be of string name`);
|
|
43
|
+
}
|
|
40
44
|
try {
|
|
41
|
-
await this.eventBusAdapter.removeListener(
|
|
45
|
+
await this.eventBusAdapter.removeListener(eventName, listener);
|
|
42
46
|
}
|
|
43
47
|
catch (error) {
|
|
44
|
-
throw new _module_2.RemoveListenerEventBusError(`A listener with name of "${listener.name}" could not removed of "${String(
|
|
48
|
+
throw new _module_2.RemoveListenerEventBusError(`A listener with name of "${listener.name}" could not removed of "${String(eventName)}" event`, error);
|
|
45
49
|
}
|
|
46
50
|
});
|
|
47
51
|
}
|
|
48
|
-
|
|
49
|
-
return
|
|
50
|
-
|
|
51
|
-
|
|
52
|
+
dispatchMany(events) {
|
|
53
|
+
return this.createLayPromise(async () => {
|
|
54
|
+
try {
|
|
55
|
+
const promises = [];
|
|
56
|
+
for (const event of events) {
|
|
57
|
+
promises.push(this.eventBusAdapter.dispatch(event));
|
|
58
|
+
}
|
|
59
|
+
await Promise.all(promises);
|
|
52
60
|
}
|
|
53
|
-
|
|
54
|
-
|
|
61
|
+
catch (error) {
|
|
62
|
+
throw new _module_2.DispatchEventBusError(`Events of types "${events.map((event) => event.type).join(", ")}" could not be dispatched`, error);
|
|
55
63
|
}
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
dispatch(event) {
|
|
67
|
+
return this.createLayPromise(async () => {
|
|
56
68
|
try {
|
|
57
|
-
await this.eventBusAdapter.dispatch(
|
|
69
|
+
await this.eventBusAdapter.dispatch(event);
|
|
58
70
|
}
|
|
59
71
|
catch (error) {
|
|
60
|
-
throw new _module_2.DispatchEventBusError(`
|
|
72
|
+
throw new _module_2.DispatchEventBusError(`Event of type "${String(event.type)}" could not be dispatched`, error);
|
|
73
|
+
}
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
addListenerMany(eventNames, listener) {
|
|
77
|
+
return this.createLayPromise(async () => {
|
|
78
|
+
if ((0, _module_3.isArrayEmpty)(eventNames)) {
|
|
79
|
+
return;
|
|
61
80
|
}
|
|
81
|
+
const promises = [];
|
|
82
|
+
for (const event of eventNames) {
|
|
83
|
+
promises.push(this.addListener(event, listener));
|
|
84
|
+
}
|
|
85
|
+
await Promise.all(promises);
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
removeListenerMany(eventNames, listener) {
|
|
89
|
+
return this.createLayPromise(async () => {
|
|
90
|
+
if ((0, _module_3.isArrayEmpty)(eventNames)) {
|
|
91
|
+
return;
|
|
92
|
+
}
|
|
93
|
+
const promises = [];
|
|
94
|
+
for (const event of eventNames) {
|
|
95
|
+
promises.push(this.removeListener(event, listener));
|
|
96
|
+
}
|
|
97
|
+
await Promise.all(promises);
|
|
98
|
+
});
|
|
99
|
+
}
|
|
100
|
+
listenOnce(eventName, listener) {
|
|
101
|
+
return this.createLayPromise(async () => {
|
|
102
|
+
const wrappedListener = async (event) => {
|
|
103
|
+
try {
|
|
104
|
+
await listener(event);
|
|
105
|
+
}
|
|
106
|
+
finally {
|
|
107
|
+
await this.removeListener(eventName, wrappedListener);
|
|
108
|
+
}
|
|
109
|
+
};
|
|
110
|
+
await this.addListener(eventName, wrappedListener);
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
subscribe(eventName, listener) {
|
|
114
|
+
return this.subscribeMany([eventName], listener);
|
|
115
|
+
}
|
|
116
|
+
subscribeMany(eventNames, listener) {
|
|
117
|
+
return this.createLayPromise(async () => {
|
|
118
|
+
await this.addListenerMany(eventNames, listener);
|
|
119
|
+
const unsubscribe = () => {
|
|
120
|
+
return this.createLayPromise(async () => {
|
|
121
|
+
await this.removeListenerMany(eventNames, listener);
|
|
122
|
+
});
|
|
123
|
+
};
|
|
124
|
+
return unsubscribe;
|
|
62
125
|
});
|
|
63
126
|
}
|
|
64
127
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"event-bus.js","sourceRoot":"","sources":["../../../../../src/event-bus/implementations/derivables/event-bus.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"event-bus.js","sourceRoot":"","sources":["../../../../../src/event-bus/implementations/derivables/event-bus.ts"],"names":[],"mappings":";;;AAKA,6CAA8C;AAO9C,2DAUuC;AAGvC,iDAAmD;AAanD,MAAa,QAAQ;IAGA,eAAe,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pC,MAAM,eAAe,GAAG,KAAK,EACzB,KAAuC,EACzC,EAAE;gBACA,IAAI,CAAC;oBACD,MAAM,QAAQ,CAAC,KAAK,CAAC,CAAC;gBAC1B,CAAC;wBAAS,CAAC;oBACP,MAAM,IAAI,CAAC,cAAc,CAAC,SAAS,EAAE,eAAe,CAAC,CAAC;gBAC1D,CAAC;YACL,CAAC,CAAC;YACF,MAAM,IAAI,CAAC,WAAW,CAAC,SAAS,EAAE,eAAe,CAAC,CAAC;QACvD,CAAC,CAAC,CAAC;IACP,CAAC;IAED,SAAS,CACL,SAAqB,EACrB,QAAoD;QAEpD,OAAO,IAAI,CAAC,aAAa,CAAC,CAAC,SAAS,CAAC,EAAE,QAAQ,CAAC,CAAC;IACrD,CAAC;IAED,aAAa,CACT,UAAwB,EACxB,QAAoD;QAEpD,OAAO,IAAI,CAAC,gBAAgB,CAAC,KAAK,IAAI,EAAE;YACpC,MAAM,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAC;YACjD,MAAM,WAAW,GAAG,GAAG,EAAE;gBACrB,OAAO,IAAI,CAAC,gBAAgB,CAAC,KAAK,IAAI,EAAE;oBACpC,MAAM,IAAI,CAAC,kBAAkB,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAC;gBACxD,CAAC,CAAC,CAAC;YACP,CAAC,CAAC;YACF,OAAO,WAAW,CAAC;QACvB,CAAC,CAAC,CAAC;IACP,CAAC;CACJ;AAtLD,4BAsLC"}
|
|
@@ -14,5 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("
|
|
17
|
+
__exportStar(require("../../serde/contracts/serde.contract"), exports);
|
|
18
|
+
__exportStar(require("../../serde/contracts/serde.errors"), exports);
|
|
18
19
|
//# sourceMappingURL=_module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_module.js","sourceRoot":"","sources":["../../../../src/serde/contracts/_module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mEAAiD;AACjD,iEAA+C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"serde.contract.js","sourceRoot":"","sources":["../../../../src/serde/contracts/serde.contract.ts"],"names":[],"mappings":""}
|
package/dist/cjs/{serializer/contracts/serializer.errors.js → serde/contracts/serde.errors.js}
RENAMED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.DeserializationError = exports.SerializationError = exports.
|
|
4
|
-
class
|
|
3
|
+
exports.DeserializationError = exports.SerializationError = exports.SerdeError = void 0;
|
|
4
|
+
class SerdeError extends Error {
|
|
5
5
|
constructor(message, cause) {
|
|
6
6
|
super(message, { cause });
|
|
7
|
-
this.name =
|
|
7
|
+
this.name = SerdeError.name;
|
|
8
8
|
}
|
|
9
9
|
}
|
|
10
|
-
exports.
|
|
11
|
-
class SerializationError extends
|
|
10
|
+
exports.SerdeError = SerdeError;
|
|
11
|
+
class SerializationError extends SerdeError {
|
|
12
12
|
constructor(message, cause) {
|
|
13
13
|
super(message, { cause });
|
|
14
14
|
this.name = SerializationError.name;
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
17
|
exports.SerializationError = SerializationError;
|
|
18
|
-
class DeserializationError extends
|
|
18
|
+
class DeserializationError extends SerdeError {
|
|
19
19
|
constructor(message, cause) {
|
|
20
20
|
super(message, { cause });
|
|
21
21
|
this.name = DeserializationError.name;
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
exports.DeserializationError = DeserializationError;
|
|
25
|
-
//# sourceMappingURL=
|
|
25
|
+
//# sourceMappingURL=serde.errors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"serde.errors.js","sourceRoot":"","sources":["../../../../src/serde/contracts/serde.errors.ts"],"names":[],"mappings":";;;AAOA,MAAa,UAAW,SAAQ,KAAK;IACjC,YAAY,OAAe,EAAE,KAAe;QACxC,KAAK,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;QAC1B,IAAI,CAAC,IAAI,GAAG,UAAU,CAAC,IAAI,CAAC;IAChC,CAAC;CACJ;AALD,gCAKC;AAKD,MAAa,kBAAmB,SAAQ,UAAU;IAC9C,YAAY,OAAe,EAAE,KAAe;QACxC,KAAK,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;QAC1B,IAAI,CAAC,IAAI,GAAG,kBAAkB,CAAC,IAAI,CAAC;IACxC,CAAC;CACJ;AALD,gDAKC;AAKD,MAAa,oBAAqB,SAAQ,UAAU;IAChD,YAAY,OAAe,EAAE,KAAe;QACxC,KAAK,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;QAC1B,IAAI,CAAC,IAAI,GAAG,oBAAoB,CAAC,IAAI,CAAC;IAC1C,CAAC;CACJ;AALD,oDAKC"}
|
|
@@ -14,7 +14,9 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("../../_shared/
|
|
18
|
-
__exportStar(require("../../
|
|
19
|
-
__exportStar(require("../../
|
|
17
|
+
__exportStar(require("../../serde/implementations/_shared/test-utilities/_module"), exports);
|
|
18
|
+
__exportStar(require("../../serde/implementations/mongodb-serde/_module"), exports);
|
|
19
|
+
__exportStar(require("../../serde/implementations/redis-serde/_module"), exports);
|
|
20
|
+
__exportStar(require("../../serde/implementations/sql-serde/_module"), exports);
|
|
21
|
+
__exportStar(require("../../serde/implementations/super-json-serde/_module"), exports);
|
|
20
22
|
//# sourceMappingURL=_module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_module.js","sourceRoot":"","sources":["../../../../src/serde/implementations/_module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yFAAuE;AACvE,gFAA8D;AAC9D,8EAA4D;AAC5D,4EAA0D;AAC1D,mFAAiE"}
|
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("
|
|
17
|
+
__exportStar(require("../../../../serde/implementations/_shared/test-utilities/serde.test-suite"), exports);
|
|
18
18
|
//# sourceMappingURL=_module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_module.js","sourceRoot":"","sources":["../../../../../../src/serde/implementations/_shared/test-utilities/_module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kGAAgF"}
|
|
@@ -1,143 +1,146 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.serdeTestSuite = serdeTestSuite;
|
|
4
|
+
function serdeTestSuite(settings) {
|
|
2
5
|
const { expect, test, createAdapter } = settings;
|
|
3
6
|
test("Should work with positive integer", async () => {
|
|
4
|
-
const
|
|
7
|
+
const serde = await createAdapter();
|
|
5
8
|
const value = 1;
|
|
6
|
-
expect(
|
|
9
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
7
10
|
});
|
|
8
11
|
test("Should work with negative integer", async () => {
|
|
9
|
-
const
|
|
12
|
+
const serde = await createAdapter();
|
|
10
13
|
const value = -1;
|
|
11
|
-
expect(
|
|
14
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
12
15
|
});
|
|
13
16
|
test("Should work with positive decimal", async () => {
|
|
14
|
-
const
|
|
17
|
+
const serde = await createAdapter();
|
|
15
18
|
const value = 1.5;
|
|
16
|
-
expect(
|
|
19
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
17
20
|
});
|
|
18
21
|
test("Should work with negative decimal", async () => {
|
|
19
|
-
const
|
|
22
|
+
const serde = await createAdapter();
|
|
20
23
|
const value = -1.5;
|
|
21
|
-
expect(
|
|
24
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
22
25
|
});
|
|
23
26
|
test("Should work with NaN", async () => {
|
|
24
|
-
const
|
|
27
|
+
const serde = await createAdapter();
|
|
25
28
|
const value = NaN;
|
|
26
|
-
const deserializedValue =
|
|
29
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
27
30
|
expect(deserializedValue).toBeNaN();
|
|
28
31
|
});
|
|
29
32
|
test("Should work with Infinity", async () => {
|
|
30
|
-
const
|
|
33
|
+
const serde = await createAdapter();
|
|
31
34
|
const value = Infinity;
|
|
32
|
-
const deserializedValue =
|
|
35
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
33
36
|
expect(isFinite(deserializedValue)).toBe(false);
|
|
34
37
|
});
|
|
35
38
|
test("Should work with Bigint", async () => {
|
|
36
|
-
const
|
|
39
|
+
const serde = await createAdapter();
|
|
37
40
|
const value = 20n;
|
|
38
|
-
expect(
|
|
41
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
39
42
|
});
|
|
40
43
|
test("Should work with true", async () => {
|
|
41
|
-
const
|
|
44
|
+
const serde = await createAdapter();
|
|
42
45
|
const value = true;
|
|
43
|
-
expect(
|
|
46
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
44
47
|
});
|
|
45
48
|
test("Should work with false", async () => {
|
|
46
|
-
const
|
|
49
|
+
const serde = await createAdapter();
|
|
47
50
|
const value = false;
|
|
48
|
-
expect(
|
|
51
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
49
52
|
});
|
|
50
53
|
test("Should work with string", async () => {
|
|
51
|
-
const
|
|
54
|
+
const serde = await createAdapter();
|
|
52
55
|
const value = "str";
|
|
53
|
-
expect(
|
|
56
|
+
expect(serde.deserialize(serde.serialize(value))).toBe(value);
|
|
54
57
|
});
|
|
55
58
|
test("Should work with Date", async () => {
|
|
56
|
-
const
|
|
59
|
+
const serde = await createAdapter();
|
|
57
60
|
const value = new Date("2024-01-01");
|
|
58
|
-
const deserializedValue =
|
|
61
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
59
62
|
expect(deserializedValue).toBeInstanceOf(Date);
|
|
60
63
|
expect(deserializedValue).toEqual(value);
|
|
61
64
|
});
|
|
62
65
|
test("Should work with RegExp", async () => {
|
|
63
|
-
const
|
|
66
|
+
const serde = await createAdapter();
|
|
64
67
|
const value = /test/;
|
|
65
|
-
const deserializedValue =
|
|
68
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
66
69
|
expect(deserializedValue).toBeInstanceOf(RegExp);
|
|
67
70
|
expect(deserializedValue).toEqual(value);
|
|
68
71
|
});
|
|
69
72
|
test("Should work with Buffer", async () => {
|
|
70
|
-
const
|
|
73
|
+
const serde = await createAdapter();
|
|
71
74
|
const value = Buffer.from("asd");
|
|
72
|
-
const deserializedValue =
|
|
75
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
73
76
|
expect(deserializedValue).toBeInstanceOf(Buffer);
|
|
74
77
|
expect(deserializedValue.toString("base64")).toEqual(value.toString("base64"));
|
|
75
78
|
});
|
|
76
79
|
test("Should work with Uint8Array", async () => {
|
|
77
|
-
const
|
|
80
|
+
const serde = await createAdapter();
|
|
78
81
|
const value = new Uint8Array(Buffer.from("asd"));
|
|
79
|
-
const deserializedValue =
|
|
82
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
80
83
|
expect(deserializedValue).toBeInstanceOf(Uint8Array);
|
|
81
84
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
82
85
|
});
|
|
83
86
|
test("Should work with Int8Array", async () => {
|
|
84
|
-
const
|
|
87
|
+
const serde = await createAdapter();
|
|
85
88
|
const value = new Int8Array(Buffer.from("asd"));
|
|
86
|
-
const deserializedValue =
|
|
89
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
87
90
|
expect(deserializedValue).toBeInstanceOf(Int8Array);
|
|
88
91
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
89
92
|
});
|
|
90
93
|
test("Should work with Uint16Array", async () => {
|
|
91
|
-
const
|
|
94
|
+
const serde = await createAdapter();
|
|
92
95
|
const value = new Uint16Array(Buffer.from("asd"));
|
|
93
|
-
const deserializedValue =
|
|
96
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
94
97
|
expect(deserializedValue).toBeInstanceOf(Uint16Array);
|
|
95
98
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
96
99
|
});
|
|
97
100
|
test("Should work with Int16Array", async () => {
|
|
98
|
-
const
|
|
101
|
+
const serde = await createAdapter();
|
|
99
102
|
const value = new Int16Array(Buffer.from("asd"));
|
|
100
|
-
const deserializedValue =
|
|
103
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
101
104
|
expect(deserializedValue).toBeInstanceOf(Int16Array);
|
|
102
105
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
103
106
|
});
|
|
104
107
|
test("Should work with Uint32Array", async () => {
|
|
105
|
-
const
|
|
108
|
+
const serde = await createAdapter();
|
|
106
109
|
const value = new Uint32Array(Buffer.from("asd"));
|
|
107
|
-
const deserializedValue =
|
|
110
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
108
111
|
expect(deserializedValue).toBeInstanceOf(Uint32Array);
|
|
109
112
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
110
113
|
});
|
|
111
114
|
test("Should work with Int32Array", async () => {
|
|
112
|
-
const
|
|
115
|
+
const serde = await createAdapter();
|
|
113
116
|
const value = new Int32Array(Buffer.from("asd"));
|
|
114
|
-
const deserializedValue =
|
|
117
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
115
118
|
expect(deserializedValue).toBeInstanceOf(Int32Array);
|
|
116
119
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
117
120
|
});
|
|
118
121
|
test("Should work with Float32Array", async () => {
|
|
119
|
-
const
|
|
122
|
+
const serde = await createAdapter();
|
|
120
123
|
const value = new Float32Array(Buffer.from("asd"));
|
|
121
|
-
const deserializedValue =
|
|
124
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
122
125
|
expect(deserializedValue).toBeInstanceOf(Float32Array);
|
|
123
126
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
124
127
|
});
|
|
125
128
|
test("Should work with Float64Array", async () => {
|
|
126
|
-
const
|
|
129
|
+
const serde = await createAdapter();
|
|
127
130
|
const value = new Float64Array(Buffer.from("asd"));
|
|
128
|
-
const deserializedValue =
|
|
131
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
129
132
|
expect(deserializedValue).toBeInstanceOf(Float64Array);
|
|
130
133
|
expect(Buffer.from(deserializedValue).toString("base64")).toEqual(Buffer.from(value).toString("base64"));
|
|
131
134
|
});
|
|
132
135
|
test("Should work with Set", async () => {
|
|
133
|
-
const
|
|
136
|
+
const serde = await createAdapter();
|
|
134
137
|
const value = new Set(["a", "b", "c"]);
|
|
135
|
-
const deserializedValue =
|
|
138
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
136
139
|
expect(deserializedValue).toBeInstanceOf(Set);
|
|
137
140
|
expect(deserializedValue).toEqual(value);
|
|
138
141
|
});
|
|
139
142
|
test("Should work with Set of number, boolean, string, Date, Set, Map, RegExp, Objects, Arrays", async () => {
|
|
140
|
-
const
|
|
143
|
+
const serde = await createAdapter();
|
|
141
144
|
const value = new Set([
|
|
142
145
|
0,
|
|
143
146
|
-1,
|
|
@@ -161,23 +164,23 @@ export function serializerTestSuite(settings) {
|
|
|
161
164
|
[1, 2, 3],
|
|
162
165
|
/test/,
|
|
163
166
|
]);
|
|
164
|
-
const deserializedValue =
|
|
167
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
165
168
|
expect(deserializedValue).toBeInstanceOf(Set);
|
|
166
169
|
expect(deserializedValue).toEqual(value);
|
|
167
170
|
});
|
|
168
171
|
test("Should work with Map", async () => {
|
|
169
|
-
const
|
|
172
|
+
const serde = await createAdapter();
|
|
170
173
|
const value = new Map([
|
|
171
174
|
["a", 1],
|
|
172
175
|
["b", 2],
|
|
173
176
|
["c", 3],
|
|
174
177
|
]);
|
|
175
|
-
const deserializedValue =
|
|
178
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
176
179
|
expect(deserializedValue).toBeInstanceOf(Map);
|
|
177
180
|
expect(deserializedValue).toEqual(value);
|
|
178
181
|
});
|
|
179
182
|
test("Should work with Map of number, boolean, string, Date, Set, Map, RegExp, Objects, Arrays values", async () => {
|
|
180
|
-
const
|
|
183
|
+
const serde = await createAdapter();
|
|
181
184
|
const value = new Map([
|
|
182
185
|
["a", 0],
|
|
183
186
|
["b", -1],
|
|
@@ -204,12 +207,12 @@ export function serializerTestSuite(settings) {
|
|
|
204
207
|
[1, { a: 2, b: -1 }],
|
|
205
208
|
[2, [1, 2, 3]],
|
|
206
209
|
]);
|
|
207
|
-
const deserializedValue =
|
|
210
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
208
211
|
expect(deserializedValue).toBeInstanceOf(Map);
|
|
209
212
|
expect(deserializedValue).toEqual(value);
|
|
210
213
|
});
|
|
211
214
|
test("Should work with Map of number, boolean, string, Date, Set, Map, RegExp, Objects, Arrays keys", async () => {
|
|
212
|
-
const
|
|
215
|
+
const serde = await createAdapter();
|
|
213
216
|
const value = new Map([
|
|
214
217
|
[0, "a"],
|
|
215
218
|
[-1, "a"],
|
|
@@ -236,12 +239,12 @@ export function serializerTestSuite(settings) {
|
|
|
236
239
|
[{ a: 2, b: -1 }, 1],
|
|
237
240
|
[[1, 2, 3], 2],
|
|
238
241
|
]);
|
|
239
|
-
const deserializedValue =
|
|
242
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
240
243
|
expect(deserializedValue).toBeInstanceOf(Map);
|
|
241
244
|
expect(deserializedValue).toEqual(value);
|
|
242
245
|
});
|
|
243
246
|
test("Should work with array of number, boolean, string, Date, Set, Map, RegExp", async () => {
|
|
244
|
-
const
|
|
247
|
+
const serde = await createAdapter();
|
|
245
248
|
const value = [
|
|
246
249
|
0,
|
|
247
250
|
-1,
|
|
@@ -263,11 +266,11 @@ export function serializerTestSuite(settings) {
|
|
|
263
266
|
]),
|
|
264
267
|
/test/,
|
|
265
268
|
];
|
|
266
|
-
const deserializedValue =
|
|
269
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
267
270
|
expect(deserializedValue).toEqual(value);
|
|
268
271
|
});
|
|
269
272
|
test("Should work with array of objects", async () => {
|
|
270
|
-
const
|
|
273
|
+
const serde = await createAdapter();
|
|
271
274
|
const value = [
|
|
272
275
|
Object.fromEntries([
|
|
273
276
|
["a", 0],
|
|
@@ -294,11 +297,11 @@ export function serializerTestSuite(settings) {
|
|
|
294
297
|
["a", /test/],
|
|
295
298
|
]),
|
|
296
299
|
];
|
|
297
|
-
const deserializedValue =
|
|
300
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
298
301
|
expect(deserializedValue).toEqual(value);
|
|
299
302
|
});
|
|
300
303
|
test("Should work with object of number, boolean, string, Date, Set, Map, RegExp", async () => {
|
|
301
|
-
const
|
|
304
|
+
const serde = await createAdapter();
|
|
302
305
|
const value = Object.fromEntries([
|
|
303
306
|
["a", 0],
|
|
304
307
|
["b", -1],
|
|
@@ -323,11 +326,11 @@ export function serializerTestSuite(settings) {
|
|
|
323
326
|
],
|
|
324
327
|
["a", /test/],
|
|
325
328
|
]);
|
|
326
|
-
const deserializedValue =
|
|
329
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
327
330
|
expect(deserializedValue).toEqual(value);
|
|
328
331
|
});
|
|
329
332
|
test("Should work with object of arrays", async () => {
|
|
330
|
-
const
|
|
333
|
+
const serde = await createAdapter();
|
|
331
334
|
const value = {
|
|
332
335
|
a: [
|
|
333
336
|
0,
|
|
@@ -351,8 +354,8 @@ export function serializerTestSuite(settings) {
|
|
|
351
354
|
/test/,
|
|
352
355
|
],
|
|
353
356
|
};
|
|
354
|
-
const deserializedValue =
|
|
357
|
+
const deserializedValue = serde.deserialize(serde.serialize(value));
|
|
355
358
|
expect(deserializedValue).toEqual(value);
|
|
356
359
|
});
|
|
357
360
|
}
|
|
358
|
-
//# sourceMappingURL=
|
|
361
|
+
//# sourceMappingURL=serde.test-suite.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"serde.test-suite.js","sourceRoot":"","sources":["../../../../../../src/serde/implementations/_shared/test-utilities/serde.test-suite.ts"],"names":[],"mappings":";;AAmBA,wCAyYC;AAzYD,SAAgB,cAAc,CAAC,QAA4B;IACvD,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,aAAa,EAAE,GAAG,QAAQ,CAAC;IACjD,IAAI,CAAC,mCAAmC,EAAE,KAAK,IAAI,EAAE;QACjD,MAAM,KAAK,GAAG,MAAM,aAAa,EAAE,CAAC;QACpC,MAAM,KAAK,GAAG,CAAC,CAAC;QAChB,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,KAAK,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAClE,CAAC,CAAC,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AAC,CAAC;QACpE,MAAM,CAAC,iBAAiB,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC7C,CAAC,CAAC,CAAC;IACH,IAAI,CAAC,mCAAmC,EAAE,KAAK,IAAI,EAAE;QACjD,MAAM,KAAK,GAAG,MAAM,aAAa,EAAE,CAAC;QACpC,MAAM,KAAK,GAAG;YACV,CAAC,EAAE;gBACC,CAAC;gBACD,CAAC,CAAC;gBACF,CAAC;gBACD,CAAC,GAAG;gBACJ,GAAG;gBACH,GAAG;gBACH,QAAQ;gBACR,EAAE;gBACF,IAAI;gBACJ,KAAK;gBACL,KAAK;gBACL,IAAI,IAAI,CAAC,YAAY,CAAC;gBACtB,IAAI,GAAG,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC;gBACxB,IAAI,GAAG,CAAC;oBACJ,CAAC,GAAG,EAAE,CAAC,CAAC;oBACR,CAAC,GAAG,EAAE,CAAC,CAAC;oBACR,CAAC,GAAG,EAAE,CAAC,CAAC;iBACX,CAAC;gBACF,MAAM;aACT;SACJ,CAAC;QACF,MAAM,iBAAiB,GAAG,KAAK,CAAC,WAAW,CAAC,KAAK,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;QACpE,MAAM,CAAC,iBAAiB,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC7C,CAAC,CAAC,CAAC;AACP,CAAC"}
|
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("
|
|
17
|
+
__exportStar(require("../../../serde/implementations/mongodb-serde/mongodb-serde"), exports);
|
|
18
18
|
//# sourceMappingURL=_module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"_module.js","sourceRoot":"","sources":["../../../../../src/serde/implementations/mongodb-serde/_module.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,sFAAoE"}
|