mongodb-pipeline-builder 3.3.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/CHANGELOG.md +362 -0
- package/LICENSE +21 -0
- package/Readme.md +280 -0
- package/constants/index.d.ts +3 -0
- package/constants/index.js +37 -0
- package/constants/index.js.map +1 -0
- package/decorators/index.d.ts +1 -0
- package/decorators/index.js +6 -0
- package/decorators/index.js.map +1 -0
- package/decorators/is-valid-name/is-valid-name.d.ts +6 -0
- package/decorators/is-valid-name/is-valid-name.js +54 -0
- package/decorators/is-valid-name/is-valid-name.js.map +1 -0
- package/errors/index.d.ts +1 -0
- package/errors/index.js +6 -0
- package/errors/index.js.map +1 -0
- package/errors/pipeline/pipeline.error.d.ts +4 -0
- package/errors/pipeline/pipeline.error.js +30 -0
- package/errors/pipeline/pipeline.error.js.map +1 -0
- package/helpers/bucket/group-by-payload.d.ts +5 -0
- package/helpers/bucket/group-by-payload.js +19 -0
- package/helpers/bucket/group-by-payload.js.map +1 -0
- package/helpers/bucket-auto/group-by-auto-payload.d.ts +6 -0
- package/helpers/bucket-auto/group-by-auto-payload.js +19 -0
- package/helpers/bucket-auto/group-by-auto-payload.js.map +1 -0
- package/helpers/commons/field.d.ts +3 -0
- package/helpers/commons/field.js +9 -0
- package/helpers/commons/field.js.map +1 -0
- package/helpers/commons/list.d.ts +1 -0
- package/helpers/commons/list.js +12 -0
- package/helpers/commons/list.js.map +1 -0
- package/helpers/current-op/op-payload.d.ts +9 -0
- package/helpers/current-op/op-payload.js +25 -0
- package/helpers/current-op/op-payload.js.map +1 -0
- package/helpers/geo-near/near-payload.d.ts +11 -0
- package/helpers/geo-near/near-payload.js +26 -0
- package/helpers/geo-near/near-payload.js.map +1 -0
- package/helpers/index.d.ts +14 -0
- package/helpers/index.js +32 -0
- package/helpers/index.js.map +1 -0
- package/helpers/lookup/condition-payload.d.ts +8 -0
- package/helpers/lookup/condition-payload.js +29 -0
- package/helpers/lookup/condition-payload.js.map +1 -0
- package/helpers/lookup/equality-payload.d.ts +2 -0
- package/helpers/lookup/equality-payload.js +17 -0
- package/helpers/lookup/equality-payload.js.map +1 -0
- package/helpers/merge/into-payload.d.ts +11 -0
- package/helpers/merge/into-payload.js +14 -0
- package/helpers/merge/into-payload.js.map +1 -0
- package/helpers/out/db-coll-payload.d.ts +2 -0
- package/helpers/out/db-coll-payload.js +14 -0
- package/helpers/out/db-coll-payload.js.map +1 -0
- package/helpers/project/ignore-payload.d.ts +3 -0
- package/helpers/project/ignore-payload.js +14 -0
- package/helpers/project/ignore-payload.js.map +1 -0
- package/helpers/project/ignore.d.ts +3 -0
- package/helpers/project/ignore.js +15 -0
- package/helpers/project/ignore.js.map +1 -0
- package/helpers/project/only-payload.d.ts +3 -0
- package/helpers/project/only-payload.js +18 -0
- package/helpers/project/only-payload.js.map +1 -0
- package/helpers/project/only.d.ts +3 -0
- package/helpers/project/only.js +15 -0
- package/helpers/project/only.js.map +1 -0
- package/helpers/sample/size-payload.d.ts +3 -0
- package/helpers/sample/size-payload.js +9 -0
- package/helpers/sample/size-payload.js.map +1 -0
- package/helpers/union-with/collection-payload.d.ts +2 -0
- package/helpers/union-with/collection-payload.js +9 -0
- package/helpers/union-with/collection-payload.js.map +1 -0
- package/index.d.ts +1 -0
- package/index.js +6 -0
- package/index.js.map +1 -0
- package/interfaces/core/builder-options.interface.d.ts +4 -0
- package/interfaces/core/builder-options.interface.js +3 -0
- package/interfaces/core/builder-options.interface.js.map +1 -0
- package/interfaces/core/debug-build.interface.d.ts +5 -0
- package/interfaces/core/debug-build.interface.js +3 -0
- package/interfaces/core/debug-build.interface.js.map +1 -0
- package/interfaces/core/debug-history.interface.d.ts +7 -0
- package/interfaces/core/debug-history.interface.js +3 -0
- package/interfaces/core/debug-history.interface.js.map +1 -0
- package/interfaces/core/get-paging-result.response.d.ts +5 -0
- package/interfaces/core/get-paging-result.response.js +3 -0
- package/interfaces/core/get-paging-result.response.js.map +1 -0
- package/interfaces/core/get-result.response.d.ts +4 -0
- package/interfaces/core/get-result.response.js +3 -0
- package/interfaces/core/get-result.response.js.map +1 -0
- package/interfaces/core/init-options.interface.d.ts +4 -0
- package/interfaces/core/init-options.interface.js +3 -0
- package/interfaces/core/init-options.interface.js.map +1 -0
- package/interfaces/core/stage-error.interface.d.ts +4 -0
- package/interfaces/core/stage-error.interface.js +3 -0
- package/interfaces/core/stage-error.interface.js.map +1 -0
- package/interfaces/core/stage-type.interface.d.ts +34 -0
- package/interfaces/core/stage-type.interface.js +41 -0
- package/interfaces/core/stage-type.interface.js.map +1 -0
- package/interfaces/core/stage.interface.d.ts +43 -0
- package/interfaces/core/stage.interface.js +3 -0
- package/interfaces/core/stage.interface.js.map +1 -0
- package/interfaces/index.d.ts +24 -0
- package/interfaces/index.js +7 -0
- package/interfaces/index.js.map +1 -0
- package/interfaces/stages/bucket-auto-stage.interface.d.ts +9 -0
- package/interfaces/stages/bucket-auto-stage.interface.js +3 -0
- package/interfaces/stages/bucket-auto-stage.interface.js.map +1 -0
- package/interfaces/stages/bucket-stage.interface.d.ts +10 -0
- package/interfaces/stages/bucket-stage.interface.js +3 -0
- package/interfaces/stages/bucket-stage.interface.js.map +1 -0
- package/interfaces/stages/coll-stats-stage.interface.d.ts +10 -0
- package/interfaces/stages/coll-stats-stage.interface.js +3 -0
- package/interfaces/stages/coll-stats-stage.interface.js.map +1 -0
- package/interfaces/stages/current-op.interface.d.ts +8 -0
- package/interfaces/stages/current-op.interface.js +3 -0
- package/interfaces/stages/current-op.interface.js.map +1 -0
- package/interfaces/stages/facet-stage.interface.d.ts +4 -0
- package/interfaces/stages/facet-stage.interface.js +3 -0
- package/interfaces/stages/facet-stage.interface.js.map +1 -0
- package/interfaces/stages/geo-near-stage.interface.d.ts +12 -0
- package/interfaces/stages/geo-near-stage.interface.js +3 -0
- package/interfaces/stages/geo-near-stage.interface.js.map +1 -0
- package/interfaces/stages/graph-lookup-stage.interface.d.ts +10 -0
- package/interfaces/stages/graph-lookup-stage.interface.js +3 -0
- package/interfaces/stages/graph-lookup-stage.interface.js.map +1 -0
- package/interfaces/stages/group-stage.interface.d.ts +4 -0
- package/interfaces/stages/group-stage.interface.js +3 -0
- package/interfaces/stages/group-stage.interface.js.map +1 -0
- package/interfaces/stages/lookup-condition.interface.d.ts +12 -0
- package/interfaces/stages/lookup-condition.interface.js +3 -0
- package/interfaces/stages/lookup-condition.interface.js.map +1 -0
- package/interfaces/stages/lookup-equality.interface.d.ts +6 -0
- package/interfaces/stages/lookup-equality.interface.js +3 -0
- package/interfaces/stages/lookup-equality.interface.js.map +1 -0
- package/interfaces/stages/lookup-stage.interface.d.ts +11 -0
- package/interfaces/stages/lookup-stage.interface.js +3 -0
- package/interfaces/stages/lookup-stage.interface.js.map +1 -0
- package/interfaces/stages/merge-stage.interface.d.ts +12 -0
- package/interfaces/stages/merge-stage.interface.js +3 -0
- package/interfaces/stages/merge-stage.interface.js.map +1 -0
- package/interfaces/stages/out-stage.interface.d.ts +4 -0
- package/interfaces/stages/out-stage.interface.js +3 -0
- package/interfaces/stages/out-stage.interface.js.map +1 -0
- package/interfaces/stages/replace-root-stage.interface.d.ts +3 -0
- package/interfaces/stages/replace-root-stage.interface.js +3 -0
- package/interfaces/stages/replace-root-stage.interface.js.map +1 -0
- package/interfaces/stages/sample-stage.interface.d.ts +3 -0
- package/interfaces/stages/sample-stage.interface.js +3 -0
- package/interfaces/stages/sample-stage.interface.js.map +1 -0
- package/interfaces/stages/union-with-stage.interface.d.ts +5 -0
- package/interfaces/stages/union-with-stage.interface.js +3 -0
- package/interfaces/stages/union-with-stage.interface.js.map +1 -0
- package/interfaces/stages/unwind-stage.interface.d.ts +5 -0
- package/interfaces/stages/unwind-stage.interface.js +3 -0
- package/interfaces/stages/unwind-stage.interface.js.map +1 -0
- package/main.d.ts +75 -0
- package/main.js +336 -0
- package/main.js.map +1 -0
- package/methods/get-result/get-result.d.ts +6 -0
- package/methods/get-result/get-result.js +126 -0
- package/methods/get-result/get-result.js.map +1 -0
- package/methods/index.d.ts +1 -0
- package/methods/index.js +6 -0
- package/methods/index.js.map +1 -0
- package/operators/accumulator/index.d.ts +24 -0
- package/operators/accumulator/index.js +20 -0
- package/operators/accumulator/index.js.map +1 -0
- package/operators/arithmetic/index.d.ts +48 -0
- package/operators/arithmetic/index.js +48 -0
- package/operators/arithmetic/index.js.map +1 -0
- package/operators/array/index.d.ts +67 -0
- package/operators/array/index.js +78 -0
- package/operators/array/index.js.map +1 -0
- package/operators/boolean/index.d.ts +9 -0
- package/operators/boolean/index.js +22 -0
- package/operators/boolean/index.js.map +1 -0
- package/operators/comparison/index.d.ts +21 -0
- package/operators/comparison/index.js +18 -0
- package/operators/comparison/index.js.map +1 -0
- package/operators/conditional/index.d.ts +18 -0
- package/operators/conditional/index.js +17 -0
- package/operators/conditional/index.js.map +1 -0
- package/operators/custom-aggregation/index.d.ts +18 -0
- package/operators/custom-aggregation/index.js +31 -0
- package/operators/custom-aggregation/index.js.map +1 -0
- package/operators/data-size/index.d.ts +6 -0
- package/operators/data-size/index.js +8 -0
- package/operators/data-size/index.js.map +1 -0
- package/operators/date/index.d.ts +119 -0
- package/operators/date/index.js +90 -0
- package/operators/date/index.js.map +1 -0
- package/operators/index.d.ts +14 -0
- package/operators/index.js +155 -0
- package/operators/index.js.map +1 -0
- package/operators/misc/index.d.ts +24 -0
- package/operators/misc/index.js +26 -0
- package/operators/misc/index.js.map +1 -0
- package/operators/set/index.d.ts +21 -0
- package/operators/set/index.js +36 -0
- package/operators/set/index.js.map +1 -0
- package/operators/string/index.d.ts +89 -0
- package/operators/string/index.js +66 -0
- package/operators/string/index.js.map +1 -0
- package/operators/trigonometry/index.d.ts +45 -0
- package/operators/trigonometry/index.js +34 -0
- package/operators/trigonometry/index.js.map +1 -0
- package/operators/type/index.d.ts +32 -0
- package/operators/type/index.js +29 -0
- package/operators/type/index.js.map +1 -0
- package/package.json +76 -0
- package/validators/index.d.ts +31 -0
- package/validators/index.js +69 -0
- package/validators/index.js.map +1 -0
- package/validators/stages/addFields-payload.validator.d.ts +3 -0
- package/validators/stages/addFields-payload.validator.js +19 -0
- package/validators/stages/addFields-payload.validator.js.map +1 -0
- package/validators/stages/bucket-auto-payload.validator.d.ts +2 -0
- package/validators/stages/bucket-auto-payload.validator.js +26 -0
- package/validators/stages/bucket-auto-payload.validator.js.map +1 -0
- package/validators/stages/bucket-payload.validator.d.ts +2 -0
- package/validators/stages/bucket-payload.validator.js +20 -0
- package/validators/stages/bucket-payload.validator.js.map +1 -0
- package/validators/stages/collStats-payload.validator.d.ts +2 -0
- package/validators/stages/collStats-payload.validator.js +23 -0
- package/validators/stages/collStats-payload.validator.js.map +1 -0
- package/validators/stages/count-payload.validator.d.ts +1 -0
- package/validators/stages/count-payload.validator.js +17 -0
- package/validators/stages/count-payload.validator.js.map +1 -0
- package/validators/stages/facet-payload.validator.d.ts +2 -0
- package/validators/stages/facet-payload.validator.js +33 -0
- package/validators/stages/facet-payload.validator.js.map +1 -0
- package/validators/stages/geoNear-payload.validator.d.ts +2 -0
- package/validators/stages/geoNear-payload.validator.js +11 -0
- package/validators/stages/geoNear-payload.validator.js.map +1 -0
- package/validators/stages/graphLookup-payload.validator.d.ts +2 -0
- package/validators/stages/graphLookup-payload.validator.js +8 -0
- package/validators/stages/graphLookup-payload.validator.js.map +1 -0
- package/validators/stages/group-payload.validator.d.ts +2 -0
- package/validators/stages/group-payload.validator.js +8 -0
- package/validators/stages/group-payload.validator.js.map +1 -0
- package/validators/stages/indexStats-payload.validator.d.ts +1 -0
- package/validators/stages/indexStats-payload.validator.js +8 -0
- package/validators/stages/indexStats-payload.validator.js.map +1 -0
- package/validators/stages/limit-payload.validator.d.ts +1 -0
- package/validators/stages/limit-payload.validator.js +8 -0
- package/validators/stages/limit-payload.validator.js.map +1 -0
- package/validators/stages/listSessions-payload.validator.d.ts +1 -0
- package/validators/stages/listSessions-payload.validator.js +8 -0
- package/validators/stages/listSessions-payload.validator.js.map +1 -0
- package/validators/stages/lookup-payload.validator.d.ts +2 -0
- package/validators/stages/lookup-payload.validator.js +33 -0
- package/validators/stages/lookup-payload.validator.js.map +1 -0
- package/validators/stages/match-payload.validator.d.ts +1 -0
- package/validators/stages/match-payload.validator.js +8 -0
- package/validators/stages/match-payload.validator.js.map +1 -0
- package/validators/stages/merge-payload.validator.d.ts +2 -0
- package/validators/stages/merge-payload.validator.js +8 -0
- package/validators/stages/merge-payload.validator.js.map +1 -0
- package/validators/stages/out-payload.validator.d.ts +2 -0
- package/validators/stages/out-payload.validator.js +8 -0
- package/validators/stages/out-payload.validator.js.map +1 -0
- package/validators/stages/planCacheStats-payload.validator.d.ts +1 -0
- package/validators/stages/planCacheStats-payload.validator.js +8 -0
- package/validators/stages/planCacheStats-payload.validator.js.map +1 -0
- package/validators/stages/project-payload.validator.d.ts +3 -0
- package/validators/stages/project-payload.validator.js +19 -0
- package/validators/stages/project-payload.validator.js.map +1 -0
- package/validators/stages/redact-payload.validator.d.ts +1 -0
- package/validators/stages/redact-payload.validator.js +8 -0
- package/validators/stages/redact-payload.validator.js.map +1 -0
- package/validators/stages/replaceRoot-payload.validator.d.ts +2 -0
- package/validators/stages/replaceRoot-payload.validator.js +8 -0
- package/validators/stages/replaceRoot-payload.validator.js.map +1 -0
- package/validators/stages/replaceWith-payload.validator.d.ts +1 -0
- package/validators/stages/replaceWith-payload.validator.js +8 -0
- package/validators/stages/replaceWith-payload.validator.js.map +1 -0
- package/validators/stages/sample-payload.validator.d.ts +2 -0
- package/validators/stages/sample-payload.validator.js +8 -0
- package/validators/stages/sample-payload.validator.js.map +1 -0
- package/validators/stages/search-payload.validator.d.ts +1 -0
- package/validators/stages/search-payload.validator.js +8 -0
- package/validators/stages/search-payload.validator.js.map +1 -0
- package/validators/stages/set-payload.validator.d.ts +3 -0
- package/validators/stages/set-payload.validator.js +19 -0
- package/validators/stages/set-payload.validator.js.map +1 -0
- package/validators/stages/skip-payload.validator.d.ts +1 -0
- package/validators/stages/skip-payload.validator.js +8 -0
- package/validators/stages/skip-payload.validator.js.map +1 -0
- package/validators/stages/sort-payload.validator.d.ts +3 -0
- package/validators/stages/sort-payload.validator.js +19 -0
- package/validators/stages/sort-payload.validator.js.map +1 -0
- package/validators/stages/sortByCount-payload.validator.d.ts +1 -0
- package/validators/stages/sortByCount-payload.validator.js +8 -0
- package/validators/stages/sortByCount-payload.validator.js.map +1 -0
- package/validators/stages/unionWith-payload.validator.d.ts +2 -0
- package/validators/stages/unionWith-payload.validator.js +8 -0
- package/validators/stages/unionWith-payload.validator.js.map +1 -0
- package/validators/stages/unset-payload.validator.d.ts +1 -0
- package/validators/stages/unset-payload.validator.js +8 -0
- package/validators/stages/unset-payload.validator.js.map +1 -0
- package/validators/stages/unwind-payload.validator.d.ts +2 -0
- package/validators/stages/unwind-payload.validator.js +8 -0
- package/validators/stages/unwind-payload.validator.js.map +1 -0
- package/validators/utils/string.validator.d.ts +4 -0
- package/validators/utils/string.validator.js +28 -0
- package/validators/utils/string.validator.js.map +1 -0
- package/validators/utils/undefined.validator.d.ts +9 -0
- package/validators/utils/undefined.validator.js +57 -0
- package/validators/utils/undefined.validator.js.map +1 -0
- package/warnings/deprecated-methods/deprecated-method-warning.d.ts +1 -0
- package/warnings/deprecated-methods/deprecated-method-warning.js +6 -0
- package/warnings/deprecated-methods/deprecated-method-warning.js.map +1 -0
- package/warnings/index.d.ts +1 -0
- package/warnings/index.js +6 -0
- package/warnings/index.js.map +1 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
|
+
|
|
5
|
+
## [3.3.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.2.3...v3.3.0) (2021-09-17)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* add the GetTotalPageNumber method to the methods that can be used when paging with the GetResult method ([c885926](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/c885926eefcaa80b641f4062d5cf9e90438130fe))
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
* correct some array operators ([6e50682](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/6e506823967a2b28cfd4e161d6a7bf1fd102e9a4))
|
|
16
|
+
|
|
17
|
+
### [3.2.3](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.2.2...v3.2.3) (2021-07-19)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Bug Fixes
|
|
21
|
+
|
|
22
|
+
* correct the path to index.js and index.d.ts files in package.json ([2ecd7a5](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/2ecd7a56462d8959b78163f697d5c576bbd39d0c))
|
|
23
|
+
|
|
24
|
+
### [3.2.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.2.1...v3.2.2) (2021-07-18)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
### Bug Fixes
|
|
28
|
+
|
|
29
|
+
* correct the value returned by the GetDocs method for a pagination result ([f83f4f0](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/f83f4f08e91c5065df1d1edb1ba79100cc231f22))
|
|
30
|
+
|
|
31
|
+
### [3.2.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.2.0...v3.2.1) (2021-07-14)
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
### Bug Fixes
|
|
35
|
+
|
|
36
|
+
* correct the interpretation of 0 as not valid when passed as an argument of the GetDocs method ([f32531d](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/f32531de6404a46270d766c2d09c927f8ffab6d5))
|
|
37
|
+
|
|
38
|
+
## [3.2.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.1.2...v3.2.0) (2021-07-11)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
### Features
|
|
42
|
+
|
|
43
|
+
* add the ability to get a particular item when using the GetDocs, increase the reliability of the pipeline parameter of the GetResult method ([ee6d745](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/ee6d7453db77898c592be025c14a80dd934e9fb3))
|
|
44
|
+
|
|
45
|
+
### [3.1.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.1.1...v3.1.2) (2021-07-09)
|
|
46
|
+
|
|
47
|
+
### [3.1.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.1.0...v3.1.1) (2021-06-08)
|
|
48
|
+
|
|
49
|
+
## [3.1.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v3.0.0...v3.1.0) (2021-06-02)
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
### Features
|
|
53
|
+
|
|
54
|
+
* add the ability to pass a single object with multiple properties in the Facet method ([8401905](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/84019059b220d1d11681d545e2411fd6bdba563b))
|
|
55
|
+
* add the possibility of testing undefined values ([9afca54](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/9afca54f5ab471236fd7710b4490ae86ee30e4eb))
|
|
56
|
+
|
|
57
|
+
## [3.0.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.7...v3.0.0) (2021-04-06)
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
### ⚠ BREAKING CHANGES
|
|
61
|
+
|
|
62
|
+
* Add the possibility of using one or more Field
|
|
63
|
+
helper(s)
|
|
64
|
+
|
|
65
|
+
* change the Facet payload ([459bf0a](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/459bf0acc89132a595653c76e74136de786a3c2f))
|
|
66
|
+
|
|
67
|
+
### [2.7.7](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.6...v2.7.7) (2021-04-06)
|
|
68
|
+
|
|
69
|
+
### [2.7.6](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.5...v2.7.6) (2021-04-05)
|
|
70
|
+
|
|
71
|
+
### [2.7.5](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.4...v2.7.5) (2021-04-05)
|
|
72
|
+
|
|
73
|
+
### [2.7.4](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.3...v2.7.4) (2021-04-05)
|
|
74
|
+
|
|
75
|
+
### [2.7.3](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.2...v2.7.3) (2021-04-01)
|
|
76
|
+
|
|
77
|
+
### [2.7.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.1...v2.7.2) (2021-04-01)
|
|
78
|
+
|
|
79
|
+
### [2.7.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.7.0...v2.7.1) (2021-04-01)
|
|
80
|
+
|
|
81
|
+
## [2.7.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.6.3-1...v2.7.0) (2021-03-30)
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
### Features
|
|
85
|
+
|
|
86
|
+
* add pipeline name decorator validation rules ([1370ea6](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/1370ea6bf90709ead9ca37d1cc3f9a01ac0c625d))
|
|
87
|
+
|
|
88
|
+
### [2.6.3-1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.6.3-0...v2.6.3-1) (2021-03-30)
|
|
89
|
+
|
|
90
|
+
### [2.6.3-0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.6.2...v2.6.3-0) (2021-03-30)
|
|
91
|
+
|
|
92
|
+
### [2.6.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.6.1...v2.6.2) (2021-03-30)
|
|
93
|
+
|
|
94
|
+
### [2.6.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.6.0...v2.6.1) (2021-03-29)
|
|
95
|
+
|
|
96
|
+
## [2.6.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.5.0...v2.6.0) (2021-03-29)
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
### Features
|
|
100
|
+
|
|
101
|
+
* add currentOp OpPayload helper ([b47c269](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/b47c269fe791b73ba678d12f176d75e66dd44939))
|
|
102
|
+
|
|
103
|
+
## [2.5.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.4.2...v2.5.0) (2021-03-26)
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
### Features
|
|
107
|
+
|
|
108
|
+
* add geoNear NearPayload helper ([9d973b0](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/9d973b0ab36e4ff6f55732713137d70f6997825f))
|
|
109
|
+
|
|
110
|
+
### [2.4.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.4.1...v2.4.2) (2021-03-24)
|
|
111
|
+
|
|
112
|
+
### [2.4.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.4.0...v2.4.1) (2021-03-24)
|
|
113
|
+
|
|
114
|
+
## [2.4.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v22.3.2...v2.4.0) (2021-03-24)
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
### Features
|
|
118
|
+
|
|
119
|
+
* add GetResult super method ([d744405](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/d744405e8da141438dbd201f47900e726037cfe7))
|
|
120
|
+
|
|
121
|
+
### [2.3.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.3.1...v2.3.2) (2021-03-23)
|
|
122
|
+
|
|
123
|
+
### [2.3.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.3.0...v2.3.1) (2021-03-23)
|
|
124
|
+
|
|
125
|
+
## [2.3.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.2.0...v2.3.0) (2021-03-23)
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
### Features
|
|
129
|
+
|
|
130
|
+
* Add a check if a Skip, Limit or Count stage is already in the pipeline ([6913cb3](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/6913cb35f730d8889ed774dd6304a4023c4d1ad2))
|
|
131
|
+
|
|
132
|
+
## [2.2.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.1.0...v2.2.0) (2021-03-23)
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
### Features
|
|
136
|
+
|
|
137
|
+
* add a Paging method that will automatically add the necessary stages to paginate the pipeline results ([f78cfb5](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/f78cfb51bef33a229d1e32b45dc4d1ac2f07f98d))
|
|
138
|
+
|
|
139
|
+
## [2.1.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.0.4...v2.1.0) (2021-03-23)
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
### Features
|
|
143
|
+
|
|
144
|
+
* add DbCollPayload helper for the Out method ([663f2bf](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/663f2bf86ec6882476bb83e3fb820ba1196396bb))
|
|
145
|
+
|
|
146
|
+
### [2.0.4](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.0.3...v2.0.4) (2021-03-22)
|
|
147
|
+
|
|
148
|
+
### [2.0.3](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.0.2...v2.0.3) (2021-03-22)
|
|
149
|
+
|
|
150
|
+
### [2.0.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.0.1...v2.0.2) (2021-03-22)
|
|
151
|
+
|
|
152
|
+
### [2.0.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v2.0.0...v2.0.1) (2021-03-22)
|
|
153
|
+
|
|
154
|
+
|
|
155
|
+
### Bug Fixes
|
|
156
|
+
|
|
157
|
+
* fix to enable debug mode by modifying import of moment.js library ([a973cb0](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/a973cb076f14686e505bc90940f869b24cce9084))
|
|
158
|
+
|
|
159
|
+
## [2.0.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v1.1.0...v2.0.0) (2021-03-22)
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
### ⚠ BREAKING CHANGES
|
|
163
|
+
|
|
164
|
+
* modify the payload arguments by adding an optional argument containing all optional payload parameters ([b258e26](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/b258e26dfdb8897ca447af036771e09f63e4b3c0))
|
|
165
|
+
|
|
166
|
+
## [1.1.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v1.0.1...v1.1.0) (2021-03-22)
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
### Features
|
|
170
|
+
|
|
171
|
+
* add merge IntoPayload helper ([91b73f1](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/91b73f1a06d983836b2afdefd91ed81d78886906))
|
|
172
|
+
|
|
173
|
+
### [1.0.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-72...v1.0.1) (2021-03-21)
|
|
174
|
+
|
|
175
|
+
## [1.0.0](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-72...v1.0.0) (2021-03-21)
|
|
176
|
+
|
|
177
|
+
### [0.0.2-72](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-71...v0.0.2-72) (2021-03-21)
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
### Features
|
|
181
|
+
|
|
182
|
+
* add bucket auto GroupByAutoPayload helper ([344b46c](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/344b46c1342988cd411585ef87f12d338cfcecac))
|
|
183
|
+
* add sample SizePayload helper ([c8d05f7](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/c8d05f7cda38fbf96c6832e697ea634e2f04f84f))
|
|
184
|
+
* add unionWith CollectionPayload helper ([938bcaa](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/938bcaad9692df2cb57dd63277056cf44a900aec))
|
|
185
|
+
|
|
186
|
+
### [0.0.2-71](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-70...v0.0.2-71) (2021-03-21)
|
|
187
|
+
|
|
188
|
+
|
|
189
|
+
### Features
|
|
190
|
+
|
|
191
|
+
* add bucket GroupByPayload helper ([03fb8d6](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/03fb8d697439b154febdc29616bd8c752d0ca70e))
|
|
192
|
+
|
|
193
|
+
### [0.0.2-70](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-69...v0.0.2-70) (2021-03-21)
|
|
194
|
+
|
|
195
|
+
### [0.0.2-69](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-68...v0.0.2-69) (2021-03-21)
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
### Bug Fixes
|
|
199
|
+
|
|
200
|
+
* github script in circleci pipeline to delete develop branch when release is ready to merge ([fd11909](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/fd11909414eb9bb0c73b6f8b002c2aa5daadfb12))
|
|
201
|
+
|
|
202
|
+
### [0.0.2-68](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-67...v0.0.2-68) (2021-03-20)
|
|
203
|
+
|
|
204
|
+
### [0.0.2-67](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-66...v0.0.2-67) (2021-03-20)
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
### Features
|
|
208
|
+
|
|
209
|
+
* add Property helper to create a javascript object ([62855da](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/62855da58b42c0da372e2009bf514c5d66638b4f))
|
|
210
|
+
* add the ability to pass an object or a list to AddFields ([9c97026](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/9c97026efe2da77a98291911fea30aa8a8a599a3))
|
|
211
|
+
|
|
212
|
+
### [0.0.2-66](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-65...v0.0.2-66) (2021-03-20)
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
### Features
|
|
216
|
+
|
|
217
|
+
* add new helper List ([8dc7919](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/8dc791950e889f972941f6f152f0c38dd915ccf2))
|
|
218
|
+
|
|
219
|
+
### [0.0.2-65](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-64...v0.0.2-65) (2021-03-20)
|
|
220
|
+
|
|
221
|
+
### [0.0.2-64](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-63...v0.0.2-64) (2021-03-20)
|
|
222
|
+
|
|
223
|
+
### [0.0.2-63](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-62...v0.0.2-63) (2021-03-20)
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
### Features
|
|
227
|
+
|
|
228
|
+
* add payload validator ([6c243e1](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/6c243e1fe4a3c38af469371d3423649c598022fa))
|
|
229
|
+
* implement all the stage methods as an alias of the addStage method ([b4066e0](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/b4066e0bd8bfba11780134ce22d5c0a706a4bfd9))
|
|
230
|
+
|
|
231
|
+
### [0.0.2-62](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-61...v0.0.2-62) (2021-03-19)
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
### Features
|
|
235
|
+
|
|
236
|
+
* implement Lookup, Match and Project method of the pipeline builder ([9b859cf](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/9b859cf72b0847bd632f6bb66ebde952854e5c65))
|
|
237
|
+
|
|
238
|
+
### [0.0.2-61](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-60...v0.0.2-61) (2021-03-19)
|
|
239
|
+
|
|
240
|
+
### [0.0.2-60](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-59...v0.0.2-60) (2021-03-19)
|
|
241
|
+
|
|
242
|
+
### [0.0.2-59](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-58...v0.0.2-59) (2021-03-18)
|
|
243
|
+
|
|
244
|
+
### [0.0.2-58](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-56...v0.0.2-58) (2021-03-18)
|
|
245
|
+
|
|
246
|
+
### [0.0.2-56](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-55...v0.0.2-56) (2021-03-18)
|
|
247
|
+
|
|
248
|
+
### [0.0.2-55](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-54...v0.0.2-55) (2021-03-18)
|
|
249
|
+
|
|
250
|
+
### [0.0.2-54](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-53...v0.0.2-54) (2021-03-18)
|
|
251
|
+
|
|
252
|
+
### [0.0.2-53](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-52...v0.0.2-53) (2021-03-18)
|
|
253
|
+
|
|
254
|
+
### [0.0.2-52](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-51...v0.0.2-52) (2021-03-18)
|
|
255
|
+
|
|
256
|
+
### [0.0.2-51](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-50...v0.0.2-51) (2021-03-18)
|
|
257
|
+
|
|
258
|
+
### [0.0.2-50](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-49...v0.0.2-50) (2021-03-18)
|
|
259
|
+
|
|
260
|
+
### [0.0.2-49](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-48...v0.0.2-49) (2021-03-18)
|
|
261
|
+
|
|
262
|
+
### [0.0.2-48](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-47...v0.0.2-48) (2021-03-18)
|
|
263
|
+
|
|
264
|
+
### [0.0.2-47](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-46...v0.0.2-47) (2021-03-18)
|
|
265
|
+
|
|
266
|
+
### [0.0.2-46](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-45...v0.0.2-46) (2021-03-18)
|
|
267
|
+
|
|
268
|
+
### [0.0.2-45](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-44...v0.0.2-45) (2021-03-18)
|
|
269
|
+
|
|
270
|
+
### [0.0.2-44](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-43...v0.0.2-44) (2021-03-18)
|
|
271
|
+
|
|
272
|
+
### [0.0.2-43](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-42...v0.0.2-43) (2021-03-18)
|
|
273
|
+
|
|
274
|
+
### [0.0.2-42](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-41...v0.0.2-42) (2021-03-18)
|
|
275
|
+
|
|
276
|
+
### [0.0.2-41](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-40...v0.0.2-41) (2021-03-18)
|
|
277
|
+
|
|
278
|
+
### [0.0.2-40](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-39...v0.0.2-40) (2021-03-18)
|
|
279
|
+
|
|
280
|
+
### [0.0.2-39](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-38...v0.0.2-39) (2021-03-17)
|
|
281
|
+
|
|
282
|
+
### [0.0.2-38](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-37...v0.0.2-38) (2021-03-17)
|
|
283
|
+
|
|
284
|
+
### [0.0.2-37](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-36...v0.0.2-37) (2021-03-17)
|
|
285
|
+
|
|
286
|
+
### [0.0.2-36](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-35...v0.0.2-36) (2021-03-17)
|
|
287
|
+
|
|
288
|
+
### [0.0.2-35](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-34...v0.0.2-35) (2021-03-17)
|
|
289
|
+
|
|
290
|
+
### [0.0.2-34](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-33...v0.0.2-34) (2021-03-17)
|
|
291
|
+
|
|
292
|
+
### [0.0.2-33](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-32...v0.0.2-33) (2021-03-17)
|
|
293
|
+
|
|
294
|
+
### [0.0.2-32](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-31...v0.0.2-32) (2021-03-17)
|
|
295
|
+
|
|
296
|
+
### [0.0.2-31](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-30...v0.0.2-31) (2021-03-17)
|
|
297
|
+
|
|
298
|
+
### [0.0.2-30](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-29...v0.0.2-30) (2021-03-17)
|
|
299
|
+
|
|
300
|
+
### [0.0.2-29](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-28...v0.0.2-29) (2021-03-17)
|
|
301
|
+
|
|
302
|
+
### [0.0.2-28](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-27...v0.0.2-28) (2021-03-17)
|
|
303
|
+
|
|
304
|
+
### [0.0.2-27](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-26...v0.0.2-27) (2021-03-17)
|
|
305
|
+
|
|
306
|
+
### [0.0.2-26](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-25...v0.0.2-26) (2021-03-17)
|
|
307
|
+
|
|
308
|
+
### [0.0.2-25](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-24...v0.0.2-25) (2021-03-17)
|
|
309
|
+
|
|
310
|
+
### [0.0.2-24](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-23...v0.0.2-24) (2021-03-17)
|
|
311
|
+
|
|
312
|
+
### [0.0.2-23](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-22...v0.0.2-23) (2021-03-17)
|
|
313
|
+
|
|
314
|
+
### [0.0.2-22](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-21...v0.0.2-22) (2021-03-17)
|
|
315
|
+
|
|
316
|
+
### [0.0.2-21](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-20...v0.0.2-21) (2021-03-17)
|
|
317
|
+
|
|
318
|
+
### [0.0.2-20](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-19...v0.0.2-20) (2021-03-17)
|
|
319
|
+
|
|
320
|
+
### [0.0.2-19](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-18...v0.0.2-19) (2021-03-17)
|
|
321
|
+
|
|
322
|
+
### [0.0.2-18](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-17...v0.0.2-18) (2021-03-17)
|
|
323
|
+
|
|
324
|
+
### [0.0.2-17](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-16...v0.0.2-17) (2021-03-17)
|
|
325
|
+
|
|
326
|
+
### [0.0.2-16](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-15...v0.0.2-16) (2021-03-17)
|
|
327
|
+
|
|
328
|
+
### [0.0.2-15](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-14...v0.0.2-15) (2021-03-17)
|
|
329
|
+
|
|
330
|
+
### [0.0.2-14](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-13...v0.0.2-14) (2021-03-17)
|
|
331
|
+
|
|
332
|
+
### [0.0.2-13](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-12...v0.0.2-13) (2021-03-17)
|
|
333
|
+
|
|
334
|
+
### [0.0.2-12](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-11...v0.0.2-12) (2021-03-17)
|
|
335
|
+
|
|
336
|
+
### [0.0.2-11](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-10...v0.0.2-11) (2021-03-17)
|
|
337
|
+
|
|
338
|
+
### [0.0.2-10](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.7...v0.0.2-10) (2021-03-17)
|
|
339
|
+
|
|
340
|
+
|
|
341
|
+
### Bug Fixes
|
|
342
|
+
|
|
343
|
+
* change import moment to require moment ([826ac37](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/826ac37b36f2d9bc2bfb9f2f98b349a78799554c))
|
|
344
|
+
|
|
345
|
+
### [0.0.2-alpha.7](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.5...v0.0.2-alpha.7) (2021-03-16)
|
|
346
|
+
|
|
347
|
+
### [0.0.2-alpha.5](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.4...v0.0.2-alpha.5) (2021-03-16)
|
|
348
|
+
|
|
349
|
+
### [0.0.2-alpha.4](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.3...v0.0.2-alpha.4) (2021-03-16)
|
|
350
|
+
|
|
351
|
+
### [0.0.2-alpha.3](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.2...v0.0.2-alpha.3) (2021-03-16)
|
|
352
|
+
|
|
353
|
+
|
|
354
|
+
### Bug Fixes
|
|
355
|
+
|
|
356
|
+
* build script ([281fb81](https://github.com/MikeDev75015/mongodb-pipeline-builder/commit/281fb81632b222a19ef0cbdbe22748a7e6fafe81))
|
|
357
|
+
|
|
358
|
+
### [0.0.2-alpha.2](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.1...v0.0.2-alpha.2) (2021-03-16)
|
|
359
|
+
|
|
360
|
+
### [0.0.2-alpha.1](https://github.com/MikeDev75015/mongodb-pipeline-builder/compare/v0.0.2-alpha.0...v0.0.2-alpha.1) (2021-03-16)
|
|
361
|
+
|
|
362
|
+
### 0.0.2-alpha.0 (2021-03-15)
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2021 Mickael Nodanche
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/Readme.md
ADDED
|
@@ -0,0 +1,280 @@
|
|
|
1
|
+
<div style="text-align: center; width: 100%;">
|
|
2
|
+
|
|
3
|
+
<div style="display: inline-block">
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/mongodb-pipeline-builder)
|
|
6
|
+

|
|
7
|
+

|
|
8
|
+
</div>
|
|
9
|
+
|
|
10
|
+
<div style="display: inline-block">
|
|
11
|
+
|
|
12
|
+

|
|
13
|
+
[](https://app.circleci.com/pipelines/github/MikeDev75015/mongodb-pipeline-builder)
|
|
14
|
+

|
|
15
|
+
</div>
|
|
16
|
+
</div>
|
|
17
|
+
|
|
18
|
+
<div style="text-align: center; width: 100%;">
|
|
19
|
+
<div style="display: inline-block">
|
|
20
|
+
|
|
21
|
+

|
|
22
|
+

|
|
23
|
+
<img src="https://mikedev75015.github.io/mongodb-pipeline-builder/images/coverage-badge-documentation.svg" alt="documentation-badge">
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
<div style="display: inline-block">
|
|
27
|
+
|
|
28
|
+

|
|
29
|
+
[](https://sonarcloud.io/dashboard?id=MikeDev75015_mongodb-pipeline-builder)
|
|
30
|
+
[](https://sonarcloud.io/dashboard?id=MikeDev75015_mongodb-pipeline-builder)
|
|
31
|
+
</div>
|
|
32
|
+
</div>
|
|
33
|
+
|
|
34
|
+
<div style="text-align: center; width: 100%;">
|
|
35
|
+
<div style="display: inline-block">
|
|
36
|
+
|
|
37
|
+

|
|
38
|
+

|
|
39
|
+

|
|
40
|
+
</div>
|
|
41
|
+
|
|
42
|
+
<div style="display: inline-block">
|
|
43
|
+
|
|
44
|
+
[](https://sonarcloud.io/dashboard?id=MikeDev75015_mongodb-pipeline-builder)
|
|
45
|
+
[](https://sonarcloud.io/dashboard?id=MikeDev75015_mongodb-pipeline-builder)
|
|
46
|
+
[](https://sonarcloud.io/dashboard?id=MikeDev75015_mongodb-pipeline-builder)
|
|
47
|
+
</div>
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
<div style="text-align: center; width: 100%;">
|
|
51
|
+
|
|
52
|
+
# `mongodb-pipeline-builder`
|
|
53
|
+
|
|
54
|
+
</div>
|
|
55
|
+
|
|
56
|
+
<a id="doc-link" style="display: block; cursor: pointer;" href="https://mikedev75015.github.io/mongodb-pipeline-builder" target="_blank">Technical documentation</a>
|
|
57
|
+
|
|
58
|
+
<p style="text-align: justify; width: 100%;font-size: 15px;">
|
|
59
|
+
is a pipeline builder for the db.collection.aggregate method and db.aggregate method. It will simplify pipelines by making them more
|
|
60
|
+
readable and much easier to edit. It also allows you to test your pipelines on a dataset in order to verify them. Pipeline stages appear in an array. Documents pass
|
|
61
|
+
through the stages in sequence.
|
|
62
|
+
</p>
|
|
63
|
+
|
|
64
|
+
## npm package <img src="https://pbs.twimg.com/media/EDoWJbUXYAArclg.png" width="24" height="24" />
|
|
65
|
+
|
|
66
|
+
### `npm i -S mongodb-pipeline-builder`
|
|
67
|
+
|
|
68
|
+
## Usage:
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
### - with require
|
|
72
|
+
|
|
73
|
+
```typescript
|
|
74
|
+
const PipelineBuilder = require("mongodb-pipeline-builder").PipelineBuilder;
|
|
75
|
+
const { EqualityPayload, OnlyPayload, Field } = require('mongodb-pipeline-builder/helpers');
|
|
76
|
+
const { LessThanEqual, ArrayElemAt, Equal, Expression } = require('mongodb-pipeline-builder/operators');
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
### - with import
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
```typescript
|
|
83
|
+
import { PipelineBuilder } from 'mongodb-pipeline-builder';
|
|
84
|
+
import { EqualityPayload, OnlyPayload, Field } from 'mongodb-pipeline-builder/helpers';
|
|
85
|
+
import { LessThanEqual, ArrayElemAt, Equal, Expression } from 'mongodb-pipeline-builder/operators';
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
## Example with paging:
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
```typescript
|
|
92
|
+
const myNewPipeline = new PipelineBuilder( 'myPagination', { debug: true } )
|
|
93
|
+
.Match( Expression( LessThanEqual( '$id', 20 ) ) )
|
|
94
|
+
.Project( OnlyPayload( 'name', 'weight' ) )
|
|
95
|
+
.Paging( 5, 3 ) // 5 per page, page 3
|
|
96
|
+
.getPipeline();
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
### is equivalent to:
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
```typescript
|
|
103
|
+
const myNewPipeline = [ {
|
|
104
|
+
$facet: {
|
|
105
|
+
docs: [
|
|
106
|
+
{ $match: { $expr: { $lte: ["$id", 20] } } },
|
|
107
|
+
{ $project: { _id: 0, name: 1, weight: 1 } },
|
|
108
|
+
{ $skip: 10 },
|
|
109
|
+
{ $limit: 5 }
|
|
110
|
+
],
|
|
111
|
+
count: [
|
|
112
|
+
{ $match: { $expr: { $lte: ["$id", 20] } } },
|
|
113
|
+
{ $project: { _id: 0, name: 1, weight: 1 } },
|
|
114
|
+
{ $count: "totalElements" }
|
|
115
|
+
]
|
|
116
|
+
}
|
|
117
|
+
} ];
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
## Example without paging:
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
```typescript
|
|
124
|
+
const myNewPipeline = new PipelineBuilder( 'user-skills' )
|
|
125
|
+
.Match( Expression( Equal( '$id', 123456 ) ) )
|
|
126
|
+
.Lookup( EqualityPayload( 'profiles', 'profile', 'profileId', 'id' ) )
|
|
127
|
+
.Project( OnlyPayload( 'firstname', 'lastname', 'email' ) )
|
|
128
|
+
.AddFields(
|
|
129
|
+
Field( 'skills', ArrayElemAt( '$profile.skills', 0 ) ),
|
|
130
|
+
Field( 'availability', ArrayElemAt( '$profile.availability', 0 ) )
|
|
131
|
+
)
|
|
132
|
+
.Unset( 'profile' )
|
|
133
|
+
.getPipeline();
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
### is equivalent to:
|
|
137
|
+
|
|
138
|
+
```typescript
|
|
139
|
+
const myNewPipeline = [
|
|
140
|
+
{ $match: { $expr: { $eq: ["$id", 123456] } } },
|
|
141
|
+
{ $lookup: { from: "profiles", as: "profile", localField: "profileId", foreignField: "id" } },
|
|
142
|
+
{ $project: { _id: 0, firstname: 1, lastname: 1, email: 1 } },
|
|
143
|
+
{ $addFields: {
|
|
144
|
+
skills: { $arrayElemAt: ["$profile.skills", 0] },
|
|
145
|
+
availability: { $arrayElemAt: ["$profile.availability", 0] }
|
|
146
|
+
} },
|
|
147
|
+
{ $unset: "profile" }
|
|
148
|
+
];
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
___
|
|
152
|
+
|
|
153
|
+
# The GetResult method
|
|
154
|
+
#### GetResult(): Promise<GetResultResponse | GetPagingResultResponse>
|
|
155
|
+
|
|
156
|
+
<p style="font-size: 15px;">
|
|
157
|
+
is an asynchronous method that provides a very easy way to use your aggregation pipelines on a target (collection or mongoose model having the aggregation method) with pagination or without.
|
|
158
|
+
<p>
|
|
159
|
+
|
|
160
|
+
## GetResultResponse
|
|
161
|
+
|
|
162
|
+
<p style="font-size: 15px;">
|
|
163
|
+
When you are not using pagination, the GetResult method returns a GetResultResponse object that contains two methods:<br>
|
|
164
|
+
- GetDocs() to get the documents found.<br>
|
|
165
|
+
- GetCount() to get the total number of documents found.
|
|
166
|
+
</p>
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
```typescript
|
|
170
|
+
// in an asynchronous function
|
|
171
|
+
const result = await GetResult( target, pipeline );
|
|
172
|
+
result.GetDocs(); // => any[]
|
|
173
|
+
result.GetCount(); // => number
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
#### Or:
|
|
177
|
+
```typescript
|
|
178
|
+
GetResult( target, pipeline ).then( result => {
|
|
179
|
+
result.GetDocs(); // => any[]
|
|
180
|
+
result.GetCount(); // => number
|
|
181
|
+
} );
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
### GetDocs() method possibilities:
|
|
185
|
+
|
|
186
|
+
<p style="font-size: 15px;">
|
|
187
|
+
You can retrieve a particular document by specifying its index as an argument of the GetDocs method.<br>Just pass "last" to get the last document. If the specified index is greater than the index of the last document, GetDocs() will return the last document.
|
|
188
|
+
</p>
|
|
189
|
+
|
|
190
|
+
```typescript
|
|
191
|
+
// if GetDocs() returns [document0, document1, document2, document3, ..., document51]
|
|
192
|
+
result.GetDocs(2); // will return document to index 2, document2
|
|
193
|
+
result.GetDocs('last'); // will return the last document, document51
|
|
194
|
+
result.GetDocs(99); // will return the last document, document51
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
## GetPagingResultResponse
|
|
198
|
+
|
|
199
|
+
<p style="font-size: 15px;">
|
|
200
|
+
When you use paging, the GetResult method returns a GetPagingResultResponse object that contains three methods:<br>
|
|
201
|
+
- GetDocs() to get the documents found.<br>
|
|
202
|
+
- GetCount() to get the total number of documents found.<br>
|
|
203
|
+
- GetTotalPageNumber() to get the total number of pages.
|
|
204
|
+
</p>
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
```typescript
|
|
208
|
+
// in an asynchronous function
|
|
209
|
+
const result = await GetResult( target, pipeline );
|
|
210
|
+
result.GetDocs(); // => any[]
|
|
211
|
+
result.GetCount(); // => number
|
|
212
|
+
result.GetTotalPageNumber(); // => number
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
#### Or:
|
|
216
|
+
```typescript
|
|
217
|
+
GetResult( target, pipeline ).then( result => {
|
|
218
|
+
result.GetDocs(); // => any[]
|
|
219
|
+
result.GetCount(); // => number
|
|
220
|
+
result.GetTotalPageNumber(); // => number
|
|
221
|
+
} );
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
___
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
### [ <a href="https://npm.runkit.com/mongodb-pipeline-builder" target="_blank">Try the lib on NPM RunKit with the require method</a> ]<br>
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
<p style="font-size: 14px; white-space: nowrap;">[ <a href="https://docs.mongodb.com/manual/reference/operator/aggregation-pipeline/" target="_blank">Aggregation Pipeline Stages</a> ]</p>
|
|
232
|
+
|
|
233
|
+
## `MONGODB STAGES:`
|
|
234
|
+
<p style="font-size: 15px;">
|
|
235
|
+
AddFields | Bucket | BucketAuto | CollStats | Count | Facet | GeoNear | GraphLookup | Group | IndexStats | Limit | ListSessions | Lookup | Match | Merge | Out | PlanCacheStats | Project | Redact | ReplaceRoot | ReplaceWith | Sample | Search | Set | Skip | Sort | SortByCount | UnionWith | Unset | Unwind
|
|
236
|
+
</p>
|
|
237
|
+
|
|
238
|
+
## `CUSTOM STAGE:`
|
|
239
|
+
<p style="font-size: 15px;">
|
|
240
|
+
Paging
|
|
241
|
+
</p>
|
|
242
|
+
|
|
243
|
+
___
|
|
244
|
+
|
|
245
|
+
<p style="font-size: 14px; white-space: nowrap;">[ <a href="https://docs.mongodb.com/manual/reference/operator/aggregation-pipeline/" target="_blank">Aggregation Pipeline Helpers</a> ]</p>
|
|
246
|
+
|
|
247
|
+
## `STAGE HELPERS * :`
|
|
248
|
+
<p style="font-size: 15px;">
|
|
249
|
+
- Bucket ( GroupByPayload )<br>
|
|
250
|
+
- BucketAuto ( GroupByAutoPayload )<br>
|
|
251
|
+
- CurrentOp ( OpPayload )<br>
|
|
252
|
+
- GeoNear ( NearPayload )<br>
|
|
253
|
+
- Lookup ( ConditionPayload | EqualityPayload )<br>
|
|
254
|
+
- Merge ( IntoPayload )<br>
|
|
255
|
+
- Out ( DbCollPayload )<br>
|
|
256
|
+
- Project ( IgnorePayload | OnlyPayload )<br>
|
|
257
|
+
- Sample ( SizePayload )<br>
|
|
258
|
+
- UnionWith ( CollectionPayload )
|
|
259
|
+
|
|
260
|
+
## `COMMON HELPERS:`
|
|
261
|
+
<p style="font-size: 15px;">
|
|
262
|
+
- Field: AddFields( Field ** ) | Facet( Field ** ) | Set( Field ** ) | Sort( Field ** )<br>
|
|
263
|
+
- List
|
|
264
|
+
<p>
|
|
265
|
+
|
|
266
|
+
<p style="font-style: italic">
|
|
267
|
+
* If no helper is available for a stage, use stage method and pass it a valid value as a parameter.<br>
|
|
268
|
+
** One or more Field helper(s) separated by a comma.
|
|
269
|
+
|
|
270
|
+
___
|
|
271
|
+
|
|
272
|
+
<p style="font-size: 14px; white-space: nowrap;">[ <a href="https://docs.mongodb.com/manual/reference/operator/aggregation/" target="_blank">Aggregation Pipeline Operators</a> ]</p>
|
|
273
|
+
|
|
274
|
+
<p style="font-size: 15px;">
|
|
275
|
+
Absolute | Accumulator | Acos | Acosh | Add | AddToSet | AllElementsTrue | And | AnyElementTrue | ArrayElemAt | ArrayToObject | Asin | Asinh | Atan | Atan2 | Atanh | Avg | BinarySize | BsonSize | Ceil | Compare | Concat | ConcatArrays | Cond | Convert | Cos | Cosh | DateFromParts | DateFromString | DateToParts | DateToString | DayOfMonth | DayOfWeek | DayOfYear | DegreesToRadians | Divide | Equal | Exponent | Expression | Filter | First | Floor | FunctionOperator | GreaterThan | GreaterThanEqual | Hour | IfNull | In | IndexOfArray | IndexOfBytes | IndexOfCP | IsArray | IsNumber | IsoDayOfWeek | IsoWeek | IsoWeekYear | Last | LessThan | LessThanEqual | Let | Literal | Log | Log10 | Ltrim | MapOperator | Max | MergeObjects | Meta | Millisecond | Min | Minute | Mod | Month | Multiply | NaturalLog | Not | NotEqual | ObjectToArray | Or | Pow | Push | RadiansToDegrees | Rand | Range | Reduce | RegexFind | RegexFindAll | RegexMatch | ReplaceAll | ReplaceOne | ReverseArray | Round | Rtrim | SampleRate | Second | SetDifference | SetEquals | SetIntersection | SetIsSubset | SetUnion | Sin | Sinh | Size | Slice | Split | Sqrt | StdDevPop | StdDevSamp | StrCaseCmp | StrLenBytes | StrLenCP | Substr | SubstrBytes | SubstrCP | Subtract | Sum | Switch | Tan | Tanh | ToBool | ToDate | ToDecimal | ToDouble | ToInt | ToLong | ToLower | ToObjectId | ToString | ToUpper | Trim | Trunc | Type | Week | Year | Zip
|
|
276
|
+
</p>
|
|
277
|
+
<br><br><br><br>
|
|
278
|
+
|
|
279
|
+
|
|
280
|
+
|