@ahoo-wang/wow-client 9.2.0-rc.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/LICENSE +201 -0
- package/README.md +291 -0
- package/README.zh-CN.md +267 -0
- package/dist/_virtual/_@oxc-project_runtime@0.151.0/helpers/esm/decorate.cjs +1 -0
- package/dist/_virtual/_@oxc-project_runtime@0.151.0/helpers/esm/decorate.es.js +9 -0
- package/dist/_virtual/_@oxc-project_runtime@0.151.0/helpers/esm/decorateMetadata.cjs +1 -0
- package/dist/_virtual/_@oxc-project_runtime@0.151.0/helpers/esm/decorateMetadata.es.js +6 -0
- package/dist/_virtual/_@oxc-project_runtime@0.151.0/helpers/esm/decorateParam.cjs +1 -0
- package/dist/_virtual/_@oxc-project_runtime@0.151.0/helpers/esm/decorateParam.es.js +8 -0
- package/dist/client/bindMethods.cjs +2 -0
- package/dist/client/bindMethods.cjs.map +1 -0
- package/dist/client/bindMethods.d.cts +13 -0
- package/dist/client/bindMethods.d.ts +13 -0
- package/dist/client/bindMethods.es.js +19 -0
- package/dist/client/bindMethods.es.js.map +1 -0
- package/dist/client/command/commandClient.cjs +2 -0
- package/dist/client/command/commandClient.cjs.map +1 -0
- package/dist/client/command/commandClient.d.cts +67 -0
- package/dist/client/command/commandClient.d.ts +67 -0
- package/dist/client/command/commandClient.es.js +38 -0
- package/dist/client/command/commandClient.es.js.map +1 -0
- package/dist/client/command/commandHeaders.cjs +2 -0
- package/dist/client/command/commandHeaders.cjs.map +1 -0
- package/dist/client/command/commandHeaders.d.cts +75 -0
- package/dist/client/command/commandHeaders.d.ts +75 -0
- package/dist/client/command/commandHeaders.es.js +31 -0
- package/dist/client/command/commandHeaders.es.js.map +1 -0
- package/dist/client/command/commandRequest.cjs +2 -0
- package/dist/client/command/commandRequest.cjs.map +1 -0
- package/dist/client/command/commandRequest.d.cts +180 -0
- package/dist/client/command/commandRequest.d.ts +180 -0
- package/dist/client/command/commandRequest.es.js +31 -0
- package/dist/client/command/commandRequest.es.js.map +1 -0
- package/dist/client/command/commandResult.d.cts +15 -0
- package/dist/client/command/commandResult.d.ts +15 -0
- package/dist/client/command/index.d.cts +5 -0
- package/dist/client/command/index.d.ts +5 -0
- package/dist/client/command/types.d.cts +71 -0
- package/dist/client/command/types.d.ts +71 -0
- package/dist/client/metadata/index.d.cts +2 -0
- package/dist/client/metadata/index.d.ts +2 -0
- package/dist/client/metadata/wowMetadata.d.cts +48 -0
- package/dist/client/metadata/wowMetadata.d.ts +48 -0
- package/dist/client/metadata/wowMetadataClient.cjs +2 -0
- package/dist/client/metadata/wowMetadataClient.cjs.map +1 -0
- package/dist/client/metadata/wowMetadataClient.d.cts +23 -0
- package/dist/client/metadata/wowMetadataClient.d.ts +23 -0
- package/dist/client/metadata/wowMetadataClient.es.js +25 -0
- package/dist/client/metadata/wowMetadataClient.es.js.map +1 -0
- package/dist/client/query/descriptor/descriptorEndpoints.cjs +2 -0
- package/dist/client/query/descriptor/descriptorEndpoints.cjs.map +1 -0
- package/dist/client/query/descriptor/descriptorEndpoints.d.cts +29 -0
- package/dist/client/query/descriptor/descriptorEndpoints.d.ts +29 -0
- package/dist/client/query/descriptor/descriptorEndpoints.es.js +69 -0
- package/dist/client/query/descriptor/descriptorEndpoints.es.js.map +1 -0
- package/dist/client/query/descriptor/endpointPaths.cjs +2 -0
- package/dist/client/query/descriptor/endpointPaths.cjs.map +1 -0
- package/dist/client/query/descriptor/endpointPaths.d.cts +4 -0
- package/dist/client/query/descriptor/endpointPaths.d.ts +4 -0
- package/dist/client/query/descriptor/endpointPaths.es.js +9 -0
- package/dist/client/query/descriptor/endpointPaths.es.js.map +1 -0
- package/dist/client/query/descriptor/index.d.cts +2 -0
- package/dist/client/query/descriptor/index.d.ts +2 -0
- package/dist/client/query/descriptor/queryDescriptorApi.d.cts +58 -0
- package/dist/client/query/descriptor/queryDescriptorApi.d.ts +58 -0
- package/dist/client/query/descriptor/queryDescriptorClient.cjs +2 -0
- package/dist/client/query/descriptor/queryDescriptorClient.cjs.map +1 -0
- package/dist/client/query/descriptor/queryDescriptorClient.d.cts +61 -0
- package/dist/client/query/descriptor/queryDescriptorClient.d.ts +61 -0
- package/dist/client/query/descriptor/queryDescriptorClient.es.js +20 -0
- package/dist/client/query/descriptor/queryDescriptorClient.es.js.map +1 -0
- package/dist/client/query/event/domainEventStream.cjs +2 -0
- package/dist/client/query/event/domainEventStream.cjs.map +1 -0
- package/dist/client/query/event/domainEventStream.d.cts +105 -0
- package/dist/client/query/event/domainEventStream.d.ts +105 -0
- package/dist/client/query/event/domainEventStream.es.js +23 -0
- package/dist/client/query/event/domainEventStream.es.js.map +1 -0
- package/dist/client/query/event/endpointPaths.cjs +2 -0
- package/dist/client/query/event/endpointPaths.cjs.map +1 -0
- package/dist/client/query/event/endpointPaths.d.cts +8 -0
- package/dist/client/query/event/endpointPaths.d.ts +8 -0
- package/dist/client/query/event/endpointPaths.es.js +13 -0
- package/dist/client/query/event/endpointPaths.es.js.map +1 -0
- package/dist/client/query/event/eventStreamQueryApi.d.cts +29 -0
- package/dist/client/query/event/eventStreamQueryApi.d.ts +29 -0
- package/dist/client/query/event/eventStreamQueryClient.cjs +2 -0
- package/dist/client/query/event/eventStreamQueryClient.cjs.map +1 -0
- package/dist/client/query/event/eventStreamQueryClient.d.cts +190 -0
- package/dist/client/query/event/eventStreamQueryClient.d.ts +190 -0
- package/dist/client/query/event/eventStreamQueryClient.es.js +160 -0
- package/dist/client/query/event/eventStreamQueryClient.es.js.map +1 -0
- package/dist/client/query/event/index.d.cts +3 -0
- package/dist/client/query/event/index.d.ts +3 -0
- package/dist/client/query/factory.cjs +2 -0
- package/dist/client/query/factory.cjs.map +1 -0
- package/dist/client/query/factory.d.cts +165 -0
- package/dist/client/query/factory.d.ts +165 -0
- package/dist/client/query/factory.es.js +45 -0
- package/dist/client/query/factory.es.js.map +1 -0
- package/dist/client/query/index.d.cts +6 -0
- package/dist/client/query/index.d.ts +6 -0
- package/dist/client/query/queryApi.d.cts +68 -0
- package/dist/client/query/queryApi.d.ts +68 -0
- package/dist/client/query/requests.d.cts +24 -0
- package/dist/client/query/requests.d.ts +24 -0
- package/dist/client/query/snapshot/endpointPaths.cjs +2 -0
- package/dist/client/query/snapshot/endpointPaths.cjs.map +1 -0
- package/dist/client/query/snapshot/endpointPaths.d.cts +12 -0
- package/dist/client/query/snapshot/endpointPaths.d.ts +12 -0
- package/dist/client/query/snapshot/endpointPaths.es.js +17 -0
- package/dist/client/query/snapshot/endpointPaths.es.js.map +1 -0
- package/dist/client/query/snapshot/index.d.cts +3 -0
- package/dist/client/query/snapshot/index.d.ts +3 -0
- package/dist/client/query/snapshot/snapshot.cjs +2 -0
- package/dist/client/query/snapshot/snapshot.cjs.map +1 -0
- package/dist/client/query/snapshot/snapshot.d.cts +51 -0
- package/dist/client/query/snapshot/snapshot.d.ts +51 -0
- package/dist/client/query/snapshot/snapshot.es.js +20 -0
- package/dist/client/query/snapshot/snapshot.es.js.map +1 -0
- package/dist/client/query/snapshot/snapshotQueryApi.d.cts +101 -0
- package/dist/client/query/snapshot/snapshotQueryApi.d.ts +101 -0
- package/dist/client/query/snapshot/snapshotQueryClient.cjs +2 -0
- package/dist/client/query/snapshot/snapshotQueryClient.cjs.map +1 -0
- package/dist/client/query/snapshot/snapshotQueryClient.d.cts +369 -0
- package/dist/client/query/snapshot/snapshotQueryClient.d.ts +369 -0
- package/dist/client/query/snapshot/snapshotQueryClient.es.js +239 -0
- package/dist/client/query/snapshot/snapshotQueryClient.es.js.map +1 -0
- package/dist/client/query/state/endpointPaths.cjs +2 -0
- package/dist/client/query/state/endpointPaths.cjs.map +1 -0
- package/dist/client/query/state/endpointPaths.d.cts +10 -0
- package/dist/client/query/state/endpointPaths.d.ts +10 -0
- package/dist/client/query/state/endpointPaths.es.js +14 -0
- package/dist/client/query/state/endpointPaths.es.js.map +1 -0
- package/dist/client/query/state/index.d.cts +4 -0
- package/dist/client/query/state/index.d.ts +4 -0
- package/dist/client/query/state/loadOwnerStateAggregateApi.d.cts +36 -0
- package/dist/client/query/state/loadOwnerStateAggregateApi.d.ts +36 -0
- package/dist/client/query/state/loadOwnerStateAggregateClient.cjs +2 -0
- package/dist/client/query/state/loadOwnerStateAggregateClient.cjs.map +1 -0
- package/dist/client/query/state/loadOwnerStateAggregateClient.d.cts +58 -0
- package/dist/client/query/state/loadOwnerStateAggregateClient.d.ts +58 -0
- package/dist/client/query/state/loadOwnerStateAggregateClient.es.js +56 -0
- package/dist/client/query/state/loadOwnerStateAggregateClient.es.js.map +1 -0
- package/dist/client/query/state/loadStateAggregateApi.d.cts +37 -0
- package/dist/client/query/state/loadStateAggregateApi.d.ts +37 -0
- package/dist/client/query/state/loadStateAggregateClient.cjs +2 -0
- package/dist/client/query/state/loadStateAggregateClient.cjs.map +1 -0
- package/dist/client/query/state/loadStateAggregateClient.d.cts +62 -0
- package/dist/client/query/state/loadStateAggregateClient.d.ts +62 -0
- package/dist/client/query/state/loadStateAggregateClient.es.js +65 -0
- package/dist/client/query/state/loadStateAggregateClient.es.js.map +1 -0
- package/dist/client/routing.cjs +2 -0
- package/dist/client/routing.cjs.map +1 -0
- package/dist/client/routing.d.cts +47 -0
- package/dist/client/routing.d.ts +47 -0
- package/dist/client/routing.es.js +8 -0
- package/dist/client/routing.es.js.map +1 -0
- package/dist/dsl/aggregation/admit.cjs +2 -0
- package/dist/dsl/aggregation/admit.cjs.map +1 -0
- package/dist/dsl/aggregation/admit.d.cts +6 -0
- package/dist/dsl/aggregation/admit.d.ts +6 -0
- package/dist/dsl/aggregation/admit.es.js +142 -0
- package/dist/dsl/aggregation/admit.es.js.map +1 -0
- package/dist/dsl/aggregation/builders.cjs +2 -0
- package/dist/dsl/aggregation/builders.cjs.map +1 -0
- package/dist/dsl/aggregation/builders.d.cts +309 -0
- package/dist/dsl/aggregation/builders.d.ts +309 -0
- package/dist/dsl/aggregation/builders.es.js +188 -0
- package/dist/dsl/aggregation/builders.es.js.map +1 -0
- package/dist/dsl/aggregation/derived.cjs +2 -0
- package/dist/dsl/aggregation/derived.cjs.map +1 -0
- package/dist/dsl/aggregation/derived.d.cts +33 -0
- package/dist/dsl/aggregation/derived.d.ts +33 -0
- package/dist/dsl/aggregation/derived.es.js +31 -0
- package/dist/dsl/aggregation/derived.es.js.map +1 -0
- package/dist/dsl/aggregation/expressionTrees.cjs +2 -0
- package/dist/dsl/aggregation/expressionTrees.cjs.map +1 -0
- package/dist/dsl/aggregation/expressionTrees.d.cts +10 -0
- package/dist/dsl/aggregation/expressionTrees.d.ts +10 -0
- package/dist/dsl/aggregation/expressionTrees.es.js +44 -0
- package/dist/dsl/aggregation/expressionTrees.es.js.map +1 -0
- package/dist/dsl/aggregation/having.cjs +2 -0
- package/dist/dsl/aggregation/having.cjs.map +1 -0
- package/dist/dsl/aggregation/having.d.cts +94 -0
- package/dist/dsl/aggregation/having.d.ts +94 -0
- package/dist/dsl/aggregation/having.es.js +62 -0
- package/dist/dsl/aggregation/having.es.js.map +1 -0
- package/dist/dsl/aggregation/index.d.cts +4 -0
- package/dist/dsl/aggregation/index.d.ts +4 -0
- package/dist/dsl/aggregation/sort.cjs +2 -0
- package/dist/dsl/aggregation/sort.cjs.map +1 -0
- package/dist/dsl/aggregation/sort.d.cts +7 -0
- package/dist/dsl/aggregation/sort.d.ts +7 -0
- package/dist/dsl/aggregation/sort.es.js +10 -0
- package/dist/dsl/aggregation/sort.es.js.map +1 -0
- package/dist/dsl/aggregation/types.cjs +2 -0
- package/dist/dsl/aggregation/types.cjs.map +1 -0
- package/dist/dsl/aggregation/types.d.cts +608 -0
- package/dist/dsl/aggregation/types.d.ts +608 -0
- package/dist/dsl/aggregation/types.es.js +37 -0
- package/dist/dsl/aggregation/types.es.js.map +1 -0
- package/dist/dsl/cursorQuery.cjs +2 -0
- package/dist/dsl/cursorQuery.cjs.map +1 -0
- package/dist/dsl/cursorQuery.d.cts +69 -0
- package/dist/dsl/cursorQuery.d.ts +69 -0
- package/dist/dsl/cursorQuery.es.js +19 -0
- package/dist/dsl/cursorQuery.es.js.map +1 -0
- package/dist/dsl/deletionState.cjs +2 -0
- package/dist/dsl/deletionState.cjs.map +1 -0
- package/dist/dsl/deletionState.d.cts +19 -0
- package/dist/dsl/deletionState.d.ts +19 -0
- package/dist/dsl/deletionState.es.js +8 -0
- package/dist/dsl/deletionState.es.js.map +1 -0
- package/dist/dsl/descriptor.cjs +2 -0
- package/dist/dsl/descriptor.cjs.map +1 -0
- package/dist/dsl/descriptor.d.cts +629 -0
- package/dist/dsl/descriptor.d.ts +629 -0
- package/dist/dsl/descriptor.es.js +37 -0
- package/dist/dsl/descriptor.es.js.map +1 -0
- package/dist/dsl/documents.d.cts +8 -0
- package/dist/dsl/documents.d.ts +8 -0
- package/dist/dsl/field.cjs +2 -0
- package/dist/dsl/field.cjs.map +1 -0
- package/dist/dsl/field.d.cts +2 -0
- package/dist/dsl/field.d.ts +2 -0
- package/dist/dsl/field.es.js +10 -0
- package/dist/dsl/field.es.js.map +1 -0
- package/dist/dsl/filter/builders.cjs +2 -0
- package/dist/dsl/filter/builders.cjs.map +1 -0
- package/dist/dsl/filter/builders.d.cts +962 -0
- package/dist/dsl/filter/builders.d.ts +962 -0
- package/dist/dsl/filter/builders.es.js +289 -0
- package/dist/dsl/filter/builders.es.js.map +1 -0
- package/dist/dsl/filter/datePattern.cjs +2 -0
- package/dist/dsl/filter/datePattern.cjs.map +1 -0
- package/dist/dsl/filter/datePattern.d.cts +8 -0
- package/dist/dsl/filter/datePattern.d.ts +8 -0
- package/dist/dsl/filter/datePattern.es.js +100 -0
- package/dist/dsl/filter/datePattern.es.js.map +1 -0
- package/dist/dsl/filter/index.d.cts +3 -0
- package/dist/dsl/filter/index.d.ts +3 -0
- package/dist/dsl/filter/operator.cjs +2 -0
- package/dist/dsl/filter/operator.cjs.map +1 -0
- package/dist/dsl/filter/operator.d.cts +113 -0
- package/dist/dsl/filter/operator.d.ts +113 -0
- package/dist/dsl/filter/operator.es.js +14 -0
- package/dist/dsl/filter/operator.es.js.map +1 -0
- package/dist/dsl/filter/scope.cjs +2 -0
- package/dist/dsl/filter/scope.cjs.map +1 -0
- package/dist/dsl/filter/scope.d.cts +15 -0
- package/dist/dsl/filter/scope.d.ts +15 -0
- package/dist/dsl/filter/scope.es.js +32 -0
- package/dist/dsl/filter/scope.es.js.map +1 -0
- package/dist/dsl/filter/types.d.cts +274 -0
- package/dist/dsl/filter/types.d.ts +274 -0
- package/dist/dsl/filter/validate.cjs +2 -0
- package/dist/dsl/filter/validate.cjs.map +1 -0
- package/dist/dsl/filter/validate.d.cts +18 -0
- package/dist/dsl/filter/validate.d.ts +18 -0
- package/dist/dsl/filter/validate.es.js +56 -0
- package/dist/dsl/filter/validate.es.js.map +1 -0
- package/dist/dsl/pagination.cjs +2 -0
- package/dist/dsl/pagination.cjs.map +1 -0
- package/dist/dsl/pagination.d.cts +28 -0
- package/dist/dsl/pagination.d.ts +28 -0
- package/dist/dsl/pagination.es.js +15 -0
- package/dist/dsl/pagination.es.js.map +1 -0
- package/dist/dsl/projection.cjs +2 -0
- package/dist/dsl/projection.cjs.map +1 -0
- package/dist/dsl/projection.d.cts +27 -0
- package/dist/dsl/projection.d.ts +27 -0
- package/dist/dsl/projection.es.js +12 -0
- package/dist/dsl/projection.es.js.map +1 -0
- package/dist/dsl/queryable.cjs +2 -0
- package/dist/dsl/queryable.cjs.map +1 -0
- package/dist/dsl/queryable.d.cts +101 -0
- package/dist/dsl/queryable.d.ts +101 -0
- package/dist/dsl/queryable.es.js +40 -0
- package/dist/dsl/queryable.es.js.map +1 -0
- package/dist/dsl/sort.cjs +2 -0
- package/dist/dsl/sort.cjs.map +1 -0
- package/dist/dsl/sort.d.cts +33 -0
- package/dist/dsl/sort.d.ts +33 -0
- package/dist/dsl/sort.es.js +21 -0
- package/dist/dsl/sort.es.js.map +1 -0
- package/dist/dsl.cjs +1 -0
- package/dist/dsl.d.cts +23 -0
- package/dist/dsl.d.ts +23 -0
- package/dist/dsl.es.js +14 -0
- package/dist/error/errorInfo.cjs +2 -0
- package/dist/error/errorInfo.cjs.map +1 -0
- package/dist/error/errorInfo.d.cts +139 -0
- package/dist/error/errorInfo.d.ts +139 -0
- package/dist/error/errorInfo.es.js +32 -0
- package/dist/error/errorInfo.es.js.map +1 -0
- package/dist/error/headers.cjs +2 -0
- package/dist/error/headers.cjs.map +1 -0
- package/dist/error/headers.d.cts +38 -0
- package/dist/error/headers.d.ts +38 -0
- package/dist/error/headers.es.js +10 -0
- package/dist/error/headers.es.js.map +1 -0
- package/dist/error/index.d.cts +21 -0
- package/dist/error/index.d.ts +21 -0
- package/dist/error/queryErrorCodes.cjs +2 -0
- package/dist/error/queryErrorCodes.cjs.map +1 -0
- package/dist/error/queryErrorCodes.d.cts +199 -0
- package/dist/error/queryErrorCodes.d.ts +199 -0
- package/dist/error/queryErrorCodes.es.js +53 -0
- package/dist/error/queryErrorCodes.es.js.map +1 -0
- package/dist/error/wowError.cjs +2 -0
- package/dist/error/wowError.cjs.map +1 -0
- package/dist/error/wowError.d.cts +99 -0
- package/dist/error/wowError.d.ts +99 -0
- package/dist/error/wowError.es.js +53 -0
- package/dist/error/wowError.es.js.map +1 -0
- package/dist/index.cjs +1 -0
- package/dist/index.d.cts +17 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.es.js +34 -0
- package/dist/legacy/condition.cjs +2 -0
- package/dist/legacy/condition.cjs.map +1 -0
- package/dist/legacy/condition.d.cts +517 -0
- package/dist/legacy/condition.d.ts +517 -0
- package/dist/legacy/condition.es.js +338 -0
- package/dist/legacy/condition.es.js.map +1 -0
- package/dist/legacy/index.d.cts +16 -0
- package/dist/legacy/index.d.ts +16 -0
- package/dist/legacy/locale/en_US.cjs +2 -0
- package/dist/legacy/locale/en_US.cjs.map +1 -0
- package/dist/legacy/locale/en_US.d.cts +7 -0
- package/dist/legacy/locale/en_US.d.ts +7 -0
- package/dist/legacy/locale/en_US.es.js +50 -0
- package/dist/legacy/locale/en_US.es.js.map +1 -0
- package/dist/legacy/locale/operatorLocale.d.cts +10 -0
- package/dist/legacy/locale/operatorLocale.d.ts +10 -0
- package/dist/legacy/locale/zh_CN.cjs +2 -0
- package/dist/legacy/locale/zh_CN.cjs.map +1 -0
- package/dist/legacy/locale/zh_CN.d.cts +7 -0
- package/dist/legacy/locale/zh_CN.d.ts +7 -0
- package/dist/legacy/locale/zh_CN.es.js +50 -0
- package/dist/legacy/locale/zh_CN.es.js.map +1 -0
- package/dist/legacy/operator.cjs +2 -0
- package/dist/legacy/operator.cjs.map +1 -0
- package/dist/legacy/operator.d.cts +218 -0
- package/dist/legacy/operator.d.ts +218 -0
- package/dist/legacy/operator.es.js +25 -0
- package/dist/legacy/operator.es.js.map +1 -0
- package/dist/legacy/queryable.cjs +2 -0
- package/dist/legacy/queryable.cjs.map +1 -0
- package/dist/legacy/queryable.d.cts +61 -0
- package/dist/legacy/queryable.d.ts +61 -0
- package/dist/legacy/queryable.es.js +34 -0
- package/dist/legacy/queryable.es.js.map +1 -0
- package/dist/legacy.cjs +1 -0
- package/dist/legacy.es.js +6 -0
- package/dist/model/abac.cjs +2 -0
- package/dist/model/abac.cjs.map +1 -0
- package/dist/model/abac.d.cts +33 -0
- package/dist/model/abac.d.ts +33 -0
- package/dist/model/abac.es.js +6 -0
- package/dist/model/abac.es.js.map +1 -0
- package/dist/model/bi.cjs +2 -0
- package/dist/model/bi.cjs.map +1 -0
- package/dist/model/bi.d.cts +12 -0
- package/dist/model/bi.d.ts +12 -0
- package/dist/model/bi.es.js +8 -0
- package/dist/model/bi.es.js.map +1 -0
- package/dist/model/command.cjs +2 -0
- package/dist/model/command.cjs.map +1 -0
- package/dist/model/command.d.cts +137 -0
- package/dist/model/command.d.ts +137 -0
- package/dist/model/command.es.js +8 -0
- package/dist/model/command.es.js.map +1 -0
- package/dist/model/common.d.cts +19 -0
- package/dist/model/common.d.ts +19 -0
- package/dist/model/function.cjs +2 -0
- package/dist/model/function.cjs.map +1 -0
- package/dist/model/function.d.cts +41 -0
- package/dist/model/function.d.ts +41 -0
- package/dist/model/function.es.js +8 -0
- package/dist/model/function.es.js.map +1 -0
- package/dist/model/index.d.cts +22 -0
- package/dist/model/index.d.ts +22 -0
- package/dist/model/messaging.d.cts +5 -0
- package/dist/model/messaging.d.ts +5 -0
- package/dist/model/modeling.d.cts +145 -0
- package/dist/model/modeling.d.ts +145 -0
- package/dist/model/naming.d.cts +27 -0
- package/dist/model/naming.d.ts +27 -0
- package/dist/transport/endpoints.cjs +2 -0
- package/dist/transport/endpoints.cjs.map +1 -0
- package/dist/transport/endpoints.d.cts +79 -0
- package/dist/transport/endpoints.d.ts +79 -0
- package/dist/transport/endpoints.es.js +14 -0
- package/dist/transport/endpoints.es.js.map +1 -0
- package/dist/transport/eventStreams.cjs +2 -0
- package/dist/transport/eventStreams.cjs.map +1 -0
- package/dist/transport/eventStreams.d.cts +23 -0
- package/dist/transport/eventStreams.d.ts +23 -0
- package/dist/transport/eventStreams.es.js +22 -0
- package/dist/transport/eventStreams.es.js.map +1 -0
- package/dist/transport/index.d.cts +1 -0
- package/dist/transport/index.d.ts +1 -0
- package/package.json +110 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operator.cjs","names":["Operator","\"AND\"","\"OR\"","\"NOR\"","\"ID\"","\"IDS\"","\"AGGREGATE_ID\"","\"AGGREGATE_IDS\"","\"TENANT_ID\"","\"OWNER_ID\"","\"SPACE_ID\"","\"DELETED\"","\"ALL\"","\"EQ\"","\"NE\"","\"GT\"","\"LT\"","\"GTE\"","\"LTE\"","\"CONTAINS\"","\"IN\"","\"NOT_IN\"","\"BETWEEN\"","\"ALL_IN\"","\"STARTS_WITH\"","\"ENDS_WITH\"","\"ELEM_MATCH\"","\"NULL\"","\"NOT_NULL\"","\"TRUE\"","\"FALSE\"","\"EXISTS\"","\"TODAY\"","\"BEFORE_TODAY\"","\"TOMORROW\"","\"THIS_WEEK\"","\"NEXT_WEEK\"","\"LAST_WEEK\"","\"THIS_MONTH\"","\"LAST_MONTH\"","\"RECENT_DAYS\"","\"EARLIER_DAYS\"","\"MATCH\"","\"RAW\"","LOGICAL_OPERATORS","EMPTY_VALUE_OPERATORS"],"sources":["../../src/legacy/operator.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * The operator of a `Condition`, the query model Wow 8.10 understands.\n *\n * @deprecated Use FilterOperator instead. Removed in v10.\n */\nexport enum Operator {\n /**\n * Performs logical AND on the provided condition list\n */\n AND = 'AND',\n\n /**\n * Performs logical OR on the provided condition list\n */\n OR = 'OR',\n\n /**\n * Performs logical NOR on the provided condition list\n */\n NOR = 'NOR',\n\n /**\n * Matches all documents where the `id` field value equals the specified value\n */\n ID = 'ID',\n\n /**\n * Matches all documents where the `id` field value equals any value in the specified list\n */\n IDS = 'IDS',\n\n /**\n * Matches documents where the aggregate root ID equals the specified value\n */\n AGGREGATE_ID = 'AGGREGATE_ID',\n\n /**\n * Matches all documents where the aggregate root ID equals any value in the specified list\n */\n AGGREGATE_IDS = 'AGGREGATE_IDS',\n\n /**\n * Matches all documents where the `tenantId` field value equals the specified value\n */\n TENANT_ID = 'TENANT_ID',\n\n /**\n * Matches all documents where the `ownerId` field value equals the specified value\n */\n OWNER_ID = 'OWNER_ID',\n\n SPACE_ID = 'SPACE_ID',\n /**\n * Matches all documents where the `deleted` field value equals the specified value\n */\n DELETED = 'DELETED',\n\n /**\n * Matches all documents\n */\n ALL = 'ALL',\n\n /**\n * Matches all documents where the field name value equals the specified value\n */\n EQ = 'EQ',\n\n /**\n * Matches all documents where the field name value does not equal the specified value\n */\n NE = 'NE',\n\n /**\n * Matches all documents where the given field's value is greater than the specified value\n */\n GT = 'GT',\n\n /**\n * Matches all documents where the given field's value is less than the specified value\n */\n LT = 'LT',\n\n /**\n * Matches all documents where the given field's value is greater than or equal to the specified value\n */\n GTE = 'GTE',\n\n /**\n * Matches all documents where the given field's value is less than or equal to the specified value\n */\n LTE = 'LTE',\n\n /**\n * Matches all documents where the given field's value contains the specified value\n */\n CONTAINS = 'CONTAINS',\n\n /**\n * Matches all documents where the field value equals any value in the specified list\n */\n IN = 'IN',\n\n /**\n * Matches all documents where the field value does not equal any specified value or does not exist\n */\n NOT_IN = 'NOT_IN',\n\n /**\n * Matches all documents where the field value is within the specified range\n */\n BETWEEN = 'BETWEEN',\n\n /**\n * Matches all documents where the field value is an array containing all specified values\n */\n ALL_IN = 'ALL_IN',\n\n /**\n * Matches documents where the field value starts with the specified string\n */\n STARTS_WITH = 'STARTS_WITH',\n\n /**\n * Matches documents where the field value ends with the specified string\n */\n ENDS_WITH = 'ENDS_WITH',\n\n /**\n * Matches all documents where the condition includes an array field,\n * and at least one member of the array matches the given condition.\n */\n ELEM_MATCH = 'ELEM_MATCH',\n\n /**\n * Matches all documents where the field value is `null`\n */\n NULL = 'NULL',\n\n /**\n * Matches all documents where the field value is not `null`\n */\n NOT_NULL = 'NOT_NULL',\n\n /**\n * Matches all documents where the field value is `true`\n */\n TRUE = 'TRUE',\n\n /**\n * Matches all documents where the field value is `false`\n */\n FALSE = 'FALSE',\n\n /**\n * Matches documents based on whether the field exists\n */\n EXISTS = 'EXISTS',\n\n // #region Date filtering conditions, field requirement: `long` type timestamp in milliseconds\n /**\n * Matches all documents where the field is within today's range\n * > For example: if `today` is `2024-06-06`, matches documents in the range\n * `2024-06-06 00:00:00.000` ~ `2024-06-06 23:59:59.999`\n */\n TODAY = 'TODAY',\n\n /**\n * Matches all documents where the field is before today\n */\n BEFORE_TODAY = 'BEFORE_TODAY',\n\n /**\n * Matches all documents where the field is within yesterday's range\n * > For example: if `today` is `2024-06-06`, matches documents in the range\n * `2024-06-05 00:00:00.000` ~ `2024-06-05 23:59:59.999`\n */\n TOMORROW = 'TOMORROW',\n\n /**\n * Matches all documents where the field is within this week's range\n */\n THIS_WEEK = 'THIS_WEEK',\n\n /**\n * Matches all documents where the field is within next week's range\n */\n NEXT_WEEK = 'NEXT_WEEK',\n\n /**\n * Matches all documents where the field is within last week's range\n */\n LAST_WEEK = 'LAST_WEEK',\n\n /**\n * Matches all documents where the field is within this month's range\n * > For example:\n * - `today`: `2024-06-06`\n * - Matching range: `2024-06-01 00:00:00.000` ~ `2024-06-30 23:59:59.999`\n */\n THIS_MONTH = 'THIS_MONTH',\n\n /**\n * Matches all documents where the field is within last month's range\n * > For example:\n * - `today`: `2024-06-06`\n * - Matching range: `2024-05-01 00:00:00.000` ~ `2024-05-31 23:59:59.999`\n */\n LAST_MONTH = 'LAST_MONTH',\n\n /**\n * Matches all documents where the field is within the specified number of recent days\n * > For example: last 3 days\n * - `today`: `2024-06-06`\n * - Matching range: `2024-06-04 00:00:00.000` ~ `2024-06-06 23:59:59.999`\n * - That is: today, yesterday, the day before yesterday\n */\n RECENT_DAYS = 'RECENT_DAYS',\n\n /**\n * Matches all documents where the field is before the specified number of days\n *\n * > For example: before 3 days\n * - `today`: `2024-06-06`\n * - Matching range: all documents less than `2024-06-04 00:00:00.000`\n */\n EARLIER_DAYS = 'EARLIER_DAYS',\n // #endregion\n /**\n * Full-text match operator.\n * Performs a full-text search for the given keywords using database-native capabilities.\n * The exact matching behavior (such as which fields are searched) is backend-specific.\n *\n * For MongoDB: Uses `Filters.text`, which runs a full-text search over the configured text index\n * and is not restricted to a single field.\n * For Elasticsearch: Uses `QueryBuilders.match` for standard full-text search on the specified field.\n */\n MATCH = 'MATCH',\n /**\n * Raw operator, uses the condition value directly as the raw database query condition.\n *\n * Removed from Wow in #2999 and refused by current servers. Kept for servers\n * older than that; see `raw()`.\n */\n RAW = 'RAW',\n}\n\n/**\n * The operators whose condition combines child conditions: `AND`, `OR`,\n * `NOR`.\n *\n * @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.\n */\nexport const LOGICAL_OPERATORS = new Set([\n Operator.AND,\n Operator.OR,\n Operator.NOR,\n]);\n\n/**\n * The operators whose condition takes no value, such as `NULL`, `TRUE` and\n * `TODAY`.\n *\n * @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.\n */\nexport const EMPTY_VALUE_OPERATORS = new Set([\n Operator.NULL,\n Operator.NOT_NULL,\n Operator.TRUE,\n Operator.FALSE,\n Operator.EXISTS,\n Operator.TODAY,\n Operator.TOMORROW,\n Operator.THIS_WEEK,\n Operator.NEXT_WEEK,\n Operator.LAST_WEEK,\n Operator.THIS_MONTH,\n Operator.LAST_MONTH,\n]);\n"],"mappings":"AAkBA,IAAYA,EAAL,SAAA,EAAA,OAIL,GAAAC,IAAA,MAKA,EAAAC,GAAA,KAKA,EAAAC,IAAA,MAKA,EAAAC,GAAA,KAKA,EAAAC,IAAA,MAKA,EAAAC,aAAA,eAKA,EAAAC,cAAA,gBAKA,EAAAC,UAAA,YAKA,EAAAC,SAAA,WAEA,EAAAC,SAAA,WAIA,EAAAC,QAAA,UAKA,EAAAC,IAAA,MAKA,EAAAC,GAAA,KAKA,EAAAC,GAAA,KAKA,EAAAC,GAAA,KAKA,EAAAC,GAAA,KAKA,EAAAC,IAAA,MAKA,EAAAC,IAAA,MAKA,EAAAC,SAAA,WAKA,EAAAC,GAAA,KAKA,EAAAC,OAAA,SAKA,EAAAC,QAAA,UAKA,EAAAC,OAAA,SAKA,EAAAC,YAAA,cAKA,EAAAC,UAAA,YAMA,EAAAC,WAAA,aAKA,EAAAC,KAAA,OAKA,EAAAC,SAAA,WAKA,EAAAC,KAAA,OAKA,EAAAC,MAAA,QAKA,EAAAC,OAAA,SAQA,EAAAC,MAAA,QAKA,EAAAC,aAAA,eAOA,EAAAC,SAAA,WAKA,EAAAC,UAAA,YAKA,EAAAC,UAAA,YAKA,EAAAC,UAAA,YAQA,EAAAC,WAAA,aAQA,EAAAC,WAAA,aASA,EAAAC,YAAA,cASA,EAAAC,aAAA,eAWA,EAAAC,MAAA,QAOA,EAAAC,IAAA,OACF,EAAA,CAAA,CAAA,EAQaC,EAAoB,IAAI,IAAI,iBAIzC,CAAC,EAQYC,EAAwB,IAAI,IAAI,2HAa7C,CAAC"}
|
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The operator of a `Condition`, the query model Wow 8.10 understands.
|
|
3
|
+
*
|
|
4
|
+
* @deprecated Use FilterOperator instead. Removed in v10.
|
|
5
|
+
*/
|
|
6
|
+
export declare enum Operator {
|
|
7
|
+
/**
|
|
8
|
+
* Performs logical AND on the provided condition list
|
|
9
|
+
*/
|
|
10
|
+
AND = "AND",
|
|
11
|
+
/**
|
|
12
|
+
* Performs logical OR on the provided condition list
|
|
13
|
+
*/
|
|
14
|
+
OR = "OR",
|
|
15
|
+
/**
|
|
16
|
+
* Performs logical NOR on the provided condition list
|
|
17
|
+
*/
|
|
18
|
+
NOR = "NOR",
|
|
19
|
+
/**
|
|
20
|
+
* Matches all documents where the `id` field value equals the specified value
|
|
21
|
+
*/
|
|
22
|
+
ID = "ID",
|
|
23
|
+
/**
|
|
24
|
+
* Matches all documents where the `id` field value equals any value in the specified list
|
|
25
|
+
*/
|
|
26
|
+
IDS = "IDS",
|
|
27
|
+
/**
|
|
28
|
+
* Matches documents where the aggregate root ID equals the specified value
|
|
29
|
+
*/
|
|
30
|
+
AGGREGATE_ID = "AGGREGATE_ID",
|
|
31
|
+
/**
|
|
32
|
+
* Matches all documents where the aggregate root ID equals any value in the specified list
|
|
33
|
+
*/
|
|
34
|
+
AGGREGATE_IDS = "AGGREGATE_IDS",
|
|
35
|
+
/**
|
|
36
|
+
* Matches all documents where the `tenantId` field value equals the specified value
|
|
37
|
+
*/
|
|
38
|
+
TENANT_ID = "TENANT_ID",
|
|
39
|
+
/**
|
|
40
|
+
* Matches all documents where the `ownerId` field value equals the specified value
|
|
41
|
+
*/
|
|
42
|
+
OWNER_ID = "OWNER_ID",
|
|
43
|
+
SPACE_ID = "SPACE_ID",
|
|
44
|
+
/**
|
|
45
|
+
* Matches all documents where the `deleted` field value equals the specified value
|
|
46
|
+
*/
|
|
47
|
+
DELETED = "DELETED",
|
|
48
|
+
/**
|
|
49
|
+
* Matches all documents
|
|
50
|
+
*/
|
|
51
|
+
ALL = "ALL",
|
|
52
|
+
/**
|
|
53
|
+
* Matches all documents where the field name value equals the specified value
|
|
54
|
+
*/
|
|
55
|
+
EQ = "EQ",
|
|
56
|
+
/**
|
|
57
|
+
* Matches all documents where the field name value does not equal the specified value
|
|
58
|
+
*/
|
|
59
|
+
NE = "NE",
|
|
60
|
+
/**
|
|
61
|
+
* Matches all documents where the given field's value is greater than the specified value
|
|
62
|
+
*/
|
|
63
|
+
GT = "GT",
|
|
64
|
+
/**
|
|
65
|
+
* Matches all documents where the given field's value is less than the specified value
|
|
66
|
+
*/
|
|
67
|
+
LT = "LT",
|
|
68
|
+
/**
|
|
69
|
+
* Matches all documents where the given field's value is greater than or equal to the specified value
|
|
70
|
+
*/
|
|
71
|
+
GTE = "GTE",
|
|
72
|
+
/**
|
|
73
|
+
* Matches all documents where the given field's value is less than or equal to the specified value
|
|
74
|
+
*/
|
|
75
|
+
LTE = "LTE",
|
|
76
|
+
/**
|
|
77
|
+
* Matches all documents where the given field's value contains the specified value
|
|
78
|
+
*/
|
|
79
|
+
CONTAINS = "CONTAINS",
|
|
80
|
+
/**
|
|
81
|
+
* Matches all documents where the field value equals any value in the specified list
|
|
82
|
+
*/
|
|
83
|
+
IN = "IN",
|
|
84
|
+
/**
|
|
85
|
+
* Matches all documents where the field value does not equal any specified value or does not exist
|
|
86
|
+
*/
|
|
87
|
+
NOT_IN = "NOT_IN",
|
|
88
|
+
/**
|
|
89
|
+
* Matches all documents where the field value is within the specified range
|
|
90
|
+
*/
|
|
91
|
+
BETWEEN = "BETWEEN",
|
|
92
|
+
/**
|
|
93
|
+
* Matches all documents where the field value is an array containing all specified values
|
|
94
|
+
*/
|
|
95
|
+
ALL_IN = "ALL_IN",
|
|
96
|
+
/**
|
|
97
|
+
* Matches documents where the field value starts with the specified string
|
|
98
|
+
*/
|
|
99
|
+
STARTS_WITH = "STARTS_WITH",
|
|
100
|
+
/**
|
|
101
|
+
* Matches documents where the field value ends with the specified string
|
|
102
|
+
*/
|
|
103
|
+
ENDS_WITH = "ENDS_WITH",
|
|
104
|
+
/**
|
|
105
|
+
* Matches all documents where the condition includes an array field,
|
|
106
|
+
* and at least one member of the array matches the given condition.
|
|
107
|
+
*/
|
|
108
|
+
ELEM_MATCH = "ELEM_MATCH",
|
|
109
|
+
/**
|
|
110
|
+
* Matches all documents where the field value is `null`
|
|
111
|
+
*/
|
|
112
|
+
NULL = "NULL",
|
|
113
|
+
/**
|
|
114
|
+
* Matches all documents where the field value is not `null`
|
|
115
|
+
*/
|
|
116
|
+
NOT_NULL = "NOT_NULL",
|
|
117
|
+
/**
|
|
118
|
+
* Matches all documents where the field value is `true`
|
|
119
|
+
*/
|
|
120
|
+
TRUE = "TRUE",
|
|
121
|
+
/**
|
|
122
|
+
* Matches all documents where the field value is `false`
|
|
123
|
+
*/
|
|
124
|
+
FALSE = "FALSE",
|
|
125
|
+
/**
|
|
126
|
+
* Matches documents based on whether the field exists
|
|
127
|
+
*/
|
|
128
|
+
EXISTS = "EXISTS",
|
|
129
|
+
/**
|
|
130
|
+
* Matches all documents where the field is within today's range
|
|
131
|
+
* > For example: if `today` is `2024-06-06`, matches documents in the range
|
|
132
|
+
* `2024-06-06 00:00:00.000` ~ `2024-06-06 23:59:59.999`
|
|
133
|
+
*/
|
|
134
|
+
TODAY = "TODAY",
|
|
135
|
+
/**
|
|
136
|
+
* Matches all documents where the field is before today
|
|
137
|
+
*/
|
|
138
|
+
BEFORE_TODAY = "BEFORE_TODAY",
|
|
139
|
+
/**
|
|
140
|
+
* Matches all documents where the field is within yesterday's range
|
|
141
|
+
* > For example: if `today` is `2024-06-06`, matches documents in the range
|
|
142
|
+
* `2024-06-05 00:00:00.000` ~ `2024-06-05 23:59:59.999`
|
|
143
|
+
*/
|
|
144
|
+
TOMORROW = "TOMORROW",
|
|
145
|
+
/**
|
|
146
|
+
* Matches all documents where the field is within this week's range
|
|
147
|
+
*/
|
|
148
|
+
THIS_WEEK = "THIS_WEEK",
|
|
149
|
+
/**
|
|
150
|
+
* Matches all documents where the field is within next week's range
|
|
151
|
+
*/
|
|
152
|
+
NEXT_WEEK = "NEXT_WEEK",
|
|
153
|
+
/**
|
|
154
|
+
* Matches all documents where the field is within last week's range
|
|
155
|
+
*/
|
|
156
|
+
LAST_WEEK = "LAST_WEEK",
|
|
157
|
+
/**
|
|
158
|
+
* Matches all documents where the field is within this month's range
|
|
159
|
+
* > For example:
|
|
160
|
+
* - `today`: `2024-06-06`
|
|
161
|
+
* - Matching range: `2024-06-01 00:00:00.000` ~ `2024-06-30 23:59:59.999`
|
|
162
|
+
*/
|
|
163
|
+
THIS_MONTH = "THIS_MONTH",
|
|
164
|
+
/**
|
|
165
|
+
* Matches all documents where the field is within last month's range
|
|
166
|
+
* > For example:
|
|
167
|
+
* - `today`: `2024-06-06`
|
|
168
|
+
* - Matching range: `2024-05-01 00:00:00.000` ~ `2024-05-31 23:59:59.999`
|
|
169
|
+
*/
|
|
170
|
+
LAST_MONTH = "LAST_MONTH",
|
|
171
|
+
/**
|
|
172
|
+
* Matches all documents where the field is within the specified number of recent days
|
|
173
|
+
* > For example: last 3 days
|
|
174
|
+
* - `today`: `2024-06-06`
|
|
175
|
+
* - Matching range: `2024-06-04 00:00:00.000` ~ `2024-06-06 23:59:59.999`
|
|
176
|
+
* - That is: today, yesterday, the day before yesterday
|
|
177
|
+
*/
|
|
178
|
+
RECENT_DAYS = "RECENT_DAYS",
|
|
179
|
+
/**
|
|
180
|
+
* Matches all documents where the field is before the specified number of days
|
|
181
|
+
*
|
|
182
|
+
* > For example: before 3 days
|
|
183
|
+
* - `today`: `2024-06-06`
|
|
184
|
+
* - Matching range: all documents less than `2024-06-04 00:00:00.000`
|
|
185
|
+
*/
|
|
186
|
+
EARLIER_DAYS = "EARLIER_DAYS",
|
|
187
|
+
/**
|
|
188
|
+
* Full-text match operator.
|
|
189
|
+
* Performs a full-text search for the given keywords using database-native capabilities.
|
|
190
|
+
* The exact matching behavior (such as which fields are searched) is backend-specific.
|
|
191
|
+
*
|
|
192
|
+
* For MongoDB: Uses `Filters.text`, which runs a full-text search over the configured text index
|
|
193
|
+
* and is not restricted to a single field.
|
|
194
|
+
* For Elasticsearch: Uses `QueryBuilders.match` for standard full-text search on the specified field.
|
|
195
|
+
*/
|
|
196
|
+
MATCH = "MATCH",
|
|
197
|
+
/**
|
|
198
|
+
* Raw operator, uses the condition value directly as the raw database query condition.
|
|
199
|
+
*
|
|
200
|
+
* Removed from Wow in #2999 and refused by current servers. Kept for servers
|
|
201
|
+
* older than that; see `raw()`.
|
|
202
|
+
*/
|
|
203
|
+
RAW = "RAW"
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* The operators whose condition combines child conditions: `AND`, `OR`,
|
|
207
|
+
* `NOR`.
|
|
208
|
+
*
|
|
209
|
+
* @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.
|
|
210
|
+
*/
|
|
211
|
+
export declare const LOGICAL_OPERATORS: Set<Operator>;
|
|
212
|
+
/**
|
|
213
|
+
* The operators whose condition takes no value, such as `NULL`, `TRUE` and
|
|
214
|
+
* `TODAY`.
|
|
215
|
+
*
|
|
216
|
+
* @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.
|
|
217
|
+
*/
|
|
218
|
+
export declare const EMPTY_VALUE_OPERATORS: Set<Operator>;
|
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The operator of a `Condition`, the query model Wow 8.10 understands.
|
|
3
|
+
*
|
|
4
|
+
* @deprecated Use FilterOperator instead. Removed in v10.
|
|
5
|
+
*/
|
|
6
|
+
export declare enum Operator {
|
|
7
|
+
/**
|
|
8
|
+
* Performs logical AND on the provided condition list
|
|
9
|
+
*/
|
|
10
|
+
AND = "AND",
|
|
11
|
+
/**
|
|
12
|
+
* Performs logical OR on the provided condition list
|
|
13
|
+
*/
|
|
14
|
+
OR = "OR",
|
|
15
|
+
/**
|
|
16
|
+
* Performs logical NOR on the provided condition list
|
|
17
|
+
*/
|
|
18
|
+
NOR = "NOR",
|
|
19
|
+
/**
|
|
20
|
+
* Matches all documents where the `id` field value equals the specified value
|
|
21
|
+
*/
|
|
22
|
+
ID = "ID",
|
|
23
|
+
/**
|
|
24
|
+
* Matches all documents where the `id` field value equals any value in the specified list
|
|
25
|
+
*/
|
|
26
|
+
IDS = "IDS",
|
|
27
|
+
/**
|
|
28
|
+
* Matches documents where the aggregate root ID equals the specified value
|
|
29
|
+
*/
|
|
30
|
+
AGGREGATE_ID = "AGGREGATE_ID",
|
|
31
|
+
/**
|
|
32
|
+
* Matches all documents where the aggregate root ID equals any value in the specified list
|
|
33
|
+
*/
|
|
34
|
+
AGGREGATE_IDS = "AGGREGATE_IDS",
|
|
35
|
+
/**
|
|
36
|
+
* Matches all documents where the `tenantId` field value equals the specified value
|
|
37
|
+
*/
|
|
38
|
+
TENANT_ID = "TENANT_ID",
|
|
39
|
+
/**
|
|
40
|
+
* Matches all documents where the `ownerId` field value equals the specified value
|
|
41
|
+
*/
|
|
42
|
+
OWNER_ID = "OWNER_ID",
|
|
43
|
+
SPACE_ID = "SPACE_ID",
|
|
44
|
+
/**
|
|
45
|
+
* Matches all documents where the `deleted` field value equals the specified value
|
|
46
|
+
*/
|
|
47
|
+
DELETED = "DELETED",
|
|
48
|
+
/**
|
|
49
|
+
* Matches all documents
|
|
50
|
+
*/
|
|
51
|
+
ALL = "ALL",
|
|
52
|
+
/**
|
|
53
|
+
* Matches all documents where the field name value equals the specified value
|
|
54
|
+
*/
|
|
55
|
+
EQ = "EQ",
|
|
56
|
+
/**
|
|
57
|
+
* Matches all documents where the field name value does not equal the specified value
|
|
58
|
+
*/
|
|
59
|
+
NE = "NE",
|
|
60
|
+
/**
|
|
61
|
+
* Matches all documents where the given field's value is greater than the specified value
|
|
62
|
+
*/
|
|
63
|
+
GT = "GT",
|
|
64
|
+
/**
|
|
65
|
+
* Matches all documents where the given field's value is less than the specified value
|
|
66
|
+
*/
|
|
67
|
+
LT = "LT",
|
|
68
|
+
/**
|
|
69
|
+
* Matches all documents where the given field's value is greater than or equal to the specified value
|
|
70
|
+
*/
|
|
71
|
+
GTE = "GTE",
|
|
72
|
+
/**
|
|
73
|
+
* Matches all documents where the given field's value is less than or equal to the specified value
|
|
74
|
+
*/
|
|
75
|
+
LTE = "LTE",
|
|
76
|
+
/**
|
|
77
|
+
* Matches all documents where the given field's value contains the specified value
|
|
78
|
+
*/
|
|
79
|
+
CONTAINS = "CONTAINS",
|
|
80
|
+
/**
|
|
81
|
+
* Matches all documents where the field value equals any value in the specified list
|
|
82
|
+
*/
|
|
83
|
+
IN = "IN",
|
|
84
|
+
/**
|
|
85
|
+
* Matches all documents where the field value does not equal any specified value or does not exist
|
|
86
|
+
*/
|
|
87
|
+
NOT_IN = "NOT_IN",
|
|
88
|
+
/**
|
|
89
|
+
* Matches all documents where the field value is within the specified range
|
|
90
|
+
*/
|
|
91
|
+
BETWEEN = "BETWEEN",
|
|
92
|
+
/**
|
|
93
|
+
* Matches all documents where the field value is an array containing all specified values
|
|
94
|
+
*/
|
|
95
|
+
ALL_IN = "ALL_IN",
|
|
96
|
+
/**
|
|
97
|
+
* Matches documents where the field value starts with the specified string
|
|
98
|
+
*/
|
|
99
|
+
STARTS_WITH = "STARTS_WITH",
|
|
100
|
+
/**
|
|
101
|
+
* Matches documents where the field value ends with the specified string
|
|
102
|
+
*/
|
|
103
|
+
ENDS_WITH = "ENDS_WITH",
|
|
104
|
+
/**
|
|
105
|
+
* Matches all documents where the condition includes an array field,
|
|
106
|
+
* and at least one member of the array matches the given condition.
|
|
107
|
+
*/
|
|
108
|
+
ELEM_MATCH = "ELEM_MATCH",
|
|
109
|
+
/**
|
|
110
|
+
* Matches all documents where the field value is `null`
|
|
111
|
+
*/
|
|
112
|
+
NULL = "NULL",
|
|
113
|
+
/**
|
|
114
|
+
* Matches all documents where the field value is not `null`
|
|
115
|
+
*/
|
|
116
|
+
NOT_NULL = "NOT_NULL",
|
|
117
|
+
/**
|
|
118
|
+
* Matches all documents where the field value is `true`
|
|
119
|
+
*/
|
|
120
|
+
TRUE = "TRUE",
|
|
121
|
+
/**
|
|
122
|
+
* Matches all documents where the field value is `false`
|
|
123
|
+
*/
|
|
124
|
+
FALSE = "FALSE",
|
|
125
|
+
/**
|
|
126
|
+
* Matches documents based on whether the field exists
|
|
127
|
+
*/
|
|
128
|
+
EXISTS = "EXISTS",
|
|
129
|
+
/**
|
|
130
|
+
* Matches all documents where the field is within today's range
|
|
131
|
+
* > For example: if `today` is `2024-06-06`, matches documents in the range
|
|
132
|
+
* `2024-06-06 00:00:00.000` ~ `2024-06-06 23:59:59.999`
|
|
133
|
+
*/
|
|
134
|
+
TODAY = "TODAY",
|
|
135
|
+
/**
|
|
136
|
+
* Matches all documents where the field is before today
|
|
137
|
+
*/
|
|
138
|
+
BEFORE_TODAY = "BEFORE_TODAY",
|
|
139
|
+
/**
|
|
140
|
+
* Matches all documents where the field is within yesterday's range
|
|
141
|
+
* > For example: if `today` is `2024-06-06`, matches documents in the range
|
|
142
|
+
* `2024-06-05 00:00:00.000` ~ `2024-06-05 23:59:59.999`
|
|
143
|
+
*/
|
|
144
|
+
TOMORROW = "TOMORROW",
|
|
145
|
+
/**
|
|
146
|
+
* Matches all documents where the field is within this week's range
|
|
147
|
+
*/
|
|
148
|
+
THIS_WEEK = "THIS_WEEK",
|
|
149
|
+
/**
|
|
150
|
+
* Matches all documents where the field is within next week's range
|
|
151
|
+
*/
|
|
152
|
+
NEXT_WEEK = "NEXT_WEEK",
|
|
153
|
+
/**
|
|
154
|
+
* Matches all documents where the field is within last week's range
|
|
155
|
+
*/
|
|
156
|
+
LAST_WEEK = "LAST_WEEK",
|
|
157
|
+
/**
|
|
158
|
+
* Matches all documents where the field is within this month's range
|
|
159
|
+
* > For example:
|
|
160
|
+
* - `today`: `2024-06-06`
|
|
161
|
+
* - Matching range: `2024-06-01 00:00:00.000` ~ `2024-06-30 23:59:59.999`
|
|
162
|
+
*/
|
|
163
|
+
THIS_MONTH = "THIS_MONTH",
|
|
164
|
+
/**
|
|
165
|
+
* Matches all documents where the field is within last month's range
|
|
166
|
+
* > For example:
|
|
167
|
+
* - `today`: `2024-06-06`
|
|
168
|
+
* - Matching range: `2024-05-01 00:00:00.000` ~ `2024-05-31 23:59:59.999`
|
|
169
|
+
*/
|
|
170
|
+
LAST_MONTH = "LAST_MONTH",
|
|
171
|
+
/**
|
|
172
|
+
* Matches all documents where the field is within the specified number of recent days
|
|
173
|
+
* > For example: last 3 days
|
|
174
|
+
* - `today`: `2024-06-06`
|
|
175
|
+
* - Matching range: `2024-06-04 00:00:00.000` ~ `2024-06-06 23:59:59.999`
|
|
176
|
+
* - That is: today, yesterday, the day before yesterday
|
|
177
|
+
*/
|
|
178
|
+
RECENT_DAYS = "RECENT_DAYS",
|
|
179
|
+
/**
|
|
180
|
+
* Matches all documents where the field is before the specified number of days
|
|
181
|
+
*
|
|
182
|
+
* > For example: before 3 days
|
|
183
|
+
* - `today`: `2024-06-06`
|
|
184
|
+
* - Matching range: all documents less than `2024-06-04 00:00:00.000`
|
|
185
|
+
*/
|
|
186
|
+
EARLIER_DAYS = "EARLIER_DAYS",
|
|
187
|
+
/**
|
|
188
|
+
* Full-text match operator.
|
|
189
|
+
* Performs a full-text search for the given keywords using database-native capabilities.
|
|
190
|
+
* The exact matching behavior (such as which fields are searched) is backend-specific.
|
|
191
|
+
*
|
|
192
|
+
* For MongoDB: Uses `Filters.text`, which runs a full-text search over the configured text index
|
|
193
|
+
* and is not restricted to a single field.
|
|
194
|
+
* For Elasticsearch: Uses `QueryBuilders.match` for standard full-text search on the specified field.
|
|
195
|
+
*/
|
|
196
|
+
MATCH = "MATCH",
|
|
197
|
+
/**
|
|
198
|
+
* Raw operator, uses the condition value directly as the raw database query condition.
|
|
199
|
+
*
|
|
200
|
+
* Removed from Wow in #2999 and refused by current servers. Kept for servers
|
|
201
|
+
* older than that; see `raw()`.
|
|
202
|
+
*/
|
|
203
|
+
RAW = "RAW"
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* The operators whose condition combines child conditions: `AND`, `OR`,
|
|
207
|
+
* `NOR`.
|
|
208
|
+
*
|
|
209
|
+
* @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.
|
|
210
|
+
*/
|
|
211
|
+
export declare const LOGICAL_OPERATORS: Set<Operator>;
|
|
212
|
+
/**
|
|
213
|
+
* The operators whose condition takes no value, such as `NULL`, `TRUE` and
|
|
214
|
+
* `TODAY`.
|
|
215
|
+
*
|
|
216
|
+
* @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.
|
|
217
|
+
*/
|
|
218
|
+
export declare const EMPTY_VALUE_OPERATORS: Set<Operator>;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
//#region src/legacy/operator.ts
|
|
2
|
+
var e = /* @__PURE__ */ function(e) {
|
|
3
|
+
return e.AND = "AND", e.OR = "OR", e.NOR = "NOR", e.ID = "ID", e.IDS = "IDS", e.AGGREGATE_ID = "AGGREGATE_ID", e.AGGREGATE_IDS = "AGGREGATE_IDS", e.TENANT_ID = "TENANT_ID", e.OWNER_ID = "OWNER_ID", e.SPACE_ID = "SPACE_ID", e.DELETED = "DELETED", e.ALL = "ALL", e.EQ = "EQ", e.NE = "NE", e.GT = "GT", e.LT = "LT", e.GTE = "GTE", e.LTE = "LTE", e.CONTAINS = "CONTAINS", e.IN = "IN", e.NOT_IN = "NOT_IN", e.BETWEEN = "BETWEEN", e.ALL_IN = "ALL_IN", e.STARTS_WITH = "STARTS_WITH", e.ENDS_WITH = "ENDS_WITH", e.ELEM_MATCH = "ELEM_MATCH", e.NULL = "NULL", e.NOT_NULL = "NOT_NULL", e.TRUE = "TRUE", e.FALSE = "FALSE", e.EXISTS = "EXISTS", e.TODAY = "TODAY", e.BEFORE_TODAY = "BEFORE_TODAY", e.TOMORROW = "TOMORROW", e.THIS_WEEK = "THIS_WEEK", e.NEXT_WEEK = "NEXT_WEEK", e.LAST_WEEK = "LAST_WEEK", e.THIS_MONTH = "THIS_MONTH", e.LAST_MONTH = "LAST_MONTH", e.RECENT_DAYS = "RECENT_DAYS", e.EARLIER_DAYS = "EARLIER_DAYS", e.MATCH = "MATCH", e.RAW = "RAW", e;
|
|
4
|
+
}({}), t = /* @__PURE__ */ new Set([
|
|
5
|
+
"AND",
|
|
6
|
+
"OR",
|
|
7
|
+
"NOR"
|
|
8
|
+
]), n = /* @__PURE__ */ new Set([
|
|
9
|
+
"NULL",
|
|
10
|
+
"NOT_NULL",
|
|
11
|
+
"TRUE",
|
|
12
|
+
"FALSE",
|
|
13
|
+
"EXISTS",
|
|
14
|
+
"TODAY",
|
|
15
|
+
"TOMORROW",
|
|
16
|
+
"THIS_WEEK",
|
|
17
|
+
"NEXT_WEEK",
|
|
18
|
+
"LAST_WEEK",
|
|
19
|
+
"THIS_MONTH",
|
|
20
|
+
"LAST_MONTH"
|
|
21
|
+
]);
|
|
22
|
+
//#endregion
|
|
23
|
+
export { n as EMPTY_VALUE_OPERATORS, t as LOGICAL_OPERATORS, e as Operator };
|
|
24
|
+
|
|
25
|
+
//# sourceMappingURL=operator.es.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operator.es.js","names":["Operator","\"AND\"","\"OR\"","\"NOR\"","\"ID\"","\"IDS\"","\"AGGREGATE_ID\"","\"AGGREGATE_IDS\"","\"TENANT_ID\"","\"OWNER_ID\"","\"SPACE_ID\"","\"DELETED\"","\"ALL\"","\"EQ\"","\"NE\"","\"GT\"","\"LT\"","\"GTE\"","\"LTE\"","\"CONTAINS\"","\"IN\"","\"NOT_IN\"","\"BETWEEN\"","\"ALL_IN\"","\"STARTS_WITH\"","\"ENDS_WITH\"","\"ELEM_MATCH\"","\"NULL\"","\"NOT_NULL\"","\"TRUE\"","\"FALSE\"","\"EXISTS\"","\"TODAY\"","\"BEFORE_TODAY\"","\"TOMORROW\"","\"THIS_WEEK\"","\"NEXT_WEEK\"","\"LAST_WEEK\"","\"THIS_MONTH\"","\"LAST_MONTH\"","\"RECENT_DAYS\"","\"EARLIER_DAYS\"","\"MATCH\"","\"RAW\"","LOGICAL_OPERATORS","EMPTY_VALUE_OPERATORS"],"sources":["../../src/legacy/operator.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * The operator of a `Condition`, the query model Wow 8.10 understands.\n *\n * @deprecated Use FilterOperator instead. Removed in v10.\n */\nexport enum Operator {\n /**\n * Performs logical AND on the provided condition list\n */\n AND = 'AND',\n\n /**\n * Performs logical OR on the provided condition list\n */\n OR = 'OR',\n\n /**\n * Performs logical NOR on the provided condition list\n */\n NOR = 'NOR',\n\n /**\n * Matches all documents where the `id` field value equals the specified value\n */\n ID = 'ID',\n\n /**\n * Matches all documents where the `id` field value equals any value in the specified list\n */\n IDS = 'IDS',\n\n /**\n * Matches documents where the aggregate root ID equals the specified value\n */\n AGGREGATE_ID = 'AGGREGATE_ID',\n\n /**\n * Matches all documents where the aggregate root ID equals any value in the specified list\n */\n AGGREGATE_IDS = 'AGGREGATE_IDS',\n\n /**\n * Matches all documents where the `tenantId` field value equals the specified value\n */\n TENANT_ID = 'TENANT_ID',\n\n /**\n * Matches all documents where the `ownerId` field value equals the specified value\n */\n OWNER_ID = 'OWNER_ID',\n\n SPACE_ID = 'SPACE_ID',\n /**\n * Matches all documents where the `deleted` field value equals the specified value\n */\n DELETED = 'DELETED',\n\n /**\n * Matches all documents\n */\n ALL = 'ALL',\n\n /**\n * Matches all documents where the field name value equals the specified value\n */\n EQ = 'EQ',\n\n /**\n * Matches all documents where the field name value does not equal the specified value\n */\n NE = 'NE',\n\n /**\n * Matches all documents where the given field's value is greater than the specified value\n */\n GT = 'GT',\n\n /**\n * Matches all documents where the given field's value is less than the specified value\n */\n LT = 'LT',\n\n /**\n * Matches all documents where the given field's value is greater than or equal to the specified value\n */\n GTE = 'GTE',\n\n /**\n * Matches all documents where the given field's value is less than or equal to the specified value\n */\n LTE = 'LTE',\n\n /**\n * Matches all documents where the given field's value contains the specified value\n */\n CONTAINS = 'CONTAINS',\n\n /**\n * Matches all documents where the field value equals any value in the specified list\n */\n IN = 'IN',\n\n /**\n * Matches all documents where the field value does not equal any specified value or does not exist\n */\n NOT_IN = 'NOT_IN',\n\n /**\n * Matches all documents where the field value is within the specified range\n */\n BETWEEN = 'BETWEEN',\n\n /**\n * Matches all documents where the field value is an array containing all specified values\n */\n ALL_IN = 'ALL_IN',\n\n /**\n * Matches documents where the field value starts with the specified string\n */\n STARTS_WITH = 'STARTS_WITH',\n\n /**\n * Matches documents where the field value ends with the specified string\n */\n ENDS_WITH = 'ENDS_WITH',\n\n /**\n * Matches all documents where the condition includes an array field,\n * and at least one member of the array matches the given condition.\n */\n ELEM_MATCH = 'ELEM_MATCH',\n\n /**\n * Matches all documents where the field value is `null`\n */\n NULL = 'NULL',\n\n /**\n * Matches all documents where the field value is not `null`\n */\n NOT_NULL = 'NOT_NULL',\n\n /**\n * Matches all documents where the field value is `true`\n */\n TRUE = 'TRUE',\n\n /**\n * Matches all documents where the field value is `false`\n */\n FALSE = 'FALSE',\n\n /**\n * Matches documents based on whether the field exists\n */\n EXISTS = 'EXISTS',\n\n // #region Date filtering conditions, field requirement: `long` type timestamp in milliseconds\n /**\n * Matches all documents where the field is within today's range\n * > For example: if `today` is `2024-06-06`, matches documents in the range\n * `2024-06-06 00:00:00.000` ~ `2024-06-06 23:59:59.999`\n */\n TODAY = 'TODAY',\n\n /**\n * Matches all documents where the field is before today\n */\n BEFORE_TODAY = 'BEFORE_TODAY',\n\n /**\n * Matches all documents where the field is within yesterday's range\n * > For example: if `today` is `2024-06-06`, matches documents in the range\n * `2024-06-05 00:00:00.000` ~ `2024-06-05 23:59:59.999`\n */\n TOMORROW = 'TOMORROW',\n\n /**\n * Matches all documents where the field is within this week's range\n */\n THIS_WEEK = 'THIS_WEEK',\n\n /**\n * Matches all documents where the field is within next week's range\n */\n NEXT_WEEK = 'NEXT_WEEK',\n\n /**\n * Matches all documents where the field is within last week's range\n */\n LAST_WEEK = 'LAST_WEEK',\n\n /**\n * Matches all documents where the field is within this month's range\n * > For example:\n * - `today`: `2024-06-06`\n * - Matching range: `2024-06-01 00:00:00.000` ~ `2024-06-30 23:59:59.999`\n */\n THIS_MONTH = 'THIS_MONTH',\n\n /**\n * Matches all documents where the field is within last month's range\n * > For example:\n * - `today`: `2024-06-06`\n * - Matching range: `2024-05-01 00:00:00.000` ~ `2024-05-31 23:59:59.999`\n */\n LAST_MONTH = 'LAST_MONTH',\n\n /**\n * Matches all documents where the field is within the specified number of recent days\n * > For example: last 3 days\n * - `today`: `2024-06-06`\n * - Matching range: `2024-06-04 00:00:00.000` ~ `2024-06-06 23:59:59.999`\n * - That is: today, yesterday, the day before yesterday\n */\n RECENT_DAYS = 'RECENT_DAYS',\n\n /**\n * Matches all documents where the field is before the specified number of days\n *\n * > For example: before 3 days\n * - `today`: `2024-06-06`\n * - Matching range: all documents less than `2024-06-04 00:00:00.000`\n */\n EARLIER_DAYS = 'EARLIER_DAYS',\n // #endregion\n /**\n * Full-text match operator.\n * Performs a full-text search for the given keywords using database-native capabilities.\n * The exact matching behavior (such as which fields are searched) is backend-specific.\n *\n * For MongoDB: Uses `Filters.text`, which runs a full-text search over the configured text index\n * and is not restricted to a single field.\n * For Elasticsearch: Uses `QueryBuilders.match` for standard full-text search on the specified field.\n */\n MATCH = 'MATCH',\n /**\n * Raw operator, uses the condition value directly as the raw database query condition.\n *\n * Removed from Wow in #2999 and refused by current servers. Kept for servers\n * older than that; see `raw()`.\n */\n RAW = 'RAW',\n}\n\n/**\n * The operators whose condition combines child conditions: `AND`, `OR`,\n * `NOR`.\n *\n * @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.\n */\nexport const LOGICAL_OPERATORS = new Set([\n Operator.AND,\n Operator.OR,\n Operator.NOR,\n]);\n\n/**\n * The operators whose condition takes no value, such as `NULL`, `TRUE` and\n * `TODAY`.\n *\n * @deprecated Use FilterOperator and FilterExpression instead. Removed in v10.\n */\nexport const EMPTY_VALUE_OPERATORS = new Set([\n Operator.NULL,\n Operator.NOT_NULL,\n Operator.TRUE,\n Operator.FALSE,\n Operator.EXISTS,\n Operator.TODAY,\n Operator.TOMORROW,\n Operator.THIS_WEEK,\n Operator.NEXT_WEEK,\n Operator.LAST_WEEK,\n Operator.THIS_MONTH,\n Operator.LAST_MONTH,\n]);\n"],"mappings":";AAkBA,IAAYA,IAAL,yBAAA,GAAA;QAIL,EAAAC,MAAA,OAKA,EAAAC,KAAA,MAKA,EAAAC,MAAA,OAKA,EAAAC,KAAA,MAKA,EAAAC,MAAA,OAKA,EAAAC,eAAA,gBAKA,EAAAC,gBAAA,iBAKA,EAAAC,YAAA,aAKA,EAAAC,WAAA,YAEA,EAAAC,WAAA,YAIA,EAAAC,UAAA,WAKA,EAAAC,MAAA,OAKA,EAAAC,KAAA,MAKA,EAAAC,KAAA,MAKA,EAAAC,KAAA,MAKA,EAAAC,KAAA,MAKA,EAAAC,MAAA,OAKA,EAAAC,MAAA,OAKA,EAAAC,WAAA,YAKA,EAAAC,KAAA,MAKA,EAAAC,SAAA,UAKA,EAAAC,UAAA,WAKA,EAAAC,SAAA,UAKA,EAAAC,cAAA,eAKA,EAAAC,YAAA,aAMA,EAAAC,aAAA,cAKA,EAAAC,OAAA,QAKA,EAAAC,WAAA,YAKA,EAAAC,OAAA,QAKA,EAAAC,QAAA,SAKA,EAAAC,SAAA,UAQA,EAAAC,QAAA,SAKA,EAAAC,eAAA,gBAOA,EAAAC,WAAA,YAKA,EAAAC,YAAA,aAKA,EAAAC,YAAA,aAKA,EAAAC,YAAA,aAQA,EAAAC,aAAA,cAQA,EAAAC,aAAA,cASA,EAAAC,cAAA,eASA,EAAAC,eAAA,gBAWA,EAAAC,QAAA,SAOA,EAAAC,MAAA;AACF,EAAA,CAAA,CAAA,GAQaC,oBAAoB,IAAI,IAAI;;;;AAIzC,CAAC,GAQYC,oBAAwB,IAAI,IAAI;;;;;;;;;;;;;AAa7C,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
const e=require("../dsl/pagination.cjs"),t=require("./condition.cjs");function n(e){if(e===null)throw TypeError(`condition cannot be null.`);return{condition:e??t.all()}}function r({condition:e,projection:t,sort:r}={}){return{...n(e),projection:t,sort:r}}function i({condition:t,projection:r,sort:i,limit:a=e.DEFAULT_PAGINATION.size}={}){return{...n(t),projection:r,sort:i,limit:a}}function a({condition:t,projection:r,sort:i,pagination:a={...e.DEFAULT_PAGINATION}}={}){return{...n(t),projection:r,sort:i,pagination:a}}exports.listQuery=i,exports.pagedQuery=a,exports.singleQuery=r;
|
|
2
|
+
//# sourceMappingURL=queryable.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryable.cjs","names":["all","DEFAULT_PAGINATION","require_pagination","require_condition","queryCondition","condition","singleQuery","listQuery","pagedQuery"],"sources":["../../src/legacy/queryable.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { all, type ConditionCapable } from './condition.js';\nimport type { SortCapable } from '../dsl/sort.js';\nimport { DEFAULT_PAGINATION, type Pagination } from '../dsl/pagination.js';\nimport type { ProjectionCapable } from '../dsl/projection.js';\n\n/**\n * A query that filters with a `Condition`, the only query model Wow before\n * 8.11 understands.\n *\n * @deprecated Use FilterQueryable instead. Removed in v10.\n */\nexport interface Queryable<FIELDS extends string = string>\n extends\n ConditionCapable<FIELDS>,\n ProjectionCapable<FIELDS>,\n SortCapable<FIELDS> {}\n\n/**\n * The Condition-based body of a `single` query, for Wow 8.10 servers; build\n * it with this entry's `singleQuery()`.\n *\n * @deprecated Use FilterSingleQuery instead. Removed in v10.\n */\n// eslint-disable-next-line @typescript-eslint/no-empty-object-type\nexport interface SingleQuery<\n FIELDS extends string = string,\n> extends Queryable<FIELDS> {}\n\n/**\n * The Condition-based body of a `list` or `listStream` query, for Wow 8.10\n * servers; build it with this entry's `listQuery()`.\n *\n * @deprecated Use FilterListQuery instead. Removed in v10.\n */\nexport interface ListQuery<\n FIELDS extends string = string,\n> extends Queryable<FIELDS> {\n /** The most rows to return. `listQuery()` defaults it to `DEFAULT_PAGINATION.size`. */\n limit?: number;\n}\n\n/**\n * The Condition-based body of a `paged` query, for Wow 8.10 servers; build it\n * with this entry's `pagedQuery()`.\n *\n * @deprecated Use FilterPagedQuery instead. Removed in v10.\n */\nexport interface PagedQuery<\n FIELDS extends string = string,\n> extends Queryable<FIELDS> {\n /** Which page. `pagedQuery()` defaults it to `DEFAULT_PAGINATION`. */\n pagination?: Pagination;\n}\n\nfunction queryCondition<FIELDS extends string>(\n condition: ConditionCapable<FIELDS>['condition'] | undefined,\n): ConditionCapable<FIELDS> {\n if (condition === null) {\n throw new TypeError('condition cannot be null.');\n }\n return { condition: condition ?? all() };\n}\n\n/**\n * Builds a Condition-based `single` query body. The condition defaults to\n * `all()`.\n *\n * @deprecated Use singleQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.\n */\nexport function singleQuery<FIELDS extends string = string>({\n condition,\n projection,\n sort,\n}: Partial<SingleQuery<FIELDS>> = {}): SingleQuery<FIELDS> {\n return { ...queryCondition(condition), projection, sort };\n}\n\n/**\n * Builds a Condition-based `list` query body. The condition defaults to\n * `all()` and the limit to `DEFAULT_PAGINATION.size`.\n *\n * @deprecated Use listQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.\n */\nexport function listQuery<FIELDS extends string = string>({\n condition,\n projection,\n sort,\n limit = DEFAULT_PAGINATION.size,\n}: Partial<ListQuery<FIELDS>> = {}): ListQuery<FIELDS> {\n return { ...queryCondition(condition), projection, sort, limit };\n}\n\n/**\n * Builds a Condition-based `paged` query body. The condition defaults to\n * `all()` and the pagination to a copy of `DEFAULT_PAGINATION`.\n *\n * @deprecated Use pagedQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.\n */\nexport function pagedQuery<FIELDS extends string = string>({\n condition,\n projection,\n sort,\n pagination = { ...DEFAULT_PAGINATION },\n}: Partial<PagedQuery<FIELDS>> = {}): PagedQuery<FIELDS> {\n return { ...queryCondition(condition), projection, sort, pagination };\n}\n"],"mappings":"sEAmEA,SAASI,EACP,EAC0B,CAC1B,GAAIC,IAAc,KAChB,MAAU,UAAU,2BAA2B,EAEjD,MAAO,CAAE,UAAWA,GAAaL,EAAAA,IAAI,CAAE,CACzC,CAQA,SAAgBM,EAA4C,CAC1D,YACA,aACA,QACgC,CAAC,EAAwB,CACzD,MAAO,CAAE,GAAGF,EAAeC,CAAS,EAAG,aAAY,MAAK,CAC1D,CAQA,SAAgBE,EAA0C,CACxD,YACA,aACA,OACA,QAAQN,EAAAA,mBAAmB,MACG,CAAC,EAAsB,CACrD,MAAO,CAAE,GAAGG,EAAeC,CAAS,EAAG,aAAY,OAAM,OAAM,CACjE,CAQA,SAAgBG,EAA2C,CACzD,YACA,aACA,OACA,aAAa,CAAE,GAAGP,EAAAA,kBAAmB,GACN,CAAC,EAAuB,CACvD,MAAO,CAAE,GAAGG,EAAeC,CAAS,EAAG,aAAY,OAAM,YAAW,CACtE"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { ConditionCapable } from './condition.cjs';
|
|
2
|
+
import { SortCapable } from '../dsl/sort.cjs';
|
|
3
|
+
import { Pagination } from '../dsl/pagination.cjs';
|
|
4
|
+
import { ProjectionCapable } from '../dsl/projection.cjs';
|
|
5
|
+
/**
|
|
6
|
+
* A query that filters with a `Condition`, the only query model Wow before
|
|
7
|
+
* 8.11 understands.
|
|
8
|
+
*
|
|
9
|
+
* @deprecated Use FilterQueryable instead. Removed in v10.
|
|
10
|
+
*/
|
|
11
|
+
export interface Queryable<FIELDS extends string = string> extends ConditionCapable<FIELDS>, ProjectionCapable<FIELDS>, SortCapable<FIELDS> {
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* The Condition-based body of a `single` query, for Wow 8.10 servers; build
|
|
15
|
+
* it with this entry's `singleQuery()`.
|
|
16
|
+
*
|
|
17
|
+
* @deprecated Use FilterSingleQuery instead. Removed in v10.
|
|
18
|
+
*/
|
|
19
|
+
export interface SingleQuery<FIELDS extends string = string> extends Queryable<FIELDS> {
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The Condition-based body of a `list` or `listStream` query, for Wow 8.10
|
|
23
|
+
* servers; build it with this entry's `listQuery()`.
|
|
24
|
+
*
|
|
25
|
+
* @deprecated Use FilterListQuery instead. Removed in v10.
|
|
26
|
+
*/
|
|
27
|
+
export interface ListQuery<FIELDS extends string = string> extends Queryable<FIELDS> {
|
|
28
|
+
/** The most rows to return. `listQuery()` defaults it to `DEFAULT_PAGINATION.size`. */
|
|
29
|
+
limit?: number;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* The Condition-based body of a `paged` query, for Wow 8.10 servers; build it
|
|
33
|
+
* with this entry's `pagedQuery()`.
|
|
34
|
+
*
|
|
35
|
+
* @deprecated Use FilterPagedQuery instead. Removed in v10.
|
|
36
|
+
*/
|
|
37
|
+
export interface PagedQuery<FIELDS extends string = string> extends Queryable<FIELDS> {
|
|
38
|
+
/** Which page. `pagedQuery()` defaults it to `DEFAULT_PAGINATION`. */
|
|
39
|
+
pagination?: Pagination;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Builds a Condition-based `single` query body. The condition defaults to
|
|
43
|
+
* `all()`.
|
|
44
|
+
*
|
|
45
|
+
* @deprecated Use singleQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.
|
|
46
|
+
*/
|
|
47
|
+
export declare function singleQuery<FIELDS extends string = string>({ condition, projection, sort, }?: Partial<SingleQuery<FIELDS>>): SingleQuery<FIELDS>;
|
|
48
|
+
/**
|
|
49
|
+
* Builds a Condition-based `list` query body. The condition defaults to
|
|
50
|
+
* `all()` and the limit to `DEFAULT_PAGINATION.size`.
|
|
51
|
+
*
|
|
52
|
+
* @deprecated Use listQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.
|
|
53
|
+
*/
|
|
54
|
+
export declare function listQuery<FIELDS extends string = string>({ condition, projection, sort, limit, }?: Partial<ListQuery<FIELDS>>): ListQuery<FIELDS>;
|
|
55
|
+
/**
|
|
56
|
+
* Builds a Condition-based `paged` query body. The condition defaults to
|
|
57
|
+
* `all()` and the pagination to a copy of `DEFAULT_PAGINATION`.
|
|
58
|
+
*
|
|
59
|
+
* @deprecated Use pagedQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.
|
|
60
|
+
*/
|
|
61
|
+
export declare function pagedQuery<FIELDS extends string = string>({ condition, projection, sort, pagination, }?: Partial<PagedQuery<FIELDS>>): PagedQuery<FIELDS>;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { ConditionCapable } from './condition.js';
|
|
2
|
+
import { SortCapable } from '../dsl/sort.js';
|
|
3
|
+
import { Pagination } from '../dsl/pagination.js';
|
|
4
|
+
import { ProjectionCapable } from '../dsl/projection.js';
|
|
5
|
+
/**
|
|
6
|
+
* A query that filters with a `Condition`, the only query model Wow before
|
|
7
|
+
* 8.11 understands.
|
|
8
|
+
*
|
|
9
|
+
* @deprecated Use FilterQueryable instead. Removed in v10.
|
|
10
|
+
*/
|
|
11
|
+
export interface Queryable<FIELDS extends string = string> extends ConditionCapable<FIELDS>, ProjectionCapable<FIELDS>, SortCapable<FIELDS> {
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* The Condition-based body of a `single` query, for Wow 8.10 servers; build
|
|
15
|
+
* it with this entry's `singleQuery()`.
|
|
16
|
+
*
|
|
17
|
+
* @deprecated Use FilterSingleQuery instead. Removed in v10.
|
|
18
|
+
*/
|
|
19
|
+
export interface SingleQuery<FIELDS extends string = string> extends Queryable<FIELDS> {
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The Condition-based body of a `list` or `listStream` query, for Wow 8.10
|
|
23
|
+
* servers; build it with this entry's `listQuery()`.
|
|
24
|
+
*
|
|
25
|
+
* @deprecated Use FilterListQuery instead. Removed in v10.
|
|
26
|
+
*/
|
|
27
|
+
export interface ListQuery<FIELDS extends string = string> extends Queryable<FIELDS> {
|
|
28
|
+
/** The most rows to return. `listQuery()` defaults it to `DEFAULT_PAGINATION.size`. */
|
|
29
|
+
limit?: number;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* The Condition-based body of a `paged` query, for Wow 8.10 servers; build it
|
|
33
|
+
* with this entry's `pagedQuery()`.
|
|
34
|
+
*
|
|
35
|
+
* @deprecated Use FilterPagedQuery instead. Removed in v10.
|
|
36
|
+
*/
|
|
37
|
+
export interface PagedQuery<FIELDS extends string = string> extends Queryable<FIELDS> {
|
|
38
|
+
/** Which page. `pagedQuery()` defaults it to `DEFAULT_PAGINATION`. */
|
|
39
|
+
pagination?: Pagination;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Builds a Condition-based `single` query body. The condition defaults to
|
|
43
|
+
* `all()`.
|
|
44
|
+
*
|
|
45
|
+
* @deprecated Use singleQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.
|
|
46
|
+
*/
|
|
47
|
+
export declare function singleQuery<FIELDS extends string = string>({ condition, projection, sort, }?: Partial<SingleQuery<FIELDS>>): SingleQuery<FIELDS>;
|
|
48
|
+
/**
|
|
49
|
+
* Builds a Condition-based `list` query body. The condition defaults to
|
|
50
|
+
* `all()` and the limit to `DEFAULT_PAGINATION.size`.
|
|
51
|
+
*
|
|
52
|
+
* @deprecated Use listQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.
|
|
53
|
+
*/
|
|
54
|
+
export declare function listQuery<FIELDS extends string = string>({ condition, projection, sort, limit, }?: Partial<ListQuery<FIELDS>>): ListQuery<FIELDS>;
|
|
55
|
+
/**
|
|
56
|
+
* Builds a Condition-based `paged` query body. The condition defaults to
|
|
57
|
+
* `all()` and the pagination to a copy of `DEFAULT_PAGINATION`.
|
|
58
|
+
*
|
|
59
|
+
* @deprecated Use pagedQuery from `@ahoo-wang/wow-client` with a filter instead. Removed in v10.
|
|
60
|
+
*/
|
|
61
|
+
export declare function pagedQuery<FIELDS extends string = string>({ condition, projection, sort, pagination, }?: Partial<PagedQuery<FIELDS>>): PagedQuery<FIELDS>;
|