@tstdl/base 0.81.35 → 0.82.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api/client/client.d.ts +3 -3
- package/api/default-error-handlers.d.ts +1 -1
- package/api/response.d.ts +8 -8
- package/api/server/api-controller.d.ts +1 -1
- package/api/server/gateway.d.ts +9 -9
- package/api/server/middlewares/cors.middleware.d.ts +1 -1
- package/api/server/module.d.ts +1 -1
- package/api/types.d.ts +30 -30
- package/api/utils.d.ts +1 -1
- package/api/utils.js +3 -1
- package/api/utils.js.map +1 -1
- package/authentication/authentication-credentials.service.d.ts +6 -0
- package/authentication/authentication-credentials.service.js +17 -0
- package/authentication/authentication-credentials.service.js.map +1 -0
- package/authentication/authentication-session.repository.d.ts +6 -0
- package/authentication/authentication-session.repository.js +18 -0
- package/authentication/authentication-session.repository.js.map +1 -0
- package/authentication/authentication-token-payload.provider.d.ts +3 -0
- package/authentication/authentication-token-payload.provider.js +17 -0
- package/authentication/authentication-token-payload.provider.js.map +1 -0
- package/authentication/authentication.service.d.ts +42 -0
- package/authentication/authentication.service.js +133 -0
- package/authentication/authentication.service.js.map +1 -0
- package/authentication/models/authentication-credentials.model.d.ts +11 -0
- package/authentication/models/authentication-credentials.model.js +44 -0
- package/authentication/models/authentication-credentials.model.js.map +1 -0
- package/authentication/models/authentication-session.model.d.ts +14 -0
- package/authentication/models/authentication-session.model.js +59 -0
- package/authentication/models/authentication-session.model.js.map +1 -0
- package/authentication/models/index.d.ts +2 -0
- package/authentication/models/index.js +19 -0
- package/authentication/models/index.js.map +1 -0
- package/authentication/tokens.d.ts +2 -0
- package/authentication/tokens.js +6 -0
- package/authentication/tokens.js.map +1 -0
- package/collections/keyed-set.d.ts +1 -1
- package/collections/observable/observable-collection.d.ts +1 -1
- package/collections/observable/observable-list.d.ts +2 -2
- package/container/container.d.ts +3 -3
- package/container/container.js +3 -3
- package/container/container.js.map +1 -1
- package/container/decorators.d.ts +3 -3
- package/container/decorators.js +0 -1
- package/container/decorators.js.map +1 -1
- package/container/interfaces.d.ts +1 -1
- package/container/provider.d.ts +6 -6
- package/container/resolve-chain.d.ts +2 -2
- package/container/resolve-chain.js +1 -1
- package/container/resolve-chain.js.map +1 -1
- package/container/token.d.ts +3 -3
- package/container/type-info.d.ts +1 -1
- package/container/types.d.ts +4 -4
- package/core.d.ts +1 -1
- package/data-structures/linked-list.d.ts +1 -1
- package/data-structures/multi-key-map.d.ts +2 -2
- package/data-structures/sorted-array-list.d.ts +1 -1
- package/database/entity-repository.d.ts +2 -2
- package/database/entity.d.ts +3 -3
- package/database/module.d.ts +1 -1
- package/database/mongo/classes.d.ts +3 -3
- package/database/mongo/model/document.d.ts +3 -3
- package/database/mongo/module.d.ts +1 -1
- package/database/mongo/mongo-base.repository.d.ts +11 -11
- package/database/mongo/mongo-bulk.d.ts +1 -1
- package/database/mongo/mongo-entity-repository.d.ts +7 -7
- package/database/mongo/types.d.ts +16 -16
- package/database/query.d.ts +38 -38
- package/disposable/async-disposer.d.ts +3 -3
- package/distributed-loop/distributed-loop.d.ts +2 -2
- package/error/custom.error.d.ts +1 -1
- package/http/client/adapters/undici-http-client.adapter.d.ts +1 -1
- package/http/client/http-client-request.d.ts +5 -5
- package/http/client/http-client-response.d.ts +2 -2
- package/http/client/http-client.d.ts +5 -5
- package/http/http-body.d.ts +3 -1
- package/http/http-body.js +18 -12
- package/http/http-body.js.map +1 -1
- package/http/http-form.d.ts +2 -2
- package/http/http-headers.d.ts +3 -3
- package/http/http-query.d.ts +2 -2
- package/http/http-url-parameters.d.ts +2 -2
- package/http/http-value-map.d.ts +1 -1
- package/http/server/http-server-request.d.ts +1 -1
- package/http/server/http-server-response.d.ts +1 -1
- package/http/server/http-server.d.ts +1 -1
- package/http/server/node/node-http-server.d.ts +1 -1
- package/http/types.d.ts +5 -5
- package/http/utils.d.ts +3 -3
- package/image-service/imgproxy/imgproxy-image-service.d.ts +1 -1
- package/json-path/json-path.d.ts +4 -4
- package/key-value-store/key-value.store.d.ts +1 -1
- package/key-value-store/mongo/module.d.ts +1 -1
- package/key-value-store/mongo/mongo-key-value.model.d.ts +1 -1
- package/lock/lock.d.ts +4 -4
- package/lock/mongo/model.d.ts +1 -1
- package/lock/mongo/module.d.ts +1 -1
- package/lock/provider.d.ts +1 -1
- package/logger/logger.d.ts +6 -6
- package/mail/mail.client.d.ts +1 -1
- package/mail/mail.service.d.ts +3 -1
- package/mail/mail.service.js +11 -6
- package/mail/mail.service.js.map +1 -1
- package/mail/models/mail-address.model.d.ts +1 -1
- package/mail/models/mail-content.model.d.ts +1 -1
- package/mail/models/mail-data.model.d.ts +2 -1
- package/mail/models/mail-log.model.d.ts +2 -2
- package/mail/models/mail-send-result.model.d.ts +1 -1
- package/mail/models/mail-template.model.d.ts +1 -1
- package/mail/module.d.ts +4 -2
- package/mail/module.js +6 -2
- package/mail/module.js.map +1 -1
- package/mail/repositories/mongo-mail-log.repository.d.ts +2 -2
- package/mail/tokens.d.ts +1 -0
- package/mail/tokens.js +2 -1
- package/mail/tokens.js.map +1 -1
- package/message-bus/local/types.d.ts +1 -1
- package/message-bus/message-bus.d.ts +1 -1
- package/migration/migration-state.d.ts +2 -2
- package/migration/migrator.d.ts +4 -4
- package/migration/mongo/module.d.ts +1 -1
- package/module/module-metric-reporter.d.ts +2 -2
- package/module/module.d.ts +1 -1
- package/module/modules/function.module.d.ts +1 -1
- package/module/modules/web-server.module.d.ts +1 -1
- package/notification/api.d.ts +3 -6
- package/notification/api.js +2 -5
- package/notification/api.js.map +1 -1
- package/notification/models/index.d.ts +2 -0
- package/notification/models/index.js +19 -0
- package/notification/models/index.js.map +1 -0
- package/notification/models/notification-channel-job.model.d.ts +3 -0
- package/notification/models/notification-channel-job.model.js +3 -0
- package/notification/models/notification-channel-job.model.js.map +1 -0
- package/notification/models/notification.model.d.ts +27 -0
- package/notification/{model.js → models/notification.model.js} +28 -16
- package/notification/models/notification.model.js.map +1 -0
- package/notification/module.d.ts +1 -1
- package/notification/notification-channel.service.d.ts +5 -0
- package/notification/notification-channel.service.js +7 -0
- package/notification/notification-channel.service.js.map +1 -0
- package/notification/notification.service.d.ts +8 -0
- package/notification/notification.service.js +40 -0
- package/notification/notification.service.js.map +1 -0
- package/object-storage/object-storage.d.ts +2 -2
- package/object-storage/object.d.ts +1 -1
- package/object-storage/s3/s3.object-storage-provider.d.ts +1 -1
- package/openid-connect/mongo-oidc-state.repository.d.ts +1 -1
- package/openid-connect/oidc-configuration.service.d.ts +1 -1
- package/openid-connect/oidc-state.model.d.ts +2 -2
- package/openid-connect/oidc.service-model.d.ts +8 -8
- package/orm/decorators.d.ts +26 -0
- package/orm/decorators.js +170 -0
- package/orm/decorators.js.map +1 -1
- package/orm/entity-definition.model.d.ts +51 -0
- package/orm/entity-definition.model.js +27 -0
- package/orm/entity-definition.model.js.map +1 -0
- package/orm/index.d.ts +1 -0
- package/orm/index.js +18 -0
- package/orm/index.js.map +1 -0
- package/orm/models/entity.d.ts +22 -0
- package/orm/models/entity.js +87 -0
- package/orm/models/entity.js.map +1 -0
- package/orm/models/index.d.ts +1 -0
- package/orm/models/index.js +18 -0
- package/orm/models/index.js.map +1 -0
- package/orm/repository/mongo/classes.d.ts +25 -0
- package/orm/repository/mongo/classes.js +33 -0
- package/orm/repository/mongo/classes.js.map +1 -0
- package/orm/repository/mongo/module.d.ts +8 -0
- package/orm/repository/mongo/module.js +88 -0
- package/orm/repository/mongo/module.js.map +1 -0
- package/orm/repository/mongo/mongo-repository.d.ts +11 -0
- package/orm/repository/mongo/mongo-repository.js +55 -0
- package/orm/repository/mongo/mongo-repository.js.map +1 -0
- package/orm/repository/mongo/mongo-transaction.d.ts +10 -0
- package/orm/repository/mongo/mongo-transaction.js +28 -0
- package/orm/repository/mongo/mongo-transaction.js.map +1 -0
- package/orm/repository/repository.d.ts +75 -0
- package/orm/repository/repository.js +182 -0
- package/orm/repository/repository.js.map +1 -0
- package/orm/repository/transaction.d.ts +26 -0
- package/orm/repository/transaction.js +65 -0
- package/orm/repository/transaction.js.map +1 -0
- package/orm/{types.d.ts → types/definition.d.ts} +5 -5
- package/orm/{types.js → types/definition.js} +8 -8
- package/orm/types/definition.js.map +1 -0
- package/orm/types/index.d.ts +3 -0
- package/orm/types/index.js +20 -0
- package/orm/types/index.js.map +1 -0
- package/orm/types/options.d.ts +36 -0
- package/orm/types/options.js +5 -0
- package/orm/types/options.js.map +1 -0
- package/orm/types/query.d.ts +110 -0
- package/orm/types/query.js +10 -0
- package/orm/types/query.js.map +1 -0
- package/package.json +5 -5
- package/pdf/pdf.service.d.ts +3 -3
- package/pool/pool.d.ts +4 -4
- package/promise/cancelable-promise.d.ts +1 -1
- package/promise/lazy-promise.d.ts +1 -1
- package/queue/mongo/job.d.ts +2 -2
- package/queue/mongo/queue.js +2 -2
- package/queue/mongo/queue.js.map +1 -1
- package/queue/queue.d.ts +11 -6
- package/queue/queue.js +2 -1
- package/queue/queue.js.map +1 -1
- package/reflection/decorator-data.js +2 -1
- package/reflection/decorator-data.js.map +1 -1
- package/reflection/registry.d.ts +18 -17
- package/reflection/registry.js +25 -10
- package/reflection/registry.js.map +1 -1
- package/reflection/types.d.ts +34 -34
- package/reflection/utils.d.ts +8 -8
- package/reflection/utils.js +6 -6
- package/reflection/utils.js.map +1 -1
- package/rpc/endpoints/message-port.rpc-endpoint.d.ts +3 -3
- package/rpc/model.d.ts +22 -22
- package/rpc/rpc.d.ts +1 -1
- package/rxjs/intersection-observer.d.ts +1 -1
- package/rxjs/mutation-observer.d.ts +1 -1
- package/rxjs/performance-observer.d.ts +1 -1
- package/rxjs/resize-observer.d.ts +1 -1
- package/rxjs/slow-array.d.ts +1 -1
- package/rxjs/touch.d.ts +1 -1
- package/schema/array-constraints/maximum-length.d.ts +2 -2
- package/schema/array-constraints/maximum-length.js +2 -2
- package/schema/array-constraints/maximum-length.js.map +1 -1
- package/schema/array-constraints/minimum-length.d.ts +2 -2
- package/schema/array-constraints/minimum-length.js +2 -2
- package/schema/array-constraints/minimum-length.js.map +1 -1
- package/schema/constraints/enumeration.d.ts +4 -4
- package/schema/constraints/enumeration.js +5 -5
- package/schema/constraints/enumeration.js.map +1 -1
- package/schema/constraints/generic.d.ts +4 -4
- package/schema/constraints/generic.js +2 -2
- package/schema/constraints/generic.js.map +1 -1
- package/schema/constraints/integer.d.ts +2 -2
- package/schema/constraints/integer.js +3 -2
- package/schema/constraints/integer.js.map +1 -1
- package/schema/constraints/length.d.ts +1 -1
- package/schema/constraints/literal.d.ts +2 -2
- package/schema/constraints/literal.js +2 -2
- package/schema/constraints/literal.js.map +1 -1
- package/schema/constraints/maximum-date.d.ts +2 -2
- package/schema/constraints/maximum-date.js +3 -2
- package/schema/constraints/maximum-date.js.map +1 -1
- package/schema/constraints/maximum-length.d.ts +2 -2
- package/schema/constraints/maximum-length.js +2 -2
- package/schema/constraints/maximum-length.js.map +1 -1
- package/schema/constraints/maximum.d.ts +2 -2
- package/schema/constraints/maximum.js +3 -2
- package/schema/constraints/maximum.js.map +1 -1
- package/schema/constraints/minimum-date.d.ts +2 -2
- package/schema/constraints/minimum-date.js +3 -2
- package/schema/constraints/minimum-date.js.map +1 -1
- package/schema/constraints/minimum-length.d.ts +2 -2
- package/schema/constraints/minimum-length.js +2 -2
- package/schema/constraints/minimum-length.js.map +1 -1
- package/schema/constraints/minimum.d.ts +2 -2
- package/schema/constraints/minimum.js +3 -2
- package/schema/constraints/minimum.js.map +1 -1
- package/schema/constraints/pattern.d.ts +2 -2
- package/schema/constraints/pattern.js +3 -2
- package/schema/constraints/pattern.js.map +1 -1
- package/schema/decorators/types.d.ts +3 -3
- package/schema/decorators/utils.d.ts +4 -1
- package/schema/decorators/utils.js +1 -1
- package/schema/decorators/utils.js.map +1 -1
- package/schema/schema.d.ts +4 -4
- package/schema/schema.error.d.ts +1 -1
- package/schema/schema.js +10 -13
- package/schema/schema.js.map +1 -1
- package/schema/schemas/any.d.ts +1 -1
- package/schema/schemas/array.d.ts +2 -2
- package/schema/schemas/array.js +2 -2
- package/schema/schemas/array.js.map +1 -1
- package/schema/schemas/boolean.d.ts +1 -1
- package/schema/schemas/date.d.ts +2 -2
- package/schema/schemas/date.js +2 -2
- package/schema/schemas/date.js.map +1 -1
- package/schema/schemas/enumeration.d.ts +2 -2
- package/schema/schemas/enumeration.js +2 -2
- package/schema/schemas/enumeration.js.map +1 -1
- package/schema/schemas/instance.d.ts +1 -1
- package/schema/schemas/literal.d.ts +2 -2
- package/schema/schemas/literal.js +2 -2
- package/schema/schemas/literal.js.map +1 -1
- package/schema/schemas/nullable.d.ts +1 -1
- package/schema/schemas/number.d.ts +2 -2
- package/schema/schemas/number.js +2 -2
- package/schema/schemas/number.js.map +1 -1
- package/schema/schemas/object.d.ts +1 -1
- package/schema/schemas/omit.d.ts +2 -2
- package/schema/schemas/omit.js.map +1 -1
- package/schema/schemas/one-or-many.d.ts +2 -2
- package/schema/schemas/optional.d.ts +1 -1
- package/schema/schemas/readable-stream.d.ts +1 -1
- package/schema/schemas/record.d.ts +1 -1
- package/schema/schemas/regexp.d.ts +1 -1
- package/schema/schemas/string.d.ts +2 -2
- package/schema/schemas/string.js +3 -3
- package/schema/schemas/string.js.map +1 -1
- package/schema/schemas/uint8-array.d.ts +2 -2
- package/schema/schemas/uint8-array.js +3 -3
- package/schema/schemas/uint8-array.js.map +1 -1
- package/schema/schemas/union.d.ts +1 -1
- package/schema/schemas/unknown.d.ts +1 -1
- package/schema/transformers/generic.d.ts +1 -1
- package/schema/types/index.d.ts +5 -0
- package/schema/types/index.js +22 -0
- package/schema/types/index.js.map +1 -0
- package/schema/types/schema-array-constraint.d.ts +5 -0
- package/schema/types/schema-array-constraint.js +7 -0
- package/schema/types/schema-array-constraint.js.map +1 -0
- package/schema/types/schema-value-coercer.d.ts +8 -0
- package/schema/types/schema-value-coercer.js +7 -0
- package/schema/types/schema-value-coercer.js.map +1 -0
- package/schema/types/schema-value-constraint.d.ts +8 -0
- package/schema/types/schema-value-constraint.js +7 -0
- package/schema/types/schema-value-constraint.js.map +1 -0
- package/schema/types/schema-value-transformer.d.ts +7 -0
- package/schema/types/schema-value-transformer.js +7 -0
- package/schema/types/schema-value-transformer.js.map +1 -0
- package/schema/{types.d.ts → types/types.d.ts} +47 -57
- package/schema/types/types.js +174 -0
- package/schema/types/types.js.map +1 -0
- package/schema/utils/schema.js +1 -1
- package/schema/utils/schema.js.map +1 -1
- package/schema/utils/value-type.d.ts +1 -1
- package/schema/utils/value-type.js +1 -1
- package/schema/utils/value-type.js.map +1 -1
- package/search-index/elastic/config.d.ts +1 -1
- package/search-index/elastic/model/elastic-query.d.ts +15 -15
- package/search-index/elastic/model/index-mapping.d.ts +14 -14
- package/search-index/elastic/model/sort.d.ts +3 -3
- package/search-index/elastic/module.d.ts +1 -1
- package/search-index/search-index.d.ts +1 -1
- package/search-index/search-result.d.ts +2 -2
- package/serializer/handlers/error.d.ts +1 -1
- package/serializer/handlers/map.d.ts +1 -1
- package/serializer/handlers/regex.d.ts +1 -1
- package/serializer/handlers/set.d.ts +1 -1
- package/serializer/serializable.d.ts +6 -6
- package/serializer/serializer.d.ts +1 -1
- package/serializer/types.d.ts +15 -15
- package/sse/server-sent-events.d.ts +3 -3
- package/tailwind/theme-adapter.d.ts +1 -1
- package/templates/module.d.ts +1 -1
- package/templates/providers/file.provider-template.d.ts +2 -2
- package/templates/providers/file.provider-template.js +2 -1
- package/templates/providers/file.provider-template.js.map +1 -1
- package/templates/renderers/handlebars.template-renderer.d.ts +9 -9
- package/templates/renderers/mjml.template-renderer.d.ts +3 -3
- package/templates/renderers/string.template-renderer.d.ts +1 -1
- package/templates/resolvers/file.template-resolver.d.ts +2 -2
- package/templates/template.model.d.ts +1 -1
- package/templates/template.renderer.d.ts +4 -4
- package/templates/template.service.d.ts +1 -1
- package/text/dynamic-text.model.d.ts +1 -1
- package/text/localizable-text.model.d.ts +1 -1
- package/text/localization.service.d.ts +11 -11
- package/theme/theme-service.d.ts +6 -6
- package/threading/thread-pool.d.ts +1 -1
- package/threading/thread-worker.d.ts +1 -1
- package/types/geo-json.d.ts +12 -12
- package/types.d.ts +91 -91
- package/utils/any-iterable-iterator.d.ts +3 -3
- package/utils/array/array.d.ts +14 -1
- package/utils/array/array.js +16 -2
- package/utils/array/array.js.map +1 -1
- package/utils/async-iterable-helpers/parallel/types.d.ts +2 -2
- package/utils/async-iterable-helpers/types.d.ts +7 -7
- package/utils/backoff.d.ts +5 -5
- package/utils/benchmark.d.ts +1 -1
- package/utils/binary-search.d.ts +1 -1
- package/utils/binary.js.map +1 -1
- package/utils/cancellation-token.d.ts +1 -1
- package/utils/compression.d.ts +1 -1
- package/utils/cryptography.d.ts +11 -11
- package/utils/date-time.d.ts +8 -7
- package/utils/date-time.js +6 -2
- package/utils/date-time.js.map +1 -1
- package/utils/equals.d.ts +3 -3
- package/utils/factory-map.d.ts +1 -1
- package/utils/format-error.d.ts +1 -1
- package/utils/function/memoize.d.ts +1 -1
- package/utils/helpers.d.ts +1 -1
- package/utils/iterable-helpers/types.d.ts +6 -6
- package/utils/jwt.d.ts +4 -4
- package/utils/math.d.ts +1 -1
- package/utils/merge.d.ts +1 -1
- package/utils/middleware.d.ts +9 -9
- package/utils/moving-metric.d.ts +1 -1
- package/utils/object/decycle.d.ts +1 -1
- package/utils/object/dereference.d.ts +1 -1
- package/utils/object/forward-ref.d.ts +2 -2
- package/utils/object/lazy-property.d.ts +5 -5
- package/utils/object/merge.d.ts +1 -1
- package/utils/object/object.js +1 -2
- package/utils/object/object.js.map +1 -1
- package/utils/object/property-name.d.ts +5 -5
- package/utils/patch-worker.d.ts +1 -1
- package/utils/periodic-sampler.d.ts +1 -1
- package/utils/provider-function-iterable.d.ts +2 -2
- package/utils/proxy.d.ts +1 -1
- package/utils/singleton.d.ts +2 -2
- package/utils/sort.d.ts +2 -2
- package/utils/stream/stream-helper-types.d.ts +5 -5
- package/utils/type-guards.d.ts +3 -3
- package/utils/url-builder.d.ts +4 -4
- package/web-types.d.ts +4 -4
- package/notification/model.d.ts +0 -18
- package/notification/model.js.map +0 -1
- package/orm/mongo/mongo-repository.d.ts +0 -2
- package/orm/mongo/mongo-repository.js +0 -7
- package/orm/mongo/mongo-repository.js.map +0 -1
- package/orm/types.js.map +0 -1
- package/schema/types.js +0 -102
- package/schema/types.js.map +0 -1
package/rpc/model.d.ts
CHANGED
|
@@ -1,67 +1,67 @@
|
|
|
1
1
|
import type { SerializationOptions } from "../serializer";
|
|
2
2
|
import type { Constructor, Record } from "../types";
|
|
3
|
-
export
|
|
4
|
-
export
|
|
5
|
-
export
|
|
3
|
+
export type RpcConstructor<T extends Constructor> = T extends Constructor<any, infer R> ? Constructor<Promise<RpcRemote<InstanceType<T>>>, R> : never;
|
|
4
|
+
export type RpcFunction<T extends (...args: any) => any> = T extends (...args: infer Args) => infer R ? (...args: Args) => Promise<Awaited<R>> : never;
|
|
5
|
+
export type RpcObject<T extends Record> = {
|
|
6
6
|
[P in keyof T]: T[P] extends (...args: any) => any ? RpcFunction<T[P]> : Promise<Awaited<T[P]>>;
|
|
7
7
|
};
|
|
8
|
-
export
|
|
9
|
-
export
|
|
10
|
-
export
|
|
8
|
+
export type RpcRemoteInput = ((...args: any) => any) | Record;
|
|
9
|
+
export type RpcRemote<T extends RpcRemoteInput = RpcRemoteInput> = T extends Constructor ? RpcConstructor<T> : T extends (...args: any) => any ? RpcFunction<T> : RpcObject<T>;
|
|
10
|
+
export type RpcMessageBase<Type extends string = string> = {
|
|
11
11
|
type: Type;
|
|
12
12
|
id: string;
|
|
13
13
|
metadata?: any;
|
|
14
14
|
};
|
|
15
|
-
export
|
|
15
|
+
export type RpcMessageWithProxyIdBase<Type extends string = string> = RpcMessageBase<Type> & {
|
|
16
16
|
proxyId: string;
|
|
17
17
|
};
|
|
18
|
-
export
|
|
18
|
+
export type RpcConnectMessage = RpcMessageBase<'connect'> & {
|
|
19
19
|
name: string;
|
|
20
20
|
};
|
|
21
|
-
export
|
|
21
|
+
export type RpcApplyMessage = RpcMessageWithProxyIdBase<'apply'> & {
|
|
22
22
|
path: PropertyKey[];
|
|
23
23
|
args: RpcMessageValue[];
|
|
24
24
|
};
|
|
25
|
-
export
|
|
25
|
+
export type RpcConstructMessage = RpcMessageWithProxyIdBase<'construct'> & {
|
|
26
26
|
path: PropertyKey[];
|
|
27
27
|
args: RpcMessageValue[];
|
|
28
28
|
};
|
|
29
|
-
export
|
|
29
|
+
export type RpcGetMessage = RpcMessageWithProxyIdBase<'get'> & {
|
|
30
30
|
path: PropertyKey[];
|
|
31
31
|
};
|
|
32
|
-
export
|
|
32
|
+
export type RpcSetMessage = RpcMessageWithProxyIdBase<'set'> & {
|
|
33
33
|
path: PropertyKey[];
|
|
34
34
|
value: RpcMessageValue;
|
|
35
35
|
};
|
|
36
|
-
export
|
|
37
|
-
export
|
|
36
|
+
export type RpcReleaseProxyMessage = RpcMessageWithProxyIdBase<'release-proxy'>;
|
|
37
|
+
export type RpcResponseMessage = RpcMessageBase<'response'> & {
|
|
38
38
|
value: RpcMessageValue;
|
|
39
39
|
};
|
|
40
|
-
export
|
|
41
|
-
export
|
|
40
|
+
export type RpcMessage = RpcConnectMessage | RpcApplyMessage | RpcConstructMessage | RpcGetMessage | RpcSetMessage | RpcReleaseProxyMessage | RpcResponseMessage;
|
|
41
|
+
export type RpcMessageRawValue = {
|
|
42
42
|
type: 'raw';
|
|
43
43
|
value: any;
|
|
44
44
|
};
|
|
45
|
-
export
|
|
45
|
+
export type RpcMessageSerializedValue = {
|
|
46
46
|
type: 'serialized';
|
|
47
47
|
value: any;
|
|
48
48
|
options?: SerializationOptions;
|
|
49
49
|
};
|
|
50
|
-
export
|
|
50
|
+
export type RpcMessageProxyValue = {
|
|
51
51
|
type: 'proxy';
|
|
52
52
|
id: string;
|
|
53
53
|
port?: MessagePort;
|
|
54
54
|
};
|
|
55
|
-
export
|
|
55
|
+
export type RpcMessageThrowValue = {
|
|
56
56
|
type: 'throw';
|
|
57
57
|
error: unknown;
|
|
58
58
|
};
|
|
59
|
-
export
|
|
60
|
-
export
|
|
59
|
+
export type RpcMessageValue = RpcMessageRawValue | RpcMessageSerializedValue | RpcMessageProxyValue | RpcMessageThrowValue;
|
|
60
|
+
export type RpcPostMessageArrayData = {
|
|
61
61
|
value: RpcMessageValue[];
|
|
62
62
|
transfer?: any[];
|
|
63
63
|
};
|
|
64
|
-
export
|
|
64
|
+
export type RpcPostMessageData = {
|
|
65
65
|
value: RpcMessageValue;
|
|
66
66
|
transfer?: any[];
|
|
67
67
|
};
|
package/rpc/rpc.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { SerializationOptions } from "../serializer";
|
|
|
2
2
|
import type { MessagePortRpcEndpointSource } from './endpoints/message-port.rpc-endpoint';
|
|
3
3
|
import type { RpcRemote, RpcRemoteInput } from './model';
|
|
4
4
|
import { RpcEndpoint } from './rpc-endpoint';
|
|
5
|
-
export
|
|
5
|
+
export type RpcEndpointSource = RpcEndpoint | MessagePortRpcEndpointSource;
|
|
6
6
|
export declare const Rpc: {
|
|
7
7
|
connect<T extends RpcRemoteInput>(endpointOrSource: RpcEndpointSource, name?: string): Promise<RpcRemote<T>>;
|
|
8
8
|
expose(object: RpcRemoteInput, endpointOrSource: RpcEndpointSource, name?: string): void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
|
-
export
|
|
2
|
+
export type ObserveIntersectionOptions = IntersectionObserverInit & {
|
|
3
3
|
takeRecordsTrigger?: Observable<any>;
|
|
4
4
|
observeTrigger?: Observable<Element>;
|
|
5
5
|
unobserveTrigger?: Observable<Element>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Observable } from 'rxjs';
|
|
2
|
-
export
|
|
2
|
+
export type ObserveMutationOptions = MutationObserverInit & {
|
|
3
3
|
takeRecordsTrigger?: Observable<any>;
|
|
4
4
|
observeTrigger?: Observable<Node | [Node, MutationObserverInit?]>;
|
|
5
5
|
};
|
package/rxjs/slow-array.d.ts
CHANGED
package/rxjs/touch.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Observable } from 'rxjs';
|
|
2
2
|
import type { EventListenerOptions } from 'rxjs/internal/observable/fromEvent';
|
|
3
|
-
export
|
|
3
|
+
export type TouchEvents = {
|
|
4
4
|
start: TouchEvent | undefined;
|
|
5
5
|
move: TouchEvent | undefined;
|
|
6
6
|
end: TouchEvent | undefined;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaArrayConstraint } from '../types/schema-array-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class ArrayMaximumLengthConstraint extends SchemaArrayConstraint {
|
|
6
6
|
private readonly maximumLength;
|
|
7
7
|
readonly expects: string;
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.ArrayMaximumLength = exports.ArrayMaximumLengthConstraint = void 0;
|
|
5
5
|
const decorators_1 = require("../decorators");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
8
|
-
class ArrayMaximumLengthConstraint extends
|
|
7
|
+
const schema_array_constraint_1 = require("../types/schema-array-constraint");
|
|
8
|
+
class ArrayMaximumLengthConstraint extends schema_array_constraint_1.SchemaArrayConstraint {
|
|
9
9
|
maximumLength;
|
|
10
10
|
expects;
|
|
11
11
|
constructor(maximumLength) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"maximum-length.js","sourceRoot":"","sources":["../../../source/schema/array-constraints/maximum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,8CAAqE;AACrE,kDAA8C;
|
|
1
|
+
{"version":3,"file":"maximum-length.js","sourceRoot":"","sources":["../../../source/schema/array-constraints/maximum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,8CAAqE;AACrE,kDAA8C;AAC9C,8EAAyE;AAGzE,MAAa,4BAA6B,SAAQ,+CAAqB;IACpD,aAAa,CAAS;IAE9B,OAAO,CAAS;IAEzB,YAAY,aAAqB;QAC/B,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,CAAC,OAAO,GAAG,6BAA6B,IAAI,CAAC,aAAa,EAAE,CAAC;IACnE,CAAC;IAED,QAAQ,CAAC,KAAY,EAAE,IAAc,EAAE,OAA0B;QAC/D,IAAI,KAAK,CAAC,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE;YACrC,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,sBAAsB,KAAK,CAAC,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SAC5J;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAnBD,oEAmBC;AAED,SAAgB,kBAAkB,CAAC,aAAqB;IACtD,OAAO,IAAA,iDAAoC,EAAC,IAAI,4BAA4B,CAAC,aAAa,CAAC,CAAC,CAAC;AAC/F,CAAC;AAFD,gDAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaArrayConstraint } from '../types/schema-array-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MinimumArrayLengthConstraint extends SchemaArrayConstraint {
|
|
6
6
|
private readonly minimumLength;
|
|
7
7
|
readonly expects: string;
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.MinimumArrayLength = exports.MinimumArrayLengthConstraint = void 0;
|
|
5
5
|
const decorators_1 = require("../decorators");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
8
|
-
class MinimumArrayLengthConstraint extends
|
|
7
|
+
const schema_array_constraint_1 = require("../types/schema-array-constraint");
|
|
8
|
+
class MinimumArrayLengthConstraint extends schema_array_constraint_1.SchemaArrayConstraint {
|
|
9
9
|
minimumLength;
|
|
10
10
|
expects;
|
|
11
11
|
constructor(minimumLength) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"minimum-length.js","sourceRoot":"","sources":["../../../source/schema/array-constraints/minimum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,8CAAqE;AACrE,kDAA8C;
|
|
1
|
+
{"version":3,"file":"minimum-length.js","sourceRoot":"","sources":["../../../source/schema/array-constraints/minimum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,8CAAqE;AACrE,kDAA8C;AAC9C,8EAAyE;AAGzE,MAAa,4BAA6B,SAAQ,+CAAqB;IACpD,aAAa,CAAS;IAE9B,OAAO,CAAS;IAEzB,YAAY,aAAqB;QAC/B,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,CAAC,OAAO,GAAG,6BAA6B,IAAI,CAAC,aAAa,EAAE,CAAC;IACnE,CAAC;IAED,QAAQ,CAAC,KAAY,EAAE,IAAc,EAAE,OAA0B;QAC/D,IAAI,KAAK,CAAC,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE;YACrC,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,sBAAsB,KAAK,CAAC,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SAC5J;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAnBD,oEAmBC;AAED,SAAgB,kBAAkB,CAAC,aAAqB;IACtD,OAAO,IAAA,iDAAoC,EAAC,IAAI,4BAA4B,CAAC,aAAa,CAAC,CAAC,CAAC;AAC/F,CAAC;AAFD,gDAEC"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
|
-
import type { Enumeration, OneOrMany } from "../../types";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
2
|
+
import type { Enumeration, EnumerationValue, OneOrMany } from "../../types";
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class EnumerationConstraint extends SchemaValueConstraint {
|
|
6
|
-
private readonly allowedValuesSet;
|
|
7
6
|
private readonly allowedValuesString;
|
|
8
7
|
readonly enumeration: Enumeration;
|
|
8
|
+
readonly allowedValuesSet: Set<EnumerationValue>;
|
|
9
9
|
readonly suitableTypes: SchemaValueConstraint['suitableTypes'];
|
|
10
10
|
readonly expects: OneOrMany<string>;
|
|
11
11
|
constructor(enumeration: Enumeration);
|
|
@@ -6,12 +6,12 @@ const enum_1 = require("../../utils/enum");
|
|
|
6
6
|
const distinct_1 = require("../../utils/iterable-helpers/distinct");
|
|
7
7
|
const type_guards_1 = require("../../utils/type-guards");
|
|
8
8
|
const schema_error_1 = require("../schema.error");
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
class EnumerationConstraint extends
|
|
12
|
-
allowedValuesSet;
|
|
9
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
10
|
+
const value_type_1 = require("../utils/value-type");
|
|
11
|
+
class EnumerationConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
13
12
|
allowedValuesString;
|
|
14
13
|
enumeration;
|
|
14
|
+
allowedValuesSet;
|
|
15
15
|
suitableTypes;
|
|
16
16
|
expects;
|
|
17
17
|
constructor(enumeration) {
|
|
@@ -20,7 +20,7 @@ class EnumerationConstraint extends types_1.SchemaValueConstraint {
|
|
|
20
20
|
const allowedValues = (0, type_guards_1.isArray)(enumeration) ? enumeration : (0, enum_1.enumValues)(enumeration);
|
|
21
21
|
this.allowedValuesSet = new Set(allowedValues);
|
|
22
22
|
this.allowedValuesString = allowedValues.map((value) => ((0, type_guards_1.isString)(value) ? `"${value}"` : value)).join(', ');
|
|
23
|
-
this.suitableTypes = [...(0, distinct_1.distinct)(allowedValues.map((value) => (0,
|
|
23
|
+
this.suitableTypes = [...(0, distinct_1.distinct)(allowedValues.map((value) => (0, value_type_1.getValueType)(value)))];
|
|
24
24
|
this.expects = `one of [${this.allowedValuesString}]`;
|
|
25
25
|
}
|
|
26
26
|
validate(value, path, context) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"enumeration.js","sourceRoot":"","sources":["../../../source/schema/constraints/enumeration.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,2CAA0C;AAC1C,oEAA6D;AAC7D,yDAAwD;AACxD,kDAA8C;
|
|
1
|
+
{"version":3,"file":"enumeration.js","sourceRoot":"","sources":["../../../source/schema/constraints/enumeration.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,2CAA0C;AAC1C,oEAA6D;AAC7D,yDAAwD;AACxD,kDAA8C;AAC9C,8EAAyE;AAEzE,oDAAmD;AAEnD,MAAa,qBAAsB,SAAQ,+CAAqB;IAC7C,mBAAmB,CAAS;IAEpC,WAAW,CAAc;IACzB,gBAAgB,CAAwB;IACxC,aAAa,CAAyC;IACtD,OAAO,CAAoB;IAEpC,YAAY,WAAwB;QAClC,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QAE/B,MAAM,aAAa,GAAG,IAAA,qBAAO,EAAC,WAAW,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,IAAA,iBAAU,EAAC,WAAW,CAAC,CAAC;QACnF,IAAI,CAAC,gBAAgB,GAAG,IAAI,GAAG,CAAC,aAAa,CAAC,CAAC;QAC/C,IAAI,CAAC,mBAAmB,GAAG,aAAa,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,IAAA,sBAAQ,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,KAAK,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAE7G,IAAI,CAAC,aAAa,GAAG,CAAC,GAAG,IAAA,mBAAQ,EAAC,aAAa,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,IAAA,yBAAY,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;QACtF,IAAI,CAAC,OAAO,GAAG,WAAW,IAAI,CAAC,mBAAmB,GAAG,CAAC;IACxD,CAAC;IAED,QAAQ,CAAC,KAAa,EAAE,IAAc,EAAE,OAA0B;QAChE,IAAI,CAAC,IAAI,CAAC,gBAAgB,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE;YACrC,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SACxI;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AA5BD,sDA4BC"}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { OneOrMany } from "../../types";
|
|
3
3
|
import { SchemaError } from '../schema.error';
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
export
|
|
4
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
5
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
6
|
+
export type GenericConstraintResult = {
|
|
7
7
|
success: true;
|
|
8
8
|
error?: undefined;
|
|
9
9
|
} | {
|
|
10
10
|
success: false;
|
|
11
11
|
error: string | SchemaError;
|
|
12
12
|
};
|
|
13
|
-
export
|
|
13
|
+
export type GenericConstraintFunction<T> = (value: T, path: JsonPath) => boolean | ConstraintResult;
|
|
14
14
|
export declare class GenericConstraint<T> extends SchemaValueConstraint {
|
|
15
15
|
readonly suitableTypes: NumberConstructor;
|
|
16
16
|
readonly expects: OneOrMany<string>;
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.GenericConstraint = void 0;
|
|
5
5
|
const type_guards_1 = require("../../utils/type-guards");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
8
|
-
class GenericConstraint extends
|
|
7
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
8
|
+
class GenericConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
9
9
|
suitableTypes = Number;
|
|
10
10
|
expects;
|
|
11
11
|
constraintFunction;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generic.js","sourceRoot":"","sources":["../../../source/schema/constraints/generic.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAgD;AAChD,kDAA8C;
|
|
1
|
+
{"version":3,"file":"generic.js","sourceRoot":"","sources":["../../../source/schema/constraints/generic.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAgD;AAChD,kDAA8C;AAC9C,8EAAyE;AASzE,MAAa,iBAAqB,SAAQ,+CAAqB;IACpD,aAAa,GAAG,MAAM,CAAC;IACvB,OAAO,CAAoB;IAC3B,kBAAkB,CAA+B;IAE1D,YAAY,kBAAgD,EAAE,UAA6B,aAAa;QACtG,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,kBAAkB,GAAG,kBAAkB,CAAC;QAC7C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;IAED,QAAQ,CAAC,KAAQ,EAAE,IAAc,EAAE,OAA0B;QAC3D,MAAM,MAAM,GAAG,IAAI,CAAC,kBAAkB,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;QAEpD,IAAI,IAAA,uBAAS,EAAC,MAAM,CAAC,EAAE;YACrB,OAAO,MAAM;gBACX,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE;gBACjB,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,eAAe,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SACpI;QAED,OAAO,MAAM,CAAC;IAChB,CAAC;CACF;AAvBD,8CAuBC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class IntegerConstraint extends SchemaValueConstraint {
|
|
6
6
|
readonly suitableTypes: NumberConstructor;
|
|
7
7
|
readonly expects: string;
|
|
@@ -4,8 +4,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.Integer = exports.integerConstraint = exports.IntegerConstraint = void 0;
|
|
5
5
|
const utils_1 = require("../decorators/utils");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
8
|
-
|
|
7
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
8
|
+
const types_1 = require("../types/types");
|
|
9
|
+
class IntegerConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
9
10
|
suitableTypes = Number;
|
|
10
11
|
expects;
|
|
11
12
|
constructor() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"integer.js","sourceRoot":"","sources":["../../../source/schema/constraints/integer.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,+CAA2E;AAC3E,kDAA8C;
|
|
1
|
+
{"version":3,"file":"integer.js","sourceRoot":"","sources":["../../../source/schema/constraints/integer.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,+CAA2E;AAC3E,kDAA8C;AAC9C,8EAAyE;AAEzE,0CAA4C;AAE5C,MAAa,iBAAkB,SAAQ,+CAAqB;IACjD,aAAa,GAAG,MAAM,CAAC;IACvB,OAAO,CAAS;IAEzB;QACE,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,OAAO,GAAG,YAAY,CAAC;IAC9B,CAAC;IAED,QAAQ,CAAC,KAAa,EAAE,IAAc,EAAE,OAA0B;QAChE,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE;YAC5B,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SACxI;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAjBD,8CAiBC;AAEY,QAAA,iBAAiB,GAAG,IAAI,iBAAiB,EAAE,CAAC;AAEzD,SAAgB,OAAO;IACrB,OAAO,IAAA,4CAAoC,EAAC,yBAAiB,EAAE,EAAE,MAAM,EAAE,IAAA,kBAAU,EAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AACjG,CAAC;AAFD,0BAEC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
2
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
3
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
4
4
|
export declare class LiteralConstraint extends SchemaValueConstraint {
|
|
5
5
|
readonly literal: any;
|
|
6
6
|
readonly suitableTypes: SchemaValueConstraint['suitableTypes'];
|
|
@@ -4,9 +4,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.LiteralConstraint = void 0;
|
|
5
5
|
const type_guards_1 = require("../../utils/type-guards");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
7
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
8
8
|
const utils_1 = require("../utils");
|
|
9
|
-
class LiteralConstraint extends
|
|
9
|
+
class LiteralConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
10
10
|
literal;
|
|
11
11
|
suitableTypes;
|
|
12
12
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"literal.js","sourceRoot":"","sources":["../../../source/schema/constraints/literal.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAGzD,yDAAkD;AAClD,kDAA8C;
|
|
1
|
+
{"version":3,"file":"literal.js","sourceRoot":"","sources":["../../../source/schema/constraints/literal.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAGzD,yDAAkD;AAClD,kDAA8C;AAC9C,8EAAyE;AAEzE,oCAA0D;AAE1D,MAAa,iBAAkB,SAAQ,+CAAqB;IACjD,OAAO,CAAM;IACb,aAAa,CAAyC;IACtD,OAAO,CAAS;IAEzB,YAAY,OAAY;QACtB,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QAEvB,IAAI,CAAC,aAAa,GAAG,IAAA,oBAAY,EAAC,OAAO,CAAC,CAAC;QAC3C,MAAM,WAAW,GAAG,IAAA,yBAAW,EAAC,OAAO,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,IAAA,wBAAgB,EAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QAClG,IAAI,CAAC,OAAO,GAAG,WAAW,WAAW,EAAE,CAAC;IAC1C,CAAC;IAED,QAAQ,CAAC,KAAU,EAAE,IAAc,EAAE,OAA0B;QAC7D,IAAI,KAAK,KAAK,IAAI,CAAC,OAAO,EAAE;YAC1B,MAAM,SAAS,GAAG,IAAA,oBAAY,EAAC,KAAK,CAAC,CAAC;YACtC,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,IAAA,wBAAgB,EAAC,SAAS,CAAC,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SACnJ;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAvBD,8CAuBC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MaximumDateConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly maximum;
|
|
7
7
|
readonly suitableTypes: NumberConstructor;
|
|
@@ -5,8 +5,9 @@ exports.MaximumDate = exports.MaximumDateConstraint = void 0;
|
|
|
5
5
|
const type_guards_1 = require("../../utils/type-guards");
|
|
6
6
|
const decorators_1 = require("../decorators");
|
|
7
7
|
const schema_error_1 = require("../schema.error");
|
|
8
|
-
const
|
|
9
|
-
|
|
8
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
9
|
+
const types_1 = require("../types/types");
|
|
10
|
+
class MaximumDateConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
10
11
|
maximum;
|
|
11
12
|
suitableTypes = Number;
|
|
12
13
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"maximum-date.js","sourceRoot":"","sources":["../../../source/schema/constraints/maximum-date.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAgE;AAChE,8CAAqE;AACrE,kDAA8C;
|
|
1
|
+
{"version":3,"file":"maximum-date.js","sourceRoot":"","sources":["../../../source/schema/constraints/maximum-date.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAgE;AAChE,8CAAqE;AACrE,kDAA8C;AAC9C,8EAAyE;AAEzE,0CAA4C;AAE5C,MAAa,qBAAsB,SAAQ,+CAAqB;IAC7C,OAAO,CAAO;IAEtB,aAAa,GAAG,MAAM,CAAC;IACvB,OAAO,CAAS;IAEzB,YAAY,OAAsB;QAChC,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,OAAO,GAAG,IAAA,sBAAQ,EAAC,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC;QAC/D,IAAI,CAAC,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,EAAE,CAAC;QAElD,IAAA,6BAAe,EAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAChC,CAAC;IAED,QAAQ,CAAC,KAAW,EAAE,IAAc,EAAE,OAA0B;QAC9D,IAAI,KAAK,GAAG,IAAI,CAAC,OAAO,EAAE;YACxB,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SAC3I;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAtBD,sDAsBC;AAED,SAAgB,WAAW,CAAC,OAAe;IACzC,OAAO,IAAA,iDAAoC,EAAC,IAAI,qBAAqB,CAAC,OAAO,CAAC,EAAE,EAAE,MAAM,EAAE,IAAA,kBAAU,EAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAClH,CAAC;AAFD,kCAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MaximumLengthConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly maximumLength;
|
|
7
7
|
readonly suitableTypes: (ArrayConstructor | ArrayBufferConstructor | Int8ArrayConstructor | Uint8ArrayConstructor | Uint8ClampedArrayConstructor | Int16ArrayConstructor | Uint16ArrayConstructor | Int32ArrayConstructor | Uint32ArrayConstructor | Float32ArrayConstructor | Float64ArrayConstructor | BigInt64ArrayConstructor | BigUint64ArrayConstructor | StringConstructor)[];
|
|
@@ -5,8 +5,8 @@ exports.MaximumLength = exports.MaximumLengthConstraint = void 0;
|
|
|
5
5
|
const type_guards_1 = require("../../utils/type-guards");
|
|
6
6
|
const utils_1 = require("../decorators/utils");
|
|
7
7
|
const schema_error_1 = require("../schema.error");
|
|
8
|
-
const
|
|
9
|
-
class MaximumLengthConstraint extends
|
|
8
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
9
|
+
class MaximumLengthConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
10
10
|
maximumLength;
|
|
11
11
|
suitableTypes = [String, Array, ArrayBuffer, Int8Array, Uint8Array, Uint8ClampedArray, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array, BigInt64Array, BigUint64Array];
|
|
12
12
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"maximum-length.js","sourceRoot":"","sources":["../../../source/schema/constraints/maximum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAuE;AACvE,+CAA2E;AAC3E,kDAA8C;
|
|
1
|
+
{"version":3,"file":"maximum-length.js","sourceRoot":"","sources":["../../../source/schema/constraints/maximum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAuE;AACvE,+CAA2E;AAC3E,kDAA8C;AAC9C,8EAAyE;AAGzE,MAAa,uBAAwB,SAAQ,+CAAqB;IAC/C,aAAa,CAAS;IAE9B,aAAa,GAAG,CAAC,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,SAAS,EAAE,UAAU,EAAE,iBAAiB,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,WAAW,EAAE,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,cAAc,CAAC,CAAC;IACpM,OAAO,CAAS;IAEzB,YAAY,aAAqB;QAC/B,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,CAAC,OAAO,GAAG,uBAAuB,IAAI,CAAC,aAAa,EAAE,CAAC;IAC7D,CAAC;IAED,QAAQ,CAAC,KAAa,EAAE,IAAc,EAAE,OAA0B;QAChE,MAAM,MAAM,GAAG,CAAC,IAAA,2BAAa,EAAC,KAAK,CAAC,IAAI,IAAA,+BAAiB,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC;QAEpG,IAAI,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE;YAC/B,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,eAAe,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SAC/I;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAtBD,0DAsBC;AAED,SAAgB,aAAa,CAAC,aAAqB;IACjD,OAAO,IAAA,4CAAoC,EAAC,IAAI,uBAAuB,CAAC,aAAa,CAAC,CAAC,CAAC;AAC1F,CAAC;AAFD,sCAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MaximumConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly maximum;
|
|
7
7
|
readonly suitableTypes: NumberConstructor;
|
|
@@ -4,8 +4,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.Maximum = exports.MaximumConstraint = void 0;
|
|
5
5
|
const decorators_1 = require("../decorators");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
8
|
-
|
|
7
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
8
|
+
const types_1 = require("../types/types");
|
|
9
|
+
class MaximumConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
9
10
|
maximum;
|
|
10
11
|
suitableTypes = Number;
|
|
11
12
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"maximum.js","sourceRoot":"","sources":["../../../source/schema/constraints/maximum.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,8CAAqE;AACrE,kDAA8C;
|
|
1
|
+
{"version":3,"file":"maximum.js","sourceRoot":"","sources":["../../../source/schema/constraints/maximum.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,8CAAqE;AACrE,kDAA8C;AAC9C,8EAAyE;AAEzE,0CAA4C;AAE5C,MAAa,iBAAkB,SAAQ,+CAAqB;IACzC,OAAO,CAAS;IAExB,aAAa,GAAG,MAAM,CAAC;IACvB,OAAO,CAAS;IAEzB,YAAY,OAAe;QACzB,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;IACtC,CAAC;IAED,QAAQ,CAAC,KAAa,EAAE,IAAc,EAAE,OAA0B;QAChE,IAAI,KAAK,GAAG,IAAI,CAAC,OAAO,EAAE;YACxB,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SACxI;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AApBD,8CAoBC;AAED,SAAgB,OAAO,CAAC,OAAe;IACrC,OAAO,IAAA,iDAAoC,EAAC,IAAI,iBAAiB,CAAC,OAAO,CAAC,EAAE,EAAE,MAAM,EAAE,IAAA,kBAAU,EAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAC9G,CAAC;AAFD,0BAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MinimumDateConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly minimum;
|
|
7
7
|
readonly suitableTypes: NumberConstructor;
|
|
@@ -5,8 +5,9 @@ exports.MinimumDate = exports.MinimumDateConstraint = void 0;
|
|
|
5
5
|
const type_guards_1 = require("../../utils/type-guards");
|
|
6
6
|
const decorators_1 = require("../decorators");
|
|
7
7
|
const schema_error_1 = require("../schema.error");
|
|
8
|
-
const
|
|
9
|
-
|
|
8
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
9
|
+
const types_1 = require("../types/types");
|
|
10
|
+
class MinimumDateConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
10
11
|
minimum;
|
|
11
12
|
suitableTypes = Number;
|
|
12
13
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"minimum-date.js","sourceRoot":"","sources":["../../../source/schema/constraints/minimum-date.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAgE;AAChE,8CAAqE;AACrE,kDAA8C;
|
|
1
|
+
{"version":3,"file":"minimum-date.js","sourceRoot":"","sources":["../../../source/schema/constraints/minimum-date.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAgE;AAChE,8CAAqE;AACrE,kDAA8C;AAC9C,8EAAyE;AAEzE,0CAA4C;AAE5C,MAAa,qBAAsB,SAAQ,+CAAqB;IAC7C,OAAO,CAAO;IAEtB,aAAa,GAAG,MAAM,CAAC;IACvB,OAAO,CAAS;IAEzB,YAAY,OAAsB;QAChC,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,OAAO,GAAG,IAAA,sBAAQ,EAAC,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC;QAC/D,IAAI,CAAC,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,EAAE,CAAC;QAElD,IAAA,6BAAe,EAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAChC,CAAC;IAED,QAAQ,CAAC,KAAW,EAAE,IAAc,EAAE,OAA0B;QAC9D,IAAI,KAAK,GAAG,IAAI,CAAC,OAAO,EAAE;YACxB,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,WAAW,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SAC3I;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAtBD,sDAsBC;AAED,SAAgB,WAAW,CAAC,OAAe;IACzC,OAAO,IAAA,iDAAoC,EAAC,IAAI,qBAAqB,CAAC,OAAO,CAAC,EAAE,EAAE,MAAM,EAAE,IAAA,kBAAU,EAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAClH,CAAC;AAFD,kCAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MinimumLengthConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly minimumLength;
|
|
7
7
|
readonly suitableTypes: (ArrayConstructor | ArrayBufferConstructor | Int8ArrayConstructor | Uint8ArrayConstructor | Uint8ClampedArrayConstructor | Int16ArrayConstructor | Uint16ArrayConstructor | Int32ArrayConstructor | Uint32ArrayConstructor | Float32ArrayConstructor | Float64ArrayConstructor | BigInt64ArrayConstructor | BigUint64ArrayConstructor | StringConstructor)[];
|
|
@@ -5,8 +5,8 @@ exports.MinimumLength = exports.MinimumLengthConstraint = void 0;
|
|
|
5
5
|
const type_guards_1 = require("../../utils/type-guards");
|
|
6
6
|
const utils_1 = require("../decorators/utils");
|
|
7
7
|
const schema_error_1 = require("../schema.error");
|
|
8
|
-
const
|
|
9
|
-
class MinimumLengthConstraint extends
|
|
8
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
9
|
+
class MinimumLengthConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
10
10
|
minimumLength;
|
|
11
11
|
suitableTypes = [String, Array, ArrayBuffer, Int8Array, Uint8Array, Uint8ClampedArray, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array, BigInt64Array, BigUint64Array];
|
|
12
12
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"minimum-length.js","sourceRoot":"","sources":["../../../source/schema/constraints/minimum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAuE;AACvE,+CAA2E;AAC3E,kDAA8C;
|
|
1
|
+
{"version":3,"file":"minimum-length.js","sourceRoot":"","sources":["../../../source/schema/constraints/minimum-length.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,yDAAuE;AACvE,+CAA2E;AAC3E,kDAA8C;AAC9C,8EAAyE;AAGzE,MAAa,uBAAwB,SAAQ,+CAAqB;IAC/C,aAAa,CAAS;IAE9B,aAAa,GAAG,CAAC,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,SAAS,EAAE,UAAU,EAAE,iBAAiB,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,WAAW,EAAE,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,cAAc,CAAC,CAAC;IACpM,OAAO,CAAS;IAEzB,YAAY,aAAqB;QAC/B,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,CAAC,OAAO,GAAG,uBAAuB,IAAI,CAAC,aAAa,EAAE,CAAC;IAC7D,CAAC;IAED,QAAQ,CAAC,KAA4C,EAAE,IAAc,EAAE,OAA0B;QAC/F,MAAM,MAAM,GAAG,CAAC,IAAA,2BAAa,EAAC,KAAK,CAAC,IAAI,IAAA,+BAAiB,EAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC;QAEpG,IAAI,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE;YAC/B,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,eAAe,MAAM,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SAC/I;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AAtBD,0DAsBC;AAED,SAAgB,aAAa,CAAC,aAAqB;IACjD,OAAO,IAAA,4CAAoC,EAAC,IAAI,uBAAuB,CAAC,aAAa,CAAC,CAAC,CAAC;AAC1F,CAAC;AAFD,sCAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class MinimumConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly minimum;
|
|
7
7
|
readonly suitableTypes: NumberConstructor;
|
|
@@ -4,8 +4,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.Minimum = exports.MinimumConstraint = void 0;
|
|
5
5
|
const utils_1 = require("../decorators/utils");
|
|
6
6
|
const schema_error_1 = require("../schema.error");
|
|
7
|
-
const
|
|
8
|
-
|
|
7
|
+
const schema_value_constraint_1 = require("../types/schema-value-constraint");
|
|
8
|
+
const types_1 = require("../types/types");
|
|
9
|
+
class MinimumConstraint extends schema_value_constraint_1.SchemaValueConstraint {
|
|
9
10
|
minimum;
|
|
10
11
|
suitableTypes = Number;
|
|
11
12
|
expects;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"minimum.js","sourceRoot":"","sources":["../../../source/schema/constraints/minimum.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,+CAA2E;AAC3E,kDAA8C;
|
|
1
|
+
{"version":3,"file":"minimum.js","sourceRoot":"","sources":["../../../source/schema/constraints/minimum.ts"],"names":[],"mappings":";AAAA,yDAAyD;;;AAIzD,+CAA2E;AAC3E,kDAA8C;AAC9C,8EAAyE;AAEzE,0CAA4C;AAE5C,MAAa,iBAAkB,SAAQ,+CAAqB;IACzC,OAAO,CAAS;IAExB,aAAa,GAAG,MAAM,CAAC;IACvB,OAAO,CAAS;IAEzB,YAAY,OAAe;QACzB,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;IACtC,CAAC;IAED,QAAQ,CAAC,KAAa,EAAE,IAAc,EAAE,OAA0B;QAChE,IAAI,KAAK,GAAG,IAAI,CAAC,OAAO,EAAE;YACxB,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,0BAAW,CAAC,cAAc,CAAC,IAAI,CAAC,OAAO,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,CAAC;SACxI;QAED,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;IACzB,CAAC;CACF;AApBD,8CAoBC;AAED,SAAgB,OAAO,CAAC,OAAe;IACrC,OAAO,IAAA,4CAAoC,EAAC,IAAI,iBAAiB,CAAC,OAAO,CAAC,EAAE,EAAE,MAAM,EAAE,IAAA,kBAAU,EAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AAC9G,CAAC;AAFD,0BAEC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { JsonPath } from "../../json-path/json-path";
|
|
2
2
|
import type { Decorator } from "../../reflection";
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
3
|
+
import { SchemaValueConstraint } from '../types/schema-value-constraint';
|
|
4
|
+
import type { ConstraintContext, ConstraintResult } from '../types/types';
|
|
5
5
|
export declare class PatternConstraint extends SchemaValueConstraint {
|
|
6
6
|
private readonly pattern;
|
|
7
7
|
private readonly patternName;
|