breeze-client 2.1.3 → 2.1.4-mjs
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -5
- package/adapter-ajax-angularjs/{breeze-client-adapter-ajax-angularjs.d.ts → index.d.ts} +1 -0
- package/adapter-ajax-fetch/{breeze-client-adapter-ajax-fetch.d.ts → index.d.ts} +1 -0
- package/adapter-ajax-httpclient/{breeze-client-adapter-ajax-httpclient.d.ts → index.d.ts} +1 -0
- package/adapter-ajax-jquery/{breeze-client-adapter-ajax-jquery.d.ts → index.d.ts} +1 -0
- package/adapter-ajax-post/{breeze-client-adapter-ajax-post.d.ts → index.d.ts} +1 -0
- package/adapter-data-service-odata/{breeze-client-adapter-data-service-odata.d.ts → index.d.ts} +1 -0
- package/adapter-data-service-webapi/{breeze-client-adapter-data-service-webapi.d.ts → index.d.ts} +1 -0
- package/adapter-model-library-backing-store/{breeze-client-adapter-model-library-backing-store.d.ts → index.d.ts} +1 -0
- package/adapter-model-library-ko/{breeze-client-adapter-model-library-ko.d.ts → index.d.ts} +1 -0
- package/adapter-uri-builder-json/{breeze-client-adapter-uri-builder-json.d.ts → index.d.ts} +1 -0
- package/adapter-uri-builder-odata/{breeze-client-adapter-uri-builder-odata.d.ts → index.d.ts} +1 -0
- package/esm2020/adapter-ajax-angularjs/adapter-ajax-angularjs.mjs +130 -0
- package/esm2020/adapter-ajax-angularjs/adapter-core.mjs +49 -0
- package/esm2020/adapter-ajax-angularjs/breeze-client-adapter-ajax-angularjs.mjs +5 -0
- package/esm2020/adapter-ajax-fetch/adapter-ajax-fetch.mjs +132 -0
- package/esm2020/adapter-ajax-fetch/adapter-core.mjs +49 -0
- package/esm2020/adapter-ajax-fetch/breeze-client-adapter-ajax-fetch.mjs +5 -0
- package/esm2020/adapter-ajax-httpclient/adapter-ajax-httpclient.mjs +137 -0
- package/esm2020/adapter-ajax-httpclient/adapter-core.mjs +49 -0
- package/esm2020/adapter-ajax-httpclient/breeze-client-adapter-ajax-httpclient.mjs +5 -0
- package/esm2020/adapter-ajax-jquery/adapter-ajax-jquery.mjs +103 -0
- package/esm2020/adapter-ajax-jquery/breeze-client-adapter-ajax-jquery.mjs +5 -0
- package/esm2020/adapter-ajax-post/adapter-ajax-post.mjs +77 -0
- package/esm2020/adapter-ajax-post/breeze-client-adapter-ajax-post.mjs +5 -0
- package/esm2020/adapter-data-service-odata/adapter-core.mjs +49 -0
- package/esm2020/adapter-data-service-odata/adapter-data-service-odata.mjs +456 -0
- package/esm2020/adapter-data-service-odata/breeze-client-adapter-data-service-odata.mjs +5 -0
- package/esm2020/adapter-data-service-webapi/adapter-data-service-webapi.mjs +93 -0
- package/esm2020/adapter-data-service-webapi/breeze-client-adapter-data-service-webapi.mjs +5 -0
- package/esm2020/adapter-model-library-backing-store/adapter-model-library-backing-store.mjs +268 -0
- package/esm2020/adapter-model-library-backing-store/breeze-client-adapter-model-library-backing-store.mjs +5 -0
- package/esm2020/adapter-model-library-ko/adapter-model-library-ko.mjs +240 -0
- package/esm2020/adapter-model-library-ko/breeze-client-adapter-model-library-ko.mjs +5 -0
- package/esm2020/adapter-uri-builder-json/adapter-core.mjs +49 -0
- package/esm2020/adapter-uri-builder-json/adapter-uri-builder-json.mjs +36 -0
- package/esm2020/adapter-uri-builder-json/breeze-client-adapter-uri-builder-json.mjs +5 -0
- package/esm2020/adapter-uri-builder-odata/adapter-core.mjs +49 -0
- package/esm2020/adapter-uri-builder-odata/adapter-uri-builder-odata.mjs +190 -0
- package/esm2020/adapter-uri-builder-odata/breeze-client-adapter-uri-builder-odata.mjs +5 -0
- package/esm2020/breeze-client.mjs +5 -0
- package/esm2020/index.mjs +2 -0
- package/esm2020/mixin-get-entity-graph/breeze-client-mixin-get-entity-graph.mjs +5 -0
- package/esm2020/mixin-get-entity-graph/mixin-get-entity-graph.mjs +269 -0
- package/esm2020/mixin-save-queuing/breeze-client-mixin-save-queuing.mjs +5 -0
- package/esm2020/mixin-save-queuing/mixin-save-queuing.mjs +400 -0
- package/esm2020/src/abstract-data-service-adapter.mjs +296 -0
- package/esm2020/src/array.mjs +4 -0
- package/esm2020/src/assert-param.mjs +312 -0
- package/esm2020/src/breeze.mjs +85 -0
- package/esm2020/src/complex-array.mjs +117 -0
- package/esm2020/src/config.mjs +223 -0
- package/esm2020/src/core.mjs +707 -0
- package/esm2020/src/csdl-metadata-parser.mjs +385 -0
- package/esm2020/src/data-service.mjs +203 -0
- package/esm2020/src/data-type.mjs +444 -0
- package/esm2020/src/default-property-interceptor.mjs +460 -0
- package/esm2020/src/entity-action.mjs +45 -0
- package/esm2020/src/entity-aspect.mjs +806 -0
- package/esm2020/src/entity-group.mjs +187 -0
- package/esm2020/src/entity-key.mjs +116 -0
- package/esm2020/src/entity-manager.mjs +2094 -0
- package/esm2020/src/entity-metadata.mjs +2109 -0
- package/esm2020/src/entity-query.mjs +996 -0
- package/esm2020/src/entity-state.mjs +99 -0
- package/esm2020/src/enum.mjs +141 -0
- package/esm2020/src/event.mjs +256 -0
- package/esm2020/src/interface-registry.mjs +41 -0
- package/esm2020/src/key-generator.mjs +108 -0
- package/esm2020/src/local-query-comparison-options.mjs +65 -0
- package/esm2020/src/mapping-context.mjs +405 -0
- package/esm2020/src/naming-convention.mjs +88 -0
- package/esm2020/src/observable-array.mjs +183 -0
- package/esm2020/src/predicate.mjs +1232 -0
- package/esm2020/src/primitive-array.mjs +85 -0
- package/esm2020/src/query-options.mjs +152 -0
- package/esm2020/src/relation-array.mjs +173 -0
- package/esm2020/src/save-options.mjs +41 -0
- package/esm2020/src/unattached-children-map.mjs +58 -0
- package/esm2020/src/validate.mjs +988 -0
- package/esm2020/src/validation-options.mjs +64 -0
- package/fesm2015/{breeze-client-adapter-ajax-angularjs.js → breeze-client-adapter-ajax-angularjs.mjs} +2 -1
- package/fesm2015/breeze-client-adapter-ajax-angularjs.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-ajax-fetch.js → breeze-client-adapter-ajax-fetch.mjs} +6 -3
- package/fesm2015/breeze-client-adapter-ajax-fetch.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-ajax-httpclient.js → breeze-client-adapter-ajax-httpclient.mjs} +2 -1
- package/fesm2015/breeze-client-adapter-ajax-httpclient.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-ajax-jquery.js → breeze-client-adapter-ajax-jquery.mjs} +3 -2
- package/fesm2015/breeze-client-adapter-ajax-jquery.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-ajax-post.js → breeze-client-adapter-ajax-post.mjs} +2 -1
- package/fesm2015/breeze-client-adapter-ajax-post.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-data-service-odata.js → breeze-client-adapter-data-service-odata.mjs} +21 -22
- package/fesm2015/breeze-client-adapter-data-service-odata.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-data-service-webapi.js → breeze-client-adapter-data-service-webapi.mjs} +14 -13
- package/fesm2015/breeze-client-adapter-data-service-webapi.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-model-library-backing-store.js → breeze-client-adapter-model-library-backing-store.mjs} +14 -13
- package/fesm2015/breeze-client-adapter-model-library-backing-store.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-model-library-ko.js → breeze-client-adapter-model-library-ko.mjs} +14 -13
- package/fesm2015/breeze-client-adapter-model-library-ko.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-uri-builder-json.js → breeze-client-adapter-uri-builder-json.mjs} +9 -8
- package/fesm2015/breeze-client-adapter-uri-builder-json.mjs.map +1 -0
- package/fesm2015/{breeze-client-adapter-uri-builder-odata.js → breeze-client-adapter-uri-builder-odata.mjs} +86 -86
- package/fesm2015/breeze-client-adapter-uri-builder-odata.mjs.map +1 -0
- package/fesm2015/{breeze-client-mixin-get-entity-graph.js → breeze-client-mixin-get-entity-graph.mjs} +2 -1
- package/fesm2015/breeze-client-mixin-get-entity-graph.mjs.map +1 -0
- package/fesm2015/{breeze-client-mixin-save-queuing.js → breeze-client-mixin-save-queuing.mjs} +2 -1
- package/fesm2015/breeze-client-mixin-save-queuing.mjs.map +1 -0
- package/fesm2015/{breeze-client.js → breeze-client.mjs} +409 -418
- package/fesm2015/breeze-client.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-ajax-angularjs.js → fesm2020/breeze-client-adapter-ajax-angularjs.mjs} +42 -42
- package/fesm2020/breeze-client-adapter-ajax-angularjs.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-ajax-fetch.js → fesm2020/breeze-client-adapter-ajax-fetch.mjs} +45 -43
- package/fesm2020/breeze-client-adapter-ajax-fetch.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-ajax-httpclient.js → fesm2020/breeze-client-adapter-ajax-httpclient.mjs} +44 -44
- package/fesm2020/breeze-client-adapter-ajax-httpclient.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-ajax-jquery.js → fesm2020/breeze-client-adapter-ajax-jquery.mjs} +19 -19
- package/fesm2020/breeze-client-adapter-ajax-jquery.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-ajax-post.js → fesm2020/breeze-client-adapter-ajax-post.mjs} +9 -11
- package/fesm2020/breeze-client-adapter-ajax-post.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-data-service-odata.js → fesm2020/breeze-client-adapter-data-service-odata.mjs} +127 -134
- package/fesm2020/breeze-client-adapter-data-service-odata.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-data-service-webapi.js → fesm2020/breeze-client-adapter-data-service-webapi.mjs} +39 -42
- package/fesm2020/breeze-client-adapter-data-service-webapi.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-model-library-backing-store.js → fesm2020/breeze-client-adapter-model-library-backing-store.mjs} +64 -64
- package/fesm2020/breeze-client-adapter-model-library-backing-store.mjs.map +1 -0
- package/{fesm5/breeze-client-adapter-model-library-ko.js → fesm2020/breeze-client-adapter-model-library-ko.mjs} +58 -58
- package/fesm2020/breeze-client-adapter-model-library-ko.mjs.map +1 -0
- package/fesm2020/breeze-client-adapter-uri-builder-json.mjs +92 -0
- package/fesm2020/breeze-client-adapter-uri-builder-json.mjs.map +1 -0
- package/fesm2020/breeze-client-adapter-uri-builder-odata.mjs +246 -0
- package/fesm2020/breeze-client-adapter-uri-builder-odata.mjs.map +1 -0
- package/{fesm5/breeze-client-mixin-get-entity-graph.js → fesm2020/breeze-client-mixin-get-entity-graph.mjs} +46 -45
- package/fesm2020/breeze-client-mixin-get-entity-graph.mjs.map +1 -0
- package/{fesm5/breeze-client-mixin-save-queuing.js → fesm2020/breeze-client-mixin-save-queuing.mjs} +117 -126
- package/fesm2020/breeze-client-mixin-save-queuing.mjs.map +1 -0
- package/{fesm5/breeze-client.js → fesm2020/breeze-client.mjs} +3396 -3612
- package/fesm2020/breeze-client.mjs.map +1 -0
- package/mixin-get-entity-graph/{breeze-client-mixin-get-entity-graph.d.ts → index.d.ts} +1 -0
- package/mixin-save-queuing/{breeze-client-mixin-save-queuing.d.ts → index.d.ts} +1 -0
- package/mjs/README.md +17 -0
- package/package.json +125 -11
- package/src/entity-metadata.d.ts +6 -4
- package/src/entity-query.d.ts +1 -1
- package/adapter-ajax-angularjs/breeze-client-adapter-ajax-angularjs.metadata.json +0 -1
- package/adapter-ajax-angularjs/package.json +0 -13
- package/adapter-ajax-fetch/breeze-client-adapter-ajax-fetch.metadata.json +0 -1
- package/adapter-ajax-fetch/package.json +0 -13
- package/adapter-ajax-httpclient/breeze-client-adapter-ajax-httpclient.metadata.json +0 -1
- package/adapter-ajax-httpclient/package.json +0 -13
- package/adapter-ajax-jquery/breeze-client-adapter-ajax-jquery.metadata.json +0 -1
- package/adapter-ajax-jquery/package.json +0 -13
- package/adapter-ajax-post/breeze-client-adapter-ajax-post.metadata.json +0 -1
- package/adapter-ajax-post/package.json +0 -13
- package/adapter-data-service-odata/breeze-client-adapter-data-service-odata.metadata.json +0 -1
- package/adapter-data-service-odata/package.json +0 -13
- package/adapter-data-service-webapi/breeze-client-adapter-data-service-webapi.metadata.json +0 -1
- package/adapter-data-service-webapi/package.json +0 -13
- package/adapter-model-library-backing-store/breeze-client-adapter-model-library-backing-store.metadata.json +0 -1
- package/adapter-model-library-backing-store/package.json +0 -13
- package/adapter-model-library-ko/breeze-client-adapter-model-library-ko.metadata.json +0 -1
- package/adapter-model-library-ko/package.json +0 -13
- package/adapter-uri-builder-json/breeze-client-adapter-uri-builder-json.metadata.json +0 -1
- package/adapter-uri-builder-json/package.json +0 -13
- package/adapter-uri-builder-odata/breeze-client-adapter-uri-builder-odata.metadata.json +0 -1
- package/adapter-uri-builder-odata/package.json +0 -13
- package/breeze-client.d.ts +0 -8
- package/breeze-client.metadata.json +0 -1
- package/bundles/breeze-client-adapter-ajax-angularjs.umd.js +0 -190
- package/bundles/breeze-client-adapter-ajax-angularjs.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-angularjs.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-ajax-angularjs.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-fetch.umd.js +0 -190
- package/bundles/breeze-client-adapter-ajax-fetch.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-fetch.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-ajax-fetch.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-httpclient.umd.js +0 -195
- package/bundles/breeze-client-adapter-ajax-httpclient.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-httpclient.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-ajax-httpclient.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-jquery.umd.js +0 -115
- package/bundles/breeze-client-adapter-ajax-jquery.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-jquery.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-ajax-jquery.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-post.umd.js +0 -92
- package/bundles/breeze-client-adapter-ajax-post.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-ajax-post.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-ajax-post.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-data-service-odata.umd.js +0 -743
- package/bundles/breeze-client-adapter-data-service-odata.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-data-service-odata.umd.min.js +0 -16
- package/bundles/breeze-client-adapter-data-service-odata.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-data-service-webapi.umd.js +0 -326
- package/bundles/breeze-client-adapter-data-service-webapi.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-data-service-webapi.umd.min.js +0 -16
- package/bundles/breeze-client-adapter-data-service-webapi.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-model-library-backing-store.umd.js +0 -280
- package/bundles/breeze-client-adapter-model-library-backing-store.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-model-library-backing-store.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-model-library-backing-store.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-model-library-ko.umd.js +0 -252
- package/bundles/breeze-client-adapter-model-library-ko.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-model-library-ko.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-model-library-ko.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-uri-builder-json.umd.js +0 -96
- package/bundles/breeze-client-adapter-uri-builder-json.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-uri-builder-json.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-uri-builder-json.umd.min.js.map +0 -1
- package/bundles/breeze-client-adapter-uri-builder-odata.umd.js +0 -262
- package/bundles/breeze-client-adapter-uri-builder-odata.umd.js.map +0 -1
- package/bundles/breeze-client-adapter-uri-builder-odata.umd.min.js +0 -2
- package/bundles/breeze-client-adapter-uri-builder-odata.umd.min.js.map +0 -1
- package/bundles/breeze-client-mixin-get-entity-graph.umd.js +0 -258
- package/bundles/breeze-client-mixin-get-entity-graph.umd.js.map +0 -1
- package/bundles/breeze-client-mixin-get-entity-graph.umd.min.js +0 -2
- package/bundles/breeze-client-mixin-get-entity-graph.umd.min.js.map +0 -1
- package/bundles/breeze-client-mixin-save-queuing.umd.js +0 -579
- package/bundles/breeze-client-mixin-save-queuing.umd.js.map +0 -1
- package/bundles/breeze-client-mixin-save-queuing.umd.min.js +0 -16
- package/bundles/breeze-client-mixin-save-queuing.umd.min.js.map +0 -1
- package/bundles/breeze-client.umd.js +0 -14098
- package/bundles/breeze-client.umd.js.map +0 -1
- package/bundles/breeze-client.umd.min.js +0 -16
- package/bundles/breeze-client.umd.min.js.map +0 -1
- package/esm2015/adapter-ajax-angularjs/adapter-ajax-angularjs.js +0 -130
- package/esm2015/adapter-ajax-angularjs/adapter-core.js +0 -49
- package/esm2015/adapter-ajax-angularjs/breeze-client-adapter-ajax-angularjs.js +0 -5
- package/esm2015/adapter-ajax-fetch/adapter-ajax-fetch.js +0 -130
- package/esm2015/adapter-ajax-fetch/adapter-core.js +0 -49
- package/esm2015/adapter-ajax-fetch/breeze-client-adapter-ajax-fetch.js +0 -5
- package/esm2015/adapter-ajax-httpclient/adapter-ajax-httpclient.js +0 -137
- package/esm2015/adapter-ajax-httpclient/adapter-core.js +0 -49
- package/esm2015/adapter-ajax-httpclient/breeze-client-adapter-ajax-httpclient.js +0 -5
- package/esm2015/adapter-ajax-jquery/adapter-ajax-jquery.js +0 -103
- package/esm2015/adapter-ajax-jquery/breeze-client-adapter-ajax-jquery.js +0 -5
- package/esm2015/adapter-ajax-post/adapter-ajax-post.js +0 -77
- package/esm2015/adapter-ajax-post/breeze-client-adapter-ajax-post.js +0 -5
- package/esm2015/adapter-data-service-odata/adapter-core.js +0 -49
- package/esm2015/adapter-data-service-odata/adapter-data-service-odata.js +0 -459
- package/esm2015/adapter-data-service-odata/breeze-client-adapter-data-service-odata.js +0 -5
- package/esm2015/adapter-data-service-webapi/adapter-data-service-webapi.js +0 -93
- package/esm2015/adapter-data-service-webapi/breeze-client-adapter-data-service-webapi.js +0 -5
- package/esm2015/adapter-model-library-backing-store/adapter-model-library-backing-store.js +0 -268
- package/esm2015/adapter-model-library-backing-store/breeze-client-adapter-model-library-backing-store.js +0 -5
- package/esm2015/adapter-model-library-ko/adapter-model-library-ko.js +0 -240
- package/esm2015/adapter-model-library-ko/breeze-client-adapter-model-library-ko.js +0 -5
- package/esm2015/adapter-uri-builder-json/adapter-core.js +0 -49
- package/esm2015/adapter-uri-builder-json/adapter-uri-builder-json.js +0 -36
- package/esm2015/adapter-uri-builder-json/breeze-client-adapter-uri-builder-json.js +0 -5
- package/esm2015/adapter-uri-builder-odata/adapter-core.js +0 -49
- package/esm2015/adapter-uri-builder-odata/adapter-uri-builder-odata.js +0 -192
- package/esm2015/adapter-uri-builder-odata/breeze-client-adapter-uri-builder-odata.js +0 -5
- package/esm2015/breeze-client.js +0 -9
- package/esm2015/index.js +0 -2
- package/esm2015/mixin-get-entity-graph/breeze-client-mixin-get-entity-graph.js +0 -5
- package/esm2015/mixin-get-entity-graph/mixin-get-entity-graph.js +0 -269
- package/esm2015/mixin-save-queuing/breeze-client-mixin-save-queuing.js +0 -5
- package/esm2015/mixin-save-queuing/mixin-save-queuing.js +0 -400
- package/esm2015/src/abstract-data-service-adapter.js +0 -296
- package/esm2015/src/array.js +0 -4
- package/esm2015/src/assert-param.js +0 -312
- package/esm2015/src/breeze.js +0 -85
- package/esm2015/src/complex-array.js +0 -119
- package/esm2015/src/config.js +0 -223
- package/esm2015/src/core.js +0 -709
- package/esm2015/src/csdl-metadata-parser.js +0 -385
- package/esm2015/src/data-service.js +0 -203
- package/esm2015/src/data-type.js +0 -444
- package/esm2015/src/default-property-interceptor.js +0 -460
- package/esm2015/src/entity-action.js +0 -45
- package/esm2015/src/entity-aspect.js +0 -806
- package/esm2015/src/entity-group.js +0 -187
- package/esm2015/src/entity-key.js +0 -116
- package/esm2015/src/entity-manager.js +0 -2094
- package/esm2015/src/entity-metadata.js +0 -2109
- package/esm2015/src/entity-query.js +0 -996
- package/esm2015/src/entity-state.js +0 -99
- package/esm2015/src/enum.js +0 -141
- package/esm2015/src/event.js +0 -256
- package/esm2015/src/interface-registry.js +0 -41
- package/esm2015/src/key-generator.js +0 -108
- package/esm2015/src/local-query-comparison-options.js +0 -65
- package/esm2015/src/mapping-context.js +0 -405
- package/esm2015/src/naming-convention.js +0 -88
- package/esm2015/src/observable-array.js +0 -185
- package/esm2015/src/predicate.js +0 -1235
- package/esm2015/src/primitive-array.js +0 -87
- package/esm2015/src/query-options.js +0 -152
- package/esm2015/src/relation-array.js +0 -175
- package/esm2015/src/save-options.js +0 -41
- package/esm2015/src/unattached-children-map.js +0 -58
- package/esm2015/src/validate.js +0 -991
- package/esm2015/src/validation-options.js +0 -64
- package/esm5/adapter-ajax-angularjs/adapter-ajax-angularjs.js +0 -132
- package/esm5/adapter-ajax-angularjs/adapter-core.js +0 -49
- package/esm5/adapter-ajax-angularjs/breeze-client-adapter-ajax-angularjs.js +0 -5
- package/esm5/adapter-ajax-fetch/adapter-ajax-fetch.js +0 -132
- package/esm5/adapter-ajax-fetch/adapter-core.js +0 -49
- package/esm5/adapter-ajax-fetch/breeze-client-adapter-ajax-fetch.js +0 -5
- package/esm5/adapter-ajax-httpclient/adapter-ajax-httpclient.js +0 -139
- package/esm5/adapter-ajax-httpclient/adapter-core.js +0 -49
- package/esm5/adapter-ajax-httpclient/breeze-client-adapter-ajax-httpclient.js +0 -5
- package/esm5/adapter-ajax-jquery/adapter-ajax-jquery.js +0 -105
- package/esm5/adapter-ajax-jquery/breeze-client-adapter-ajax-jquery.js +0 -5
- package/esm5/adapter-ajax-post/adapter-ajax-post.js +0 -81
- package/esm5/adapter-ajax-post/breeze-client-adapter-ajax-post.js +0 -5
- package/esm5/adapter-data-service-odata/adapter-core.js +0 -49
- package/esm5/adapter-data-service-odata/adapter-data-service-odata.js +0 -466
- package/esm5/adapter-data-service-odata/breeze-client-adapter-data-service-odata.js +0 -5
- package/esm5/adapter-data-service-webapi/adapter-data-service-webapi.js +0 -98
- package/esm5/adapter-data-service-webapi/breeze-client-adapter-data-service-webapi.js +0 -5
- package/esm5/adapter-model-library-backing-store/adapter-model-library-backing-store.js +0 -270
- package/esm5/adapter-model-library-backing-store/breeze-client-adapter-model-library-backing-store.js +0 -5
- package/esm5/adapter-model-library-ko/adapter-model-library-ko.js +0 -242
- package/esm5/adapter-model-library-ko/breeze-client-adapter-model-library-ko.js +0 -5
- package/esm5/adapter-uri-builder-json/adapter-core.js +0 -49
- package/esm5/adapter-uri-builder-json/adapter-uri-builder-json.js +0 -38
- package/esm5/adapter-uri-builder-json/breeze-client-adapter-uri-builder-json.js +0 -5
- package/esm5/adapter-uri-builder-odata/adapter-core.js +0 -49
- package/esm5/adapter-uri-builder-odata/adapter-uri-builder-odata.js +0 -197
- package/esm5/adapter-uri-builder-odata/breeze-client-adapter-uri-builder-odata.js +0 -5
- package/esm5/breeze-client.js +0 -9
- package/esm5/index.js +0 -2
- package/esm5/mixin-get-entity-graph/breeze-client-mixin-get-entity-graph.js +0 -5
- package/esm5/mixin-get-entity-graph/mixin-get-entity-graph.js +0 -269
- package/esm5/mixin-save-queuing/breeze-client-mixin-save-queuing.js +0 -5
- package/esm5/mixin-save-queuing/mixin-save-queuing.js +0 -412
- package/esm5/src/abstract-data-service-adapter.js +0 -302
- package/esm5/src/array.js +0 -4
- package/esm5/src/assert-param.js +0 -317
- package/esm5/src/breeze.js +0 -85
- package/esm5/src/complex-array.js +0 -119
- package/esm5/src/config.js +0 -228
- package/esm5/src/core.js +0 -717
- package/esm5/src/csdl-metadata-parser.js +0 -385
- package/esm5/src/data-service.js +0 -207
- package/esm5/src/data-type.js +0 -451
- package/esm5/src/default-property-interceptor.js +0 -460
- package/esm5/src/entity-action.js +0 -52
- package/esm5/src/entity-aspect.js +0 -812
- package/esm5/src/entity-group.js +0 -189
- package/esm5/src/entity-key.js +0 -118
- package/esm5/src/entity-manager.js +0 -2112
- package/esm5/src/entity-metadata.js +0 -2144
- package/esm5/src/entity-query.js +0 -1023
- package/esm5/src/entity-state.js +0 -106
- package/esm5/src/enum.js +0 -144
- package/esm5/src/event.js +0 -259
- package/esm5/src/interface-registry.js +0 -43
- package/esm5/src/key-generator.js +0 -111
- package/esm5/src/local-query-comparison-options.js +0 -67
- package/esm5/src/mapping-context.js +0 -407
- package/esm5/src/naming-convention.js +0 -90
- package/esm5/src/observable-array.js +0 -201
- package/esm5/src/predicate.js +0 -1300
- package/esm5/src/primitive-array.js +0 -87
- package/esm5/src/query-options.js +0 -167
- package/esm5/src/relation-array.js +0 -175
- package/esm5/src/save-options.js +0 -43
- package/esm5/src/unattached-children-map.js +0 -60
- package/esm5/src/validate.js +0 -996
- package/esm5/src/validation-options.js +0 -66
- package/fesm2015/breeze-client-adapter-ajax-angularjs.js.map +0 -1
- package/fesm2015/breeze-client-adapter-ajax-fetch.js.map +0 -1
- package/fesm2015/breeze-client-adapter-ajax-httpclient.js.map +0 -1
- package/fesm2015/breeze-client-adapter-ajax-jquery.js.map +0 -1
- package/fesm2015/breeze-client-adapter-ajax-post.js.map +0 -1
- package/fesm2015/breeze-client-adapter-data-service-odata.js.map +0 -1
- package/fesm2015/breeze-client-adapter-data-service-webapi.js.map +0 -1
- package/fesm2015/breeze-client-adapter-model-library-backing-store.js.map +0 -1
- package/fesm2015/breeze-client-adapter-model-library-ko.js.map +0 -1
- package/fesm2015/breeze-client-adapter-uri-builder-json.js.map +0 -1
- package/fesm2015/breeze-client-adapter-uri-builder-odata.js.map +0 -1
- package/fesm2015/breeze-client-mixin-get-entity-graph.js.map +0 -1
- package/fesm2015/breeze-client-mixin-save-queuing.js.map +0 -1
- package/fesm2015/breeze-client.js.map +0 -1
- package/fesm5/breeze-client-adapter-ajax-angularjs.js.map +0 -1
- package/fesm5/breeze-client-adapter-ajax-fetch.js.map +0 -1
- package/fesm5/breeze-client-adapter-ajax-httpclient.js.map +0 -1
- package/fesm5/breeze-client-adapter-ajax-jquery.js.map +0 -1
- package/fesm5/breeze-client-adapter-ajax-post.js.map +0 -1
- package/fesm5/breeze-client-adapter-data-service-odata.js.map +0 -1
- package/fesm5/breeze-client-adapter-data-service-webapi.js.map +0 -1
- package/fesm5/breeze-client-adapter-model-library-backing-store.js.map +0 -1
- package/fesm5/breeze-client-adapter-model-library-ko.js.map +0 -1
- package/fesm5/breeze-client-adapter-uri-builder-json.js +0 -92
- package/fesm5/breeze-client-adapter-uri-builder-json.js.map +0 -1
- package/fesm5/breeze-client-adapter-uri-builder-odata.js +0 -250
- package/fesm5/breeze-client-adapter-uri-builder-odata.js.map +0 -1
- package/fesm5/breeze-client-mixin-get-entity-graph.js.map +0 -1
- package/fesm5/breeze-client-mixin-save-queuing.js.map +0 -1
- package/fesm5/breeze-client.js.map +0 -1
- package/mixin-get-entity-graph/breeze-client-mixin-get-entity-graph.metadata.json +0 -1
- package/mixin-get-entity-graph/package.json +0 -13
- package/mixin-save-queuing/breeze-client-mixin-save-queuing.metadata.json +0 -1
- package/mixin-save-queuing/package.json +0 -13
|
@@ -142,15 +142,14 @@ class BreezeEnum {
|
|
|
142
142
|
/** See if this comment will make it into .d.ts */
|
|
143
143
|
let hasOwnProperty = uncurry(Object.prototype.hasOwnProperty);
|
|
144
144
|
let arraySlice = uncurry(Array.prototype.slice);
|
|
145
|
-
|
|
145
|
+
let isES5Supported = function () {
|
|
146
146
|
try {
|
|
147
147
|
return !!(Object.getPrototypeOf && Object.defineProperty({}, 'x', {}));
|
|
148
148
|
}
|
|
149
149
|
catch (e) {
|
|
150
150
|
return false;
|
|
151
151
|
}
|
|
152
|
-
};
|
|
153
|
-
let isES5Supported = ɵ0();
|
|
152
|
+
}();
|
|
154
153
|
// iterate over object
|
|
155
154
|
function objectForEach(obj, kvFn) {
|
|
156
155
|
for (let key in obj) {
|
|
@@ -726,7 +725,7 @@ function isNumeric(n) {
|
|
|
726
725
|
}
|
|
727
726
|
// end of is Functions
|
|
728
727
|
// string functions
|
|
729
|
-
function stringStartsWith(str, prefix) {
|
|
728
|
+
function stringStartsWith$1(str, prefix) {
|
|
730
729
|
// returns true for empty string or null prefix
|
|
731
730
|
if ((!str))
|
|
732
731
|
return false;
|
|
@@ -734,7 +733,7 @@ function stringStartsWith(str, prefix) {
|
|
|
734
733
|
return true;
|
|
735
734
|
return str.indexOf(prefix, 0) === 0;
|
|
736
735
|
}
|
|
737
|
-
function stringEndsWith(str, suffix) {
|
|
736
|
+
function stringEndsWith$1(str, suffix) {
|
|
738
737
|
// returns true for empty string or null suffix
|
|
739
738
|
if ((!str))
|
|
740
739
|
return false;
|
|
@@ -824,8 +823,8 @@ const core = {
|
|
|
824
823
|
isNumeric: isNumeric,
|
|
825
824
|
identity: identity,
|
|
826
825
|
noop: noop,
|
|
827
|
-
stringStartsWith: stringStartsWith,
|
|
828
|
-
stringEndsWith: stringEndsWith,
|
|
826
|
+
stringStartsWith: stringStartsWith$1,
|
|
827
|
+
stringEndsWith: stringEndsWith$1,
|
|
829
828
|
formatString: formatString,
|
|
830
829
|
titleCase: titleCaseSpace,
|
|
831
830
|
toJson: toJson,
|
|
@@ -1663,7 +1662,7 @@ class DataService {
|
|
|
1663
1662
|
@param config - A configuration object.
|
|
1664
1663
|
**/
|
|
1665
1664
|
constructor(config) {
|
|
1666
|
-
updateWithConfig(this, config);
|
|
1665
|
+
updateWithConfig$1(this, config);
|
|
1667
1666
|
}
|
|
1668
1667
|
/**
|
|
1669
1668
|
Returns a copy of this DataService with the specified properties applied.
|
|
@@ -1673,7 +1672,7 @@ class DataService {
|
|
|
1673
1672
|
if (!config)
|
|
1674
1673
|
return this;
|
|
1675
1674
|
let result = new DataService(this);
|
|
1676
|
-
return updateWithConfig(result, config);
|
|
1675
|
+
return updateWithConfig$1(result, config);
|
|
1677
1676
|
}
|
|
1678
1677
|
static resolve(dataServices) {
|
|
1679
1678
|
// final defaults
|
|
@@ -1744,7 +1743,7 @@ class DataService {
|
|
|
1744
1743
|
}
|
|
1745
1744
|
}
|
|
1746
1745
|
DataService.prototype._$typeName = "DataService";
|
|
1747
|
-
function updateWithConfig(obj, dsConfig) {
|
|
1746
|
+
function updateWithConfig$1(obj, dsConfig) {
|
|
1748
1747
|
if (dsConfig) {
|
|
1749
1748
|
assertConfig(dsConfig)
|
|
1750
1749
|
.whereParam("serviceName").isOptional()
|
|
@@ -1837,17 +1836,16 @@ const INT32_MIN = -2147483648;
|
|
|
1837
1836
|
const INT32_MAX = 2147483647;
|
|
1838
1837
|
const BYTE_MIN = 0;
|
|
1839
1838
|
const BYTE_MAX = 255;
|
|
1840
|
-
const ɵ0$1 = function (context) {
|
|
1841
|
-
if (context.property) {
|
|
1842
|
-
return context.property.resolveProperty("displayName") || context.propertyName || context.property.name;
|
|
1843
|
-
}
|
|
1844
|
-
else {
|
|
1845
|
-
return "Value";
|
|
1846
|
-
}
|
|
1847
|
-
};
|
|
1848
1839
|
// add common props and methods for every validator 'context' here.
|
|
1849
1840
|
let rootContext = {
|
|
1850
|
-
displayName:
|
|
1841
|
+
displayName: function (context) {
|
|
1842
|
+
if (context.property) {
|
|
1843
|
+
return context.property.resolveProperty("displayName") || context.propertyName || context.property.name;
|
|
1844
|
+
}
|
|
1845
|
+
else {
|
|
1846
|
+
return "Value";
|
|
1847
|
+
}
|
|
1848
|
+
}
|
|
1851
1849
|
};
|
|
1852
1850
|
/**
|
|
1853
1851
|
Instances of the Validator class provide the logic to validate another object and provide a description of any errors
|
|
@@ -2704,7 +2702,14 @@ function makeRegExpValidator(validatorName, expression, defaultMessage, context)
|
|
|
2704
2702
|
};
|
|
2705
2703
|
return new Validator(validatorName, valFn, context);
|
|
2706
2704
|
}
|
|
2707
|
-
|
|
2705
|
+
// http://rosettacode.org/wiki/Luhn_test_of_credit_card_numbers#JavaScript
|
|
2706
|
+
// function luhn(a: string, b: number, c: number, d: number, e: number) {
|
|
2707
|
+
// for (d = +a[b = a.length - 1], e = 0; b--; ) {
|
|
2708
|
+
// c = +a[b], d += ++e % 2 ? 2 * c % 10 + (c > 4) : c;
|
|
2709
|
+
// }
|
|
2710
|
+
// return !(d % 10);
|
|
2711
|
+
// };
|
|
2712
|
+
let luhn = (function () {
|
|
2708
2713
|
let luhnArr = [0, 2, 4, 6, 8, 1, 3, 5, 7, 9];
|
|
2709
2714
|
return function (str) {
|
|
2710
2715
|
let counter = 0;
|
|
@@ -2719,15 +2724,7 @@ const ɵ1 = function () {
|
|
|
2719
2724
|
}
|
|
2720
2725
|
return (counter % 10 === 0);
|
|
2721
2726
|
};
|
|
2722
|
-
};
|
|
2723
|
-
// http://rosettacode.org/wiki/Luhn_test_of_credit_card_numbers#JavaScript
|
|
2724
|
-
// function luhn(a: string, b: number, c: number, d: number, e: number) {
|
|
2725
|
-
// for (d = +a[b = a.length - 1], e = 0; b--; ) {
|
|
2726
|
-
// c = +a[b], d += ++e % 2 ? 2 * c % 10 + (c > 4) : c;
|
|
2727
|
-
// }
|
|
2728
|
-
// return !(d % 10);
|
|
2729
|
-
// };
|
|
2730
|
-
let luhn = (ɵ1)();
|
|
2727
|
+
})();
|
|
2731
2728
|
/**
|
|
2732
2729
|
A ValidationError is used to describe a failed validation.
|
|
2733
2730
|
|
|
@@ -4556,104 +4553,103 @@ function parseFnExpr(source, parts, tokens, exprContext) {
|
|
|
4556
4553
|
throw e;
|
|
4557
4554
|
}
|
|
4558
4555
|
}
|
|
4559
|
-
|
|
4560
|
-
|
|
4561
|
-
|
|
4562
|
-
|
|
4563
|
-
|
|
4564
|
-
|
|
4565
|
-
|
|
4566
|
-
|
|
4567
|
-
|
|
4568
|
-
|
|
4569
|
-
|
|
4570
|
-
|
|
4571
|
-
}
|
|
4572
|
-
|
|
4573
|
-
|
|
4574
|
-
|
|
4575
|
-
|
|
4576
|
-
|
|
4577
|
-
|
|
4578
|
-
|
|
4579
|
-
|
|
4580
|
-
|
|
4581
|
-
|
|
4582
|
-
|
|
4583
|
-
|
|
4584
|
-
|
|
4585
|
-
return
|
|
4586
|
-
|
|
4587
|
-
|
|
4588
|
-
|
|
4556
|
+
// toFunctionVisitor
|
|
4557
|
+
let toFunctionVisitor = {
|
|
4558
|
+
isExtended: false,
|
|
4559
|
+
passthruPredicate: function () {
|
|
4560
|
+
throw new Error("Cannot execute an PassthruPredicate expression against the local cache: " + this.value);
|
|
4561
|
+
},
|
|
4562
|
+
unaryPredicate: function (context) {
|
|
4563
|
+
let predFn = this.pred.visit(context);
|
|
4564
|
+
switch (this.op.key) {
|
|
4565
|
+
case "not":
|
|
4566
|
+
return function (entity) {
|
|
4567
|
+
return !predFn(entity);
|
|
4568
|
+
};
|
|
4569
|
+
default:
|
|
4570
|
+
throw new Error("Invalid unary operator:" + this.op.key);
|
|
4571
|
+
}
|
|
4572
|
+
},
|
|
4573
|
+
binaryPredicate: function (context) {
|
|
4574
|
+
let expr1Fn = this.expr1.visit(context);
|
|
4575
|
+
let expr2Fn = this.expr2.visit(context);
|
|
4576
|
+
let dataType = this.expr1.dataType || this.expr2.dataType;
|
|
4577
|
+
let lqco = context.entityType.metadataStore.localQueryComparisonOptions;
|
|
4578
|
+
let predFn = getBinaryPredicateFn(this, dataType, lqco);
|
|
4579
|
+
if (predFn == null) {
|
|
4580
|
+
throw new Error("Invalid binaryPredicate operator:" + this.op.key);
|
|
4581
|
+
}
|
|
4582
|
+
return function (entity) {
|
|
4583
|
+
return predFn(expr1Fn(entity), expr2Fn(entity));
|
|
4584
|
+
};
|
|
4585
|
+
},
|
|
4586
|
+
andOrPredicate: function (context) {
|
|
4587
|
+
let predFns = this.preds.map((pred) => {
|
|
4588
|
+
return pred.visit(context);
|
|
4589
|
+
});
|
|
4590
|
+
switch (this.op.key) {
|
|
4591
|
+
case "and":
|
|
4592
|
+
return function (entity) {
|
|
4593
|
+
let result = predFns.reduce(function (prev, cur) {
|
|
4594
|
+
return prev && cur(entity);
|
|
4595
|
+
}, true);
|
|
4596
|
+
return result;
|
|
4597
|
+
};
|
|
4598
|
+
case "or":
|
|
4599
|
+
return function (entity) {
|
|
4600
|
+
let result = predFns.reduce(function (prev, cur) {
|
|
4601
|
+
return prev || cur(entity);
|
|
4602
|
+
}, false);
|
|
4603
|
+
return result;
|
|
4604
|
+
};
|
|
4605
|
+
default:
|
|
4606
|
+
throw new Error("Invalid boolean operator:" + this.op.key);
|
|
4607
|
+
}
|
|
4608
|
+
},
|
|
4609
|
+
anyAllPredicate: function (context) {
|
|
4610
|
+
let exprFn = this.expr.visit(context);
|
|
4611
|
+
let newContext = core.extend({}, context);
|
|
4612
|
+
newContext.entityType = this.expr.dataType;
|
|
4613
|
+
let predFn = this.pred.visit(newContext);
|
|
4614
|
+
let anyAllPredFn = getAnyAllPredicateFn(this.op);
|
|
4615
|
+
return function (entity) {
|
|
4616
|
+
return anyAllPredFn(exprFn(entity), predFn);
|
|
4617
|
+
};
|
|
4618
|
+
},
|
|
4619
|
+
litExpr: function () {
|
|
4620
|
+
let value = this.value;
|
|
4621
|
+
return function (entity) {
|
|
4622
|
+
return value;
|
|
4623
|
+
};
|
|
4624
|
+
},
|
|
4625
|
+
propExpr: function () {
|
|
4626
|
+
let propertyPath = this.propertyPath;
|
|
4627
|
+
let properties = propertyPath.split('.');
|
|
4628
|
+
if (properties.length === 1) {
|
|
4589
4629
|
return function (entity) {
|
|
4590
|
-
|
|
4591
|
-
return prev && cur(entity);
|
|
4592
|
-
}, true);
|
|
4593
|
-
return result;
|
|
4630
|
+
return entity.getProperty(propertyPath);
|
|
4594
4631
|
};
|
|
4595
|
-
|
|
4632
|
+
}
|
|
4633
|
+
else {
|
|
4596
4634
|
return function (entity) {
|
|
4597
|
-
|
|
4598
|
-
return prev || cur(entity);
|
|
4599
|
-
}, false);
|
|
4600
|
-
return result;
|
|
4635
|
+
return EntityAspect.getPropertyPathValue(entity, properties);
|
|
4601
4636
|
};
|
|
4602
|
-
|
|
4603
|
-
|
|
4604
|
-
|
|
4605
|
-
|
|
4606
|
-
|
|
4607
|
-
|
|
4608
|
-
|
|
4609
|
-
let predFn = this.pred.visit(newContext);
|
|
4610
|
-
let anyAllPredFn = getAnyAllPredicateFn(this.op);
|
|
4611
|
-
return function (entity) {
|
|
4612
|
-
return anyAllPredFn(exprFn(entity), predFn);
|
|
4613
|
-
};
|
|
4614
|
-
}, ɵ5 = function () {
|
|
4615
|
-
let value = this.value;
|
|
4616
|
-
return function (entity) {
|
|
4617
|
-
return value;
|
|
4618
|
-
};
|
|
4619
|
-
}, ɵ6 = function () {
|
|
4620
|
-
let propertyPath = this.propertyPath;
|
|
4621
|
-
let properties = propertyPath.split('.');
|
|
4622
|
-
if (properties.length === 1) {
|
|
4623
|
-
return function (entity) {
|
|
4624
|
-
return entity.getProperty(propertyPath);
|
|
4625
|
-
};
|
|
4626
|
-
}
|
|
4627
|
-
else {
|
|
4637
|
+
}
|
|
4638
|
+
},
|
|
4639
|
+
fnExpr: function (context) {
|
|
4640
|
+
let exprFns = this.exprs.map(function (expr) {
|
|
4641
|
+
return expr.visit(context);
|
|
4642
|
+
});
|
|
4643
|
+
let that = this;
|
|
4628
4644
|
return function (entity) {
|
|
4629
|
-
|
|
4645
|
+
let values = exprFns.map(function (exprFn) {
|
|
4646
|
+
let value = exprFn(entity);
|
|
4647
|
+
return value;
|
|
4648
|
+
});
|
|
4649
|
+
let result = that.localFn.apply(null, values);
|
|
4650
|
+
return result;
|
|
4630
4651
|
};
|
|
4631
4652
|
}
|
|
4632
|
-
}, ɵ7 = function (context) {
|
|
4633
|
-
let exprFns = this.exprs.map(function (expr) {
|
|
4634
|
-
return expr.visit(context);
|
|
4635
|
-
});
|
|
4636
|
-
let that = this;
|
|
4637
|
-
return function (entity) {
|
|
4638
|
-
let values = exprFns.map(function (exprFn) {
|
|
4639
|
-
let value = exprFn(entity);
|
|
4640
|
-
return value;
|
|
4641
|
-
});
|
|
4642
|
-
let result = that.localFn.apply(null, values);
|
|
4643
|
-
return result;
|
|
4644
|
-
};
|
|
4645
|
-
};
|
|
4646
|
-
// toFunctionVisitor
|
|
4647
|
-
let toFunctionVisitor = {
|
|
4648
|
-
isExtended: false,
|
|
4649
|
-
passthruPredicate: ɵ0$2,
|
|
4650
|
-
unaryPredicate: ɵ1$1,
|
|
4651
|
-
binaryPredicate: ɵ2,
|
|
4652
|
-
andOrPredicate: ɵ3,
|
|
4653
|
-
anyAllPredicate: ɵ4,
|
|
4654
|
-
litExpr: ɵ5,
|
|
4655
|
-
propExpr: ɵ6,
|
|
4656
|
-
fnExpr: ɵ7
|
|
4657
4653
|
};
|
|
4658
4654
|
function getAnyAllPredicateFn(op) {
|
|
4659
4655
|
switch (op.key) {
|
|
@@ -4720,12 +4716,12 @@ function getBinaryPredicateFn(binaryPredicate, dataType, lqco) {
|
|
|
4720
4716
|
break;
|
|
4721
4717
|
case 'startswith':
|
|
4722
4718
|
predFn = function (v1, v2) {
|
|
4723
|
-
return stringStartsWith
|
|
4719
|
+
return stringStartsWith(v1, v2, lqco);
|
|
4724
4720
|
};
|
|
4725
4721
|
break;
|
|
4726
4722
|
case 'endswith':
|
|
4727
4723
|
predFn = function (v1, v2) {
|
|
4728
|
-
return stringEndsWith
|
|
4724
|
+
return stringEndsWith(v1, v2, lqco);
|
|
4729
4725
|
};
|
|
4730
4726
|
break;
|
|
4731
4727
|
case 'contains':
|
|
@@ -4761,14 +4757,14 @@ function stringEquals(a, b, lqco) {
|
|
|
4761
4757
|
}
|
|
4762
4758
|
return a === b;
|
|
4763
4759
|
}
|
|
4764
|
-
function stringStartsWith
|
|
4760
|
+
function stringStartsWith(a, b, lqco) {
|
|
4765
4761
|
if (!lqco.isCaseSensitive) {
|
|
4766
4762
|
a = (a || "").toLowerCase();
|
|
4767
4763
|
b = (b || "").toLowerCase();
|
|
4768
4764
|
}
|
|
4769
4765
|
return core.stringStartsWith(a, b);
|
|
4770
4766
|
}
|
|
4771
|
-
function stringEndsWith
|
|
4767
|
+
function stringEndsWith(a, b, lqco) {
|
|
4772
4768
|
if (!lqco.isCaseSensitive) {
|
|
4773
4769
|
a = (a || "").toLowerCase();
|
|
4774
4770
|
b = (b || "").toLowerCase();
|
|
@@ -4782,92 +4778,91 @@ function stringContains(a, b, lqco) {
|
|
|
4782
4778
|
}
|
|
4783
4779
|
return a.indexOf(b) >= 0;
|
|
4784
4780
|
}
|
|
4785
|
-
|
|
4786
|
-
|
|
4787
|
-
|
|
4788
|
-
let predVal = this.pred.visit(context);
|
|
4789
|
-
let json = {};
|
|
4790
|
-
json[this.op.key] = predVal;
|
|
4791
|
-
return json;
|
|
4792
|
-
}, ɵ10 = function (context) {
|
|
4793
|
-
let expr1Val = this.expr1.visit(context);
|
|
4794
|
-
let expr2Val = this.expr2.visit(context);
|
|
4795
|
-
let json = {};
|
|
4796
|
-
if (this.expr2 instanceof PropExpr) {
|
|
4797
|
-
expr2Val = { value: expr2Val, isProperty: true };
|
|
4798
|
-
}
|
|
4799
|
-
if (this.op.key === "eq") {
|
|
4800
|
-
json[expr1Val] = expr2Val;
|
|
4801
|
-
}
|
|
4802
|
-
else {
|
|
4803
|
-
let value = {};
|
|
4804
|
-
json[expr1Val] = value;
|
|
4805
|
-
value[this.op.key] = expr2Val;
|
|
4806
|
-
}
|
|
4807
|
-
return json;
|
|
4808
|
-
}, ɵ11 = function (context) {
|
|
4809
|
-
let predVals = this.preds.map(function (pred) {
|
|
4810
|
-
return pred.visit(context);
|
|
4811
|
-
});
|
|
4812
|
-
if (!predVals || !predVals.length) {
|
|
4813
|
-
return {};
|
|
4814
|
-
}
|
|
4815
|
-
let json;
|
|
4816
|
-
// normalizeAnd clauses if possible.
|
|
4817
|
-
// passthru predicate will appear as string and their 'ands' can't be 'normalized'
|
|
4818
|
-
if (this.op.key === 'and' && predVals.length === 2 && !predVals.some((v) => v.or || typeof (v) === 'string')) {
|
|
4819
|
-
// normalize 'and' clauses - will return null if can't be combined.
|
|
4820
|
-
json = predVals.reduce(combine);
|
|
4821
|
-
}
|
|
4822
|
-
if (json == null) {
|
|
4823
|
-
json = {};
|
|
4824
|
-
json[this.op.key] = predVals;
|
|
4825
|
-
}
|
|
4826
|
-
return json;
|
|
4827
|
-
}, ɵ12 = function (context) {
|
|
4828
|
-
let exprVal = this.expr.visit(context);
|
|
4829
|
-
let newContext = core.extend({}, context);
|
|
4830
|
-
newContext.entityType = this.expr.dataType;
|
|
4831
|
-
let predVal = this.pred.visit(newContext);
|
|
4832
|
-
let json = {};
|
|
4833
|
-
let value = {};
|
|
4834
|
-
value[this.op.key] = predVal;
|
|
4835
|
-
json[exprVal] = value;
|
|
4836
|
-
return json;
|
|
4837
|
-
}, ɵ13 = function (context) {
|
|
4838
|
-
if (this.hasExplicitDataType || context.useExplicitDataType) {
|
|
4839
|
-
return { value: this.value, dataType: this.dataType.name };
|
|
4840
|
-
}
|
|
4841
|
-
else {
|
|
4781
|
+
// toJSONVisitor
|
|
4782
|
+
let toJSONVisitor = {
|
|
4783
|
+
passthruPredicate: function () {
|
|
4842
4784
|
return this.value;
|
|
4843
|
-
}
|
|
4844
|
-
|
|
4845
|
-
|
|
4846
|
-
|
|
4847
|
-
|
|
4785
|
+
},
|
|
4786
|
+
unaryPredicate: function (context) {
|
|
4787
|
+
let predVal = this.pred.visit(context);
|
|
4788
|
+
let json = {};
|
|
4789
|
+
json[this.op.key] = predVal;
|
|
4790
|
+
return json;
|
|
4791
|
+
},
|
|
4792
|
+
binaryPredicate: function (context) {
|
|
4793
|
+
let expr1Val = this.expr1.visit(context);
|
|
4794
|
+
let expr2Val = this.expr2.visit(context);
|
|
4795
|
+
let json = {};
|
|
4796
|
+
if (this.expr2 instanceof PropExpr) {
|
|
4797
|
+
expr2Val = { value: expr2Val, isProperty: true };
|
|
4798
|
+
}
|
|
4799
|
+
if (this.op.key === "eq") {
|
|
4800
|
+
json[expr1Val] = expr2Val;
|
|
4801
|
+
}
|
|
4802
|
+
else {
|
|
4803
|
+
let value = {};
|
|
4804
|
+
json[expr1Val] = value;
|
|
4805
|
+
value[this.op.key] = expr2Val;
|
|
4806
|
+
}
|
|
4807
|
+
return json;
|
|
4808
|
+
},
|
|
4809
|
+
andOrPredicate: function (context) {
|
|
4810
|
+
let predVals = this.preds.map(function (pred) {
|
|
4811
|
+
return pred.visit(context);
|
|
4812
|
+
});
|
|
4813
|
+
if (!predVals || !predVals.length) {
|
|
4814
|
+
return {};
|
|
4815
|
+
}
|
|
4816
|
+
let json;
|
|
4817
|
+
// normalizeAnd clauses if possible.
|
|
4818
|
+
// passthru predicate will appear as string and their 'ands' can't be 'normalized'
|
|
4819
|
+
if (this.op.key === 'and' && predVals.length === 2 && !predVals.some((v) => v.or || typeof (v) === 'string')) {
|
|
4820
|
+
// normalize 'and' clauses - will return null if can't be combined.
|
|
4821
|
+
json = predVals.reduce(combine);
|
|
4822
|
+
}
|
|
4823
|
+
if (json == null) {
|
|
4824
|
+
json = {};
|
|
4825
|
+
json[this.op.key] = predVals;
|
|
4826
|
+
}
|
|
4827
|
+
return json;
|
|
4828
|
+
},
|
|
4829
|
+
anyAllPredicate: function (context) {
|
|
4830
|
+
let exprVal = this.expr.visit(context);
|
|
4831
|
+
let newContext = core.extend({}, context);
|
|
4832
|
+
newContext.entityType = this.expr.dataType;
|
|
4833
|
+
let predVal = this.pred.visit(newContext);
|
|
4834
|
+
let json = {};
|
|
4835
|
+
let value = {};
|
|
4836
|
+
value[this.op.key] = predVal;
|
|
4837
|
+
json[exprVal] = value;
|
|
4838
|
+
return json;
|
|
4839
|
+
},
|
|
4840
|
+
litExpr: function (context) {
|
|
4841
|
+
if (this.hasExplicitDataType || context.useExplicitDataType) {
|
|
4842
|
+
return { value: this.value, dataType: this.dataType.name };
|
|
4843
|
+
}
|
|
4844
|
+
else {
|
|
4845
|
+
return this.value;
|
|
4846
|
+
}
|
|
4847
|
+
},
|
|
4848
|
+
propExpr: function (context) {
|
|
4849
|
+
if (context.toNameOnServer) {
|
|
4850
|
+
if (!context.entityType) {
|
|
4851
|
+
console.warn(`No EntityType for propertyPath "${this.propertyPath}". ${core.strings.TO_TYPE}`);
|
|
4852
|
+
return this.propertyPath;
|
|
4853
|
+
}
|
|
4854
|
+
return context.entityType.clientPropertyPathToServer(this.propertyPath);
|
|
4855
|
+
}
|
|
4856
|
+
else {
|
|
4848
4857
|
return this.propertyPath;
|
|
4849
4858
|
}
|
|
4850
|
-
|
|
4851
|
-
|
|
4852
|
-
|
|
4853
|
-
|
|
4859
|
+
},
|
|
4860
|
+
fnExpr: function (context) {
|
|
4861
|
+
let exprVals = this.exprs.map(function (expr) {
|
|
4862
|
+
return expr.visit(context);
|
|
4863
|
+
});
|
|
4864
|
+
return this.fnName + "(" + exprVals.join(",") + ")";
|
|
4854
4865
|
}
|
|
4855
|
-
}, ɵ15 = function (context) {
|
|
4856
|
-
let exprVals = this.exprs.map(function (expr) {
|
|
4857
|
-
return expr.visit(context);
|
|
4858
|
-
});
|
|
4859
|
-
return this.fnName + "(" + exprVals.join(",") + ")";
|
|
4860
|
-
};
|
|
4861
|
-
// toJSONVisitor
|
|
4862
|
-
let toJSONVisitor = {
|
|
4863
|
-
passthruPredicate: ɵ8,
|
|
4864
|
-
unaryPredicate: ɵ9,
|
|
4865
|
-
binaryPredicate: ɵ10,
|
|
4866
|
-
andOrPredicate: ɵ11,
|
|
4867
|
-
anyAllPredicate: ɵ12,
|
|
4868
|
-
litExpr: ɵ13,
|
|
4869
|
-
propExpr: ɵ14,
|
|
4870
|
-
fnExpr: ɵ15
|
|
4871
4866
|
};
|
|
4872
4867
|
function combine(j1, j2) {
|
|
4873
4868
|
let ok = Object.keys(j2).every(function (key) {
|
|
@@ -6118,12 +6113,12 @@ class EntityAspect {
|
|
|
6118
6113
|
let em = this.entityManager;
|
|
6119
6114
|
let needsSave = true;
|
|
6120
6115
|
if (entityState === EntityState.Unchanged) {
|
|
6121
|
-
clearOriginalValues(entity);
|
|
6116
|
+
clearOriginalValues$1(entity);
|
|
6122
6117
|
delete this.hasTempKey;
|
|
6123
6118
|
needsSave = false;
|
|
6124
6119
|
}
|
|
6125
6120
|
else if (entityState === EntityState.Added) {
|
|
6126
|
-
clearOriginalValues(entity);
|
|
6121
|
+
clearOriginalValues$1(entity);
|
|
6127
6122
|
// TODO: more to do here... like regenerating key ???
|
|
6128
6123
|
}
|
|
6129
6124
|
else if (entityState === EntityState.Deleted) {
|
|
@@ -6658,18 +6653,18 @@ class ComplexAspect {
|
|
|
6658
6653
|
return aspect.getPropertyPath(this.parentProperty.name + "." + propName);
|
|
6659
6654
|
}
|
|
6660
6655
|
}
|
|
6661
|
-
function clearOriginalValues(target) {
|
|
6656
|
+
function clearOriginalValues$1(target) {
|
|
6662
6657
|
let aspect = target.entityAspect || target.complexAspect;
|
|
6663
6658
|
aspect.originalValues = {};
|
|
6664
6659
|
let stype = target.entityType || target.complexType;
|
|
6665
6660
|
stype.complexProperties.forEach(function (cp) {
|
|
6666
6661
|
let cos = target.getProperty(cp.name);
|
|
6667
6662
|
if (cp.isScalar) {
|
|
6668
|
-
clearOriginalValues(cos);
|
|
6663
|
+
clearOriginalValues$1(cos);
|
|
6669
6664
|
}
|
|
6670
6665
|
else {
|
|
6671
6666
|
cos._acceptChanges();
|
|
6672
|
-
cos.forEach(clearOriginalValues);
|
|
6667
|
+
cos.forEach(clearOriginalValues$1);
|
|
6673
6668
|
}
|
|
6674
6669
|
});
|
|
6675
6670
|
}
|
|
@@ -10056,7 +10051,7 @@ class ValidationOptions {
|
|
|
10056
10051
|
@param config - A configuration object.
|
|
10057
10052
|
**/
|
|
10058
10053
|
constructor(config) {
|
|
10059
|
-
updateWithConfig
|
|
10054
|
+
updateWithConfig(this, config);
|
|
10060
10055
|
}
|
|
10061
10056
|
/**
|
|
10062
10057
|
Returns a copy of this ValidationOptions with changes to the specified config properties.
|
|
@@ -10069,7 +10064,7 @@ class ValidationOptions {
|
|
|
10069
10064
|
if (!config)
|
|
10070
10065
|
return this;
|
|
10071
10066
|
let result = new ValidationOptions(this);
|
|
10072
|
-
updateWithConfig
|
|
10067
|
+
updateWithConfig(result, config);
|
|
10073
10068
|
return result;
|
|
10074
10069
|
}
|
|
10075
10070
|
/**
|
|
@@ -10093,7 +10088,7 @@ ValidationOptions.defaultInstance = new ValidationOptions({
|
|
|
10093
10088
|
validateOnPropertyChange: true
|
|
10094
10089
|
});
|
|
10095
10090
|
ValidationOptions.prototype._$typeName = "ValidationOptions";
|
|
10096
|
-
function updateWithConfig
|
|
10091
|
+
function updateWithConfig(options, config) {
|
|
10097
10092
|
if (config) {
|
|
10098
10093
|
assertConfig(config)
|
|
10099
10094
|
.whereParam("validateOnAttach").isBoolean().isOptional()
|
|
@@ -10657,7 +10652,7 @@ function mergeEntity(mc, node, meta) {
|
|
|
10657
10652
|
targetEntity.entityAspect.extraMetadata = meta.extraMetadata;
|
|
10658
10653
|
}
|
|
10659
10654
|
targetEntity.entityAspect.entityState = EntityState.Unchanged;
|
|
10660
|
-
clearOriginalValues
|
|
10655
|
+
clearOriginalValues(targetEntity);
|
|
10661
10656
|
// propertyName not specified because multiple props EntityChangedEventArgs
|
|
10662
10657
|
targetEntity.entityAspect.propertyChanged.publish({ entity: targetEntity, propertyName: null });
|
|
10663
10658
|
let action = isSaving ? EntityAction.MergeOnSave : EntityAction.MergeOnQuery;
|
|
@@ -10690,18 +10685,18 @@ function mergeEntity(mc, node, meta) {
|
|
|
10690
10685
|
return targetEntity;
|
|
10691
10686
|
}
|
|
10692
10687
|
// copied from entityAspect
|
|
10693
|
-
function clearOriginalValues
|
|
10688
|
+
function clearOriginalValues(target) {
|
|
10694
10689
|
let aspect = target.entityAspect || target.complexAspect;
|
|
10695
10690
|
aspect.originalValues = {};
|
|
10696
10691
|
let stype = target.entityType || target.complexType;
|
|
10697
10692
|
stype.complexProperties.forEach(function (cp) {
|
|
10698
10693
|
let cos = target.getProperty(cp.name);
|
|
10699
10694
|
if (cp.isScalar) {
|
|
10700
|
-
clearOriginalValues
|
|
10695
|
+
clearOriginalValues(cos);
|
|
10701
10696
|
}
|
|
10702
10697
|
else {
|
|
10703
10698
|
cos._acceptChanges();
|
|
10704
|
-
cos.forEach(clearOriginalValues
|
|
10699
|
+
cos.forEach(clearOriginalValues);
|
|
10705
10700
|
}
|
|
10706
10701
|
});
|
|
10707
10702
|
}
|
|
@@ -12999,119 +12994,118 @@ config.initializeAdapterInstances = function (irConfig) {
|
|
|
12999
12994
|
return core.objectMap(config, this.initializeAdapterInstance);
|
|
13000
12995
|
};
|
|
13001
12996
|
|
|
13002
|
-
const ɵ0$3 = function (...args) {
|
|
13003
|
-
if (this._inProgress) {
|
|
13004
|
-
return -1;
|
|
13005
|
-
}
|
|
13006
|
-
let goodAdds = this._getGoodAdds(args);
|
|
13007
|
-
if (!goodAdds.length) {
|
|
13008
|
-
return this.length;
|
|
13009
|
-
}
|
|
13010
|
-
this._beforeChange();
|
|
13011
|
-
let result;
|
|
13012
|
-
let objPrototype = Object.getPrototypeOf(this);
|
|
13013
|
-
if (objPrototype.push) {
|
|
13014
|
-
result = objPrototype.push.apply(this, goodAdds);
|
|
13015
|
-
}
|
|
13016
|
-
else {
|
|
13017
|
-
result = Array.prototype.push.apply(this, goodAdds);
|
|
13018
|
-
}
|
|
13019
|
-
processAdds(this, goodAdds);
|
|
13020
|
-
return result;
|
|
13021
|
-
}, ɵ1$2 = function (...args) {
|
|
13022
|
-
if (this._inProgress) {
|
|
13023
|
-
return -1;
|
|
13024
|
-
}
|
|
13025
|
-
let goodAdds = args;
|
|
13026
|
-
this._beforeChange();
|
|
13027
|
-
let result;
|
|
13028
|
-
let objPrototype = Object.getPrototypeOf(this);
|
|
13029
|
-
if (objPrototype.push) {
|
|
13030
|
-
result = objPrototype.push.apply(this, goodAdds);
|
|
13031
|
-
}
|
|
13032
|
-
else {
|
|
13033
|
-
result = Array.prototype.push.apply(this, goodAdds);
|
|
13034
|
-
}
|
|
13035
|
-
processAdds(this, goodAdds);
|
|
13036
|
-
return result;
|
|
13037
|
-
}, ɵ2$1 = function (...args) {
|
|
13038
|
-
let goodAdds = this._getGoodAdds(args);
|
|
13039
|
-
if (!goodAdds.length) {
|
|
13040
|
-
return this.length;
|
|
13041
|
-
}
|
|
13042
|
-
this._beforeChange();
|
|
13043
|
-
let result;
|
|
13044
|
-
let objPrototype = Object.getPrototypeOf(this);
|
|
13045
|
-
if (objPrototype.unshift) {
|
|
13046
|
-
result = objPrototype.unshift.apply(this, goodAdds);
|
|
13047
|
-
}
|
|
13048
|
-
else {
|
|
13049
|
-
result = Array.prototype.unshift.apply(this, goodAdds);
|
|
13050
|
-
}
|
|
13051
|
-
processAdds(this, goodAdds);
|
|
13052
|
-
return result;
|
|
13053
|
-
}, ɵ3$1 = function () {
|
|
13054
|
-
this._beforeChange();
|
|
13055
|
-
let result;
|
|
13056
|
-
let objPrototype = Object.getPrototypeOf(this);
|
|
13057
|
-
if (objPrototype.pop) {
|
|
13058
|
-
result = objPrototype.pop.apply(this);
|
|
13059
|
-
}
|
|
13060
|
-
else {
|
|
13061
|
-
result = Array.prototype.pop.apply(this);
|
|
13062
|
-
}
|
|
13063
|
-
processRemoves(this, [result]);
|
|
13064
|
-
return result;
|
|
13065
|
-
}, ɵ4$1 = function () {
|
|
13066
|
-
this._beforeChange();
|
|
13067
|
-
let result;
|
|
13068
|
-
let objPrototype = Object.getPrototypeOf(this);
|
|
13069
|
-
if (objPrototype.shift) {
|
|
13070
|
-
result = objPrototype.shift.apply(this);
|
|
13071
|
-
}
|
|
13072
|
-
else {
|
|
13073
|
-
result = Array.prototype.shift.apply(this);
|
|
13074
|
-
}
|
|
13075
|
-
processRemoves(this, [result]);
|
|
13076
|
-
return result;
|
|
13077
|
-
}, ɵ5$1 = function (...args) {
|
|
13078
|
-
let goodAdds = this._getGoodAdds(core.arraySlice(args, 2));
|
|
13079
|
-
let newArgs = core.arraySlice(args, 0, 2).concat(goodAdds);
|
|
13080
|
-
this._beforeChange();
|
|
13081
|
-
let result;
|
|
13082
|
-
let objPrototype = Object.getPrototypeOf(this);
|
|
13083
|
-
if (objPrototype.splice) {
|
|
13084
|
-
result = objPrototype.splice.apply(this, newArgs);
|
|
13085
|
-
}
|
|
13086
|
-
else {
|
|
13087
|
-
result = Array.prototype.splice.apply(this, newArgs);
|
|
13088
|
-
}
|
|
13089
|
-
processRemoves(this, result);
|
|
13090
|
-
if (goodAdds.length) {
|
|
13091
|
-
processAdds(this, goodAdds);
|
|
13092
|
-
}
|
|
13093
|
-
return result;
|
|
13094
|
-
}, ɵ6$1 = function () {
|
|
13095
|
-
return this.parent.entityAspect || this.parent.complexAspect.getEntityAspect();
|
|
13096
|
-
}, ɵ7$1 = function () {
|
|
13097
|
-
return this.getEntityAspect();
|
|
13098
|
-
}, ɵ8$1 = function () {
|
|
13099
|
-
let em = this.getEntityAspect().entityManager;
|
|
13100
|
-
return em && em._pendingPubs;
|
|
13101
|
-
}, ɵ9$1 = function () {
|
|
13102
|
-
// default is to do nothing
|
|
13103
|
-
};
|
|
13104
12997
|
let mixin = {
|
|
13105
|
-
push:
|
|
13106
|
-
|
|
13107
|
-
|
|
13108
|
-
|
|
13109
|
-
|
|
13110
|
-
|
|
13111
|
-
|
|
13112
|
-
|
|
13113
|
-
|
|
13114
|
-
|
|
12998
|
+
push: function (...args) {
|
|
12999
|
+
if (this._inProgress) {
|
|
13000
|
+
return -1;
|
|
13001
|
+
}
|
|
13002
|
+
let goodAdds = this._getGoodAdds(args);
|
|
13003
|
+
if (!goodAdds.length) {
|
|
13004
|
+
return this.length;
|
|
13005
|
+
}
|
|
13006
|
+
this._beforeChange();
|
|
13007
|
+
let result;
|
|
13008
|
+
let objPrototype = Object.getPrototypeOf(this);
|
|
13009
|
+
if (objPrototype.push) {
|
|
13010
|
+
result = objPrototype.push.apply(this, goodAdds);
|
|
13011
|
+
}
|
|
13012
|
+
else {
|
|
13013
|
+
result = Array.prototype.push.apply(this, goodAdds);
|
|
13014
|
+
}
|
|
13015
|
+
processAdds$2(this, goodAdds);
|
|
13016
|
+
return result;
|
|
13017
|
+
},
|
|
13018
|
+
_push: function (...args) {
|
|
13019
|
+
if (this._inProgress) {
|
|
13020
|
+
return -1;
|
|
13021
|
+
}
|
|
13022
|
+
let goodAdds = args;
|
|
13023
|
+
this._beforeChange();
|
|
13024
|
+
let result;
|
|
13025
|
+
let objPrototype = Object.getPrototypeOf(this);
|
|
13026
|
+
if (objPrototype.push) {
|
|
13027
|
+
result = objPrototype.push.apply(this, goodAdds);
|
|
13028
|
+
}
|
|
13029
|
+
else {
|
|
13030
|
+
result = Array.prototype.push.apply(this, goodAdds);
|
|
13031
|
+
}
|
|
13032
|
+
processAdds$2(this, goodAdds);
|
|
13033
|
+
return result;
|
|
13034
|
+
},
|
|
13035
|
+
unshift: function (...args) {
|
|
13036
|
+
let goodAdds = this._getGoodAdds(args);
|
|
13037
|
+
if (!goodAdds.length) {
|
|
13038
|
+
return this.length;
|
|
13039
|
+
}
|
|
13040
|
+
this._beforeChange();
|
|
13041
|
+
let result;
|
|
13042
|
+
let objPrototype = Object.getPrototypeOf(this);
|
|
13043
|
+
if (objPrototype.unshift) {
|
|
13044
|
+
result = objPrototype.unshift.apply(this, goodAdds);
|
|
13045
|
+
}
|
|
13046
|
+
else {
|
|
13047
|
+
result = Array.prototype.unshift.apply(this, goodAdds);
|
|
13048
|
+
}
|
|
13049
|
+
processAdds$2(this, goodAdds);
|
|
13050
|
+
return result;
|
|
13051
|
+
},
|
|
13052
|
+
pop: function () {
|
|
13053
|
+
this._beforeChange();
|
|
13054
|
+
let result;
|
|
13055
|
+
let objPrototype = Object.getPrototypeOf(this);
|
|
13056
|
+
if (objPrototype.pop) {
|
|
13057
|
+
result = objPrototype.pop.apply(this);
|
|
13058
|
+
}
|
|
13059
|
+
else {
|
|
13060
|
+
result = Array.prototype.pop.apply(this);
|
|
13061
|
+
}
|
|
13062
|
+
processRemoves$2(this, [result]);
|
|
13063
|
+
return result;
|
|
13064
|
+
},
|
|
13065
|
+
shift: function () {
|
|
13066
|
+
this._beforeChange();
|
|
13067
|
+
let result;
|
|
13068
|
+
let objPrototype = Object.getPrototypeOf(this);
|
|
13069
|
+
if (objPrototype.shift) {
|
|
13070
|
+
result = objPrototype.shift.apply(this);
|
|
13071
|
+
}
|
|
13072
|
+
else {
|
|
13073
|
+
result = Array.prototype.shift.apply(this);
|
|
13074
|
+
}
|
|
13075
|
+
processRemoves$2(this, [result]);
|
|
13076
|
+
return result;
|
|
13077
|
+
},
|
|
13078
|
+
splice: function (...args) {
|
|
13079
|
+
let goodAdds = this._getGoodAdds(core.arraySlice(args, 2));
|
|
13080
|
+
let newArgs = core.arraySlice(args, 0, 2).concat(goodAdds);
|
|
13081
|
+
this._beforeChange();
|
|
13082
|
+
let result;
|
|
13083
|
+
let objPrototype = Object.getPrototypeOf(this);
|
|
13084
|
+
if (objPrototype.splice) {
|
|
13085
|
+
result = objPrototype.splice.apply(this, newArgs);
|
|
13086
|
+
}
|
|
13087
|
+
else {
|
|
13088
|
+
result = Array.prototype.splice.apply(this, newArgs);
|
|
13089
|
+
}
|
|
13090
|
+
processRemoves$2(this, result);
|
|
13091
|
+
if (goodAdds.length) {
|
|
13092
|
+
processAdds$2(this, goodAdds);
|
|
13093
|
+
}
|
|
13094
|
+
return result;
|
|
13095
|
+
},
|
|
13096
|
+
getEntityAspect: function () {
|
|
13097
|
+
return this.parent.entityAspect || this.parent.complexAspect.getEntityAspect();
|
|
13098
|
+
},
|
|
13099
|
+
_getEventParent: function () {
|
|
13100
|
+
return this.getEntityAspect();
|
|
13101
|
+
},
|
|
13102
|
+
_getPendingPubs: function () {
|
|
13103
|
+
let em = this.getEntityAspect().entityManager;
|
|
13104
|
+
return em && em._pendingPubs;
|
|
13105
|
+
},
|
|
13106
|
+
_beforeChange: function () {
|
|
13107
|
+
// default is to do nothing
|
|
13108
|
+
}
|
|
13115
13109
|
};
|
|
13116
13110
|
function updateEntityState(obsArray) {
|
|
13117
13111
|
let entityAspect = obsArray.getEntityAspect();
|
|
@@ -13144,14 +13138,14 @@ function initializeParent(obsArray, parent, parentProperty) {
|
|
|
13144
13138
|
obsArray.parent = parent;
|
|
13145
13139
|
obsArray.parentProperty = parentProperty;
|
|
13146
13140
|
}
|
|
13147
|
-
function processAdds(obsArray, adds) {
|
|
13141
|
+
function processAdds$2(obsArray, adds) {
|
|
13148
13142
|
obsArray._processAdds(adds);
|
|
13149
13143
|
// this is referencing the name of the method on the complexArray not the name of the event
|
|
13150
13144
|
//var args = { added: adds };
|
|
13151
13145
|
//args[obsArray._typeName] = obsArray;
|
|
13152
13146
|
publish(obsArray, "arrayChanged", { array: obsArray, added: adds });
|
|
13153
13147
|
}
|
|
13154
|
-
function processRemoves(obsArray, removes) {
|
|
13148
|
+
function processRemoves$2(obsArray, removes) {
|
|
13155
13149
|
obsArray._processRemoves(removes);
|
|
13156
13150
|
// this is referencing the name of the method on the array not the name of the event
|
|
13157
13151
|
publish(obsArray, "arrayChanged", { array: obsArray, removed: removes });
|
|
@@ -13182,23 +13176,6 @@ const observableArray = {
|
|
|
13182
13176
|
initializeParent: initializeParent
|
|
13183
13177
|
};
|
|
13184
13178
|
|
|
13185
|
-
const ɵ0$4 = function (callback, errorCallback) {
|
|
13186
|
-
let parent = this.parentEntity;
|
|
13187
|
-
let query = EntityQuery.fromEntityNavigation(this.parentEntity, this.navigationProperty);
|
|
13188
|
-
let em = parent.entityAspect.entityManager;
|
|
13189
|
-
return em.executeQuery(query, callback, errorCallback);
|
|
13190
|
-
}, ɵ1$3 = function () {
|
|
13191
|
-
return this.parentEntity.entityAspect;
|
|
13192
|
-
}, ɵ2$2 = function () {
|
|
13193
|
-
let em = this.parentEntity.entityAspect.entityManager;
|
|
13194
|
-
return em && em._pendingPubs;
|
|
13195
|
-
}, ɵ3$2 = function (adds) {
|
|
13196
|
-
return getGoodAdds(this, adds);
|
|
13197
|
-
}, ɵ4$2 = function (adds) {
|
|
13198
|
-
processAdds$1(this, adds);
|
|
13199
|
-
}, ɵ5$2 = function (removes) {
|
|
13200
|
-
processRemoves$1(this, removes);
|
|
13201
|
-
};
|
|
13202
13179
|
let relationArrayMixin = {
|
|
13203
13180
|
/**
|
|
13204
13181
|
Relation arrays are not actually classes, they are objects that mimic arrays. A relation array is collection of
|
|
@@ -13235,15 +13212,31 @@ let relationArrayMixin = {
|
|
|
13235
13212
|
@param [errorCallback] {Function}
|
|
13236
13213
|
@return {Promise}
|
|
13237
13214
|
**/
|
|
13238
|
-
load:
|
|
13239
|
-
|
|
13240
|
-
|
|
13215
|
+
load: function (callback, errorCallback) {
|
|
13216
|
+
let parent = this.parentEntity;
|
|
13217
|
+
let query = EntityQuery.fromEntityNavigation(this.parentEntity, this.navigationProperty);
|
|
13218
|
+
let em = parent.entityAspect.entityManager;
|
|
13219
|
+
return em.executeQuery(query, callback, errorCallback);
|
|
13220
|
+
},
|
|
13221
|
+
_getEventParent: function () {
|
|
13222
|
+
return this.parentEntity.entityAspect;
|
|
13223
|
+
},
|
|
13224
|
+
_getPendingPubs: function () {
|
|
13225
|
+
let em = this.parentEntity.entityAspect.entityManager;
|
|
13226
|
+
return em && em._pendingPubs;
|
|
13227
|
+
},
|
|
13241
13228
|
// virtual impls
|
|
13242
|
-
_getGoodAdds:
|
|
13243
|
-
|
|
13244
|
-
|
|
13229
|
+
_getGoodAdds: function (adds) {
|
|
13230
|
+
return getGoodAdds$1(this, adds);
|
|
13231
|
+
},
|
|
13232
|
+
_processAdds: function (adds) {
|
|
13233
|
+
processAdds$1(this, adds);
|
|
13234
|
+
},
|
|
13235
|
+
_processRemoves: function (removes) {
|
|
13236
|
+
processRemoves$1(this, removes);
|
|
13237
|
+
}
|
|
13245
13238
|
};
|
|
13246
|
-
function getGoodAdds(relationArray, adds) {
|
|
13239
|
+
function getGoodAdds$1(relationArray, adds) {
|
|
13247
13240
|
let goodAdds = checkForDups(relationArray, adds);
|
|
13248
13241
|
if (!goodAdds.length) {
|
|
13249
13242
|
return goodAdds;
|
|
@@ -13351,28 +13344,6 @@ function makeRelationArray(arr, parentEntity, navigationProperty) {
|
|
|
13351
13344
|
return core.extend(arrX, relationArrayMixin);
|
|
13352
13345
|
}
|
|
13353
13346
|
|
|
13354
|
-
const ɵ0$5 = function (adds) {
|
|
13355
|
-
return getGoodAdds$1(this, adds);
|
|
13356
|
-
}, ɵ1$4 = function () {
|
|
13357
|
-
observableArray.updateEntityState(this);
|
|
13358
|
-
}, ɵ2$3 = function (adds) {
|
|
13359
|
-
processAdds$2(this, adds);
|
|
13360
|
-
}, ɵ3$3 = function (removes) {
|
|
13361
|
-
processRemoves$2(this, removes);
|
|
13362
|
-
}, ɵ4$3 = function () {
|
|
13363
|
-
if (!this._origValues)
|
|
13364
|
-
return;
|
|
13365
|
-
let that = this;
|
|
13366
|
-
this.forEach(function (co) {
|
|
13367
|
-
clearAspect(co, that);
|
|
13368
|
-
});
|
|
13369
|
-
this.length = 0;
|
|
13370
|
-
this._origValues.forEach(function (co) {
|
|
13371
|
-
that.push(co);
|
|
13372
|
-
});
|
|
13373
|
-
}, ɵ5$3 = function () {
|
|
13374
|
-
this._origValues = null;
|
|
13375
|
-
};
|
|
13376
13347
|
let complexArrayMixin = {
|
|
13377
13348
|
// complexArray will have the following props
|
|
13378
13349
|
// parent
|
|
@@ -13407,22 +13378,43 @@ let complexArrayMixin = {
|
|
|
13407
13378
|
@readOnly
|
|
13408
13379
|
**/
|
|
13409
13380
|
// virtual impls
|
|
13410
|
-
_getGoodAdds:
|
|
13411
|
-
|
|
13412
|
-
|
|
13413
|
-
|
|
13414
|
-
|
|
13415
|
-
|
|
13381
|
+
_getGoodAdds: function (adds) {
|
|
13382
|
+
return getGoodAdds(this, adds);
|
|
13383
|
+
},
|
|
13384
|
+
_beforeChange: function () {
|
|
13385
|
+
observableArray.updateEntityState(this);
|
|
13386
|
+
},
|
|
13387
|
+
_processAdds: function (adds) {
|
|
13388
|
+
processAdds(this, adds);
|
|
13389
|
+
},
|
|
13390
|
+
_processRemoves: function (removes) {
|
|
13391
|
+
processRemoves(this, removes);
|
|
13392
|
+
},
|
|
13393
|
+
_rejectChanges: function () {
|
|
13394
|
+
if (!this._origValues)
|
|
13395
|
+
return;
|
|
13396
|
+
let that = this;
|
|
13397
|
+
this.forEach(function (co) {
|
|
13398
|
+
clearAspect(co, that);
|
|
13399
|
+
});
|
|
13400
|
+
this.length = 0;
|
|
13401
|
+
this._origValues.forEach(function (co) {
|
|
13402
|
+
that.push(co);
|
|
13403
|
+
});
|
|
13404
|
+
},
|
|
13405
|
+
_acceptChanges: function () {
|
|
13406
|
+
this._origValues = null;
|
|
13407
|
+
}
|
|
13416
13408
|
};
|
|
13417
13409
|
// local functions
|
|
13418
|
-
function getGoodAdds
|
|
13410
|
+
function getGoodAdds(complexArray, adds) {
|
|
13419
13411
|
// remove any that are already added here
|
|
13420
13412
|
return adds.filter(function (a) {
|
|
13421
13413
|
// return a.parent !== complexArray.parent; // TODO: check if this is actually a bug in original breezejs ???
|
|
13422
13414
|
return a.complexAspect == null || a.complexAspect.parent !== complexArray.parent;
|
|
13423
13415
|
});
|
|
13424
13416
|
}
|
|
13425
|
-
function processAdds
|
|
13417
|
+
function processAdds(complexArray, adds) {
|
|
13426
13418
|
adds.forEach(function (a) {
|
|
13427
13419
|
// if (a.parent != null) { // TODO: check if this is actually a bug in original breezejs ???
|
|
13428
13420
|
if (a.complexAspect && a.complexAspect.parent != null) {
|
|
@@ -13431,7 +13423,7 @@ function processAdds$2(complexArray, adds) {
|
|
|
13431
13423
|
setAspect(a, complexArray);
|
|
13432
13424
|
});
|
|
13433
13425
|
}
|
|
13434
|
-
function processRemoves
|
|
13426
|
+
function processRemoves(complexArray, removes) {
|
|
13435
13427
|
removes.forEach(function (a) {
|
|
13436
13428
|
clearAspect(a, complexArray);
|
|
13437
13429
|
});
|
|
@@ -13466,28 +13458,6 @@ function makeComplexArray(arr, parent, parentProperty) {
|
|
|
13466
13458
|
return core.extend(arrX, complexArrayMixin);
|
|
13467
13459
|
}
|
|
13468
13460
|
|
|
13469
|
-
const ɵ0$6 = function (adds) {
|
|
13470
|
-
return adds;
|
|
13471
|
-
}, ɵ1$5 = function () {
|
|
13472
|
-
let entityAspect = this.getEntityAspect();
|
|
13473
|
-
if (entityAspect.entityState.isUnchanged()) {
|
|
13474
|
-
entityAspect.setModified();
|
|
13475
|
-
}
|
|
13476
|
-
if (entityAspect.entityState.isModified() && !this._origValues) {
|
|
13477
|
-
this._origValues = this.slice(0);
|
|
13478
|
-
}
|
|
13479
|
-
}, ɵ2$4 = function (adds) {
|
|
13480
|
-
// nothing needed
|
|
13481
|
-
}, ɵ3$4 = function (removes) {
|
|
13482
|
-
// nothing needed;
|
|
13483
|
-
}, ɵ4$4 = function () {
|
|
13484
|
-
if (!this._origValues)
|
|
13485
|
-
return;
|
|
13486
|
-
this.length = 0;
|
|
13487
|
-
Array.prototype.push.apply(this, this._origValues);
|
|
13488
|
-
}, ɵ5$4 = function () {
|
|
13489
|
-
this._origValues = null;
|
|
13490
|
-
};
|
|
13491
13461
|
// TODO: mixin impl is not very typesafe
|
|
13492
13462
|
// Not needed
|
|
13493
13463
|
// interface IPrimitiveArray extends IObservableArray {
|
|
@@ -13529,12 +13499,33 @@ let primitiveArrayMixin = {
|
|
|
13529
13499
|
@readOnly
|
|
13530
13500
|
**/
|
|
13531
13501
|
// virtual impls
|
|
13532
|
-
_getGoodAdds:
|
|
13533
|
-
|
|
13534
|
-
|
|
13535
|
-
|
|
13536
|
-
|
|
13537
|
-
|
|
13502
|
+
_getGoodAdds: function (adds) {
|
|
13503
|
+
return adds;
|
|
13504
|
+
},
|
|
13505
|
+
_beforeChange: function () {
|
|
13506
|
+
let entityAspect = this.getEntityAspect();
|
|
13507
|
+
if (entityAspect.entityState.isUnchanged()) {
|
|
13508
|
+
entityAspect.setModified();
|
|
13509
|
+
}
|
|
13510
|
+
if (entityAspect.entityState.isModified() && !this._origValues) {
|
|
13511
|
+
this._origValues = this.slice(0);
|
|
13512
|
+
}
|
|
13513
|
+
},
|
|
13514
|
+
_processAdds: function (adds) {
|
|
13515
|
+
// nothing needed
|
|
13516
|
+
},
|
|
13517
|
+
_processRemoves: function (removes) {
|
|
13518
|
+
// nothing needed;
|
|
13519
|
+
},
|
|
13520
|
+
_rejectChanges: function () {
|
|
13521
|
+
if (!this._origValues)
|
|
13522
|
+
return;
|
|
13523
|
+
this.length = 0;
|
|
13524
|
+
Array.prototype.push.apply(this, this._origValues);
|
|
13525
|
+
},
|
|
13526
|
+
_acceptChanges: function () {
|
|
13527
|
+
this._origValues = null;
|
|
13528
|
+
}
|
|
13538
13529
|
};
|
|
13539
13530
|
// local functions
|
|
13540
13531
|
/** For use by breeze plugin authors only. The class is for use in building a [[IModelLibraryAdapter]] implementation.
|
|
@@ -13592,7 +13583,7 @@ const breeze = {
|
|
|
13592
13583
|
ValidationError: ValidationError,
|
|
13593
13584
|
ValidationOptions: ValidationOptions,
|
|
13594
13585
|
Validator: Validator,
|
|
13595
|
-
version: "2.1.
|
|
13586
|
+
version: "2.1.4"
|
|
13596
13587
|
};
|
|
13597
13588
|
/** @hidden @internal */
|
|
13598
13589
|
let win;
|
|
@@ -13609,5 +13600,5 @@ if (win) {
|
|
|
13609
13600
|
* Generated bundle index. Do not edit.
|
|
13610
13601
|
*/
|
|
13611
13602
|
|
|
13612
|
-
export { AbstractDataServiceAdapter, AndOrPredicate, AnyAllPredicate, AutoGeneratedKeyType, BinaryPredicate, BreezeConfig, BreezeEnum, BreezeEvent, ComplexAspect, ComplexType, DataProperty, DataService, DataType, EntityAction, EntityAspect, EntityKey, EntityManager, EntityQuery, EntityState, EntityType, ExpandClause, FetchStrategy, FilterQueryOp, FnExpr, InterfaceRegistry, JsonResultsAdapter, KeyGenerator, LitExpr, LocalQueryComparisonOptions, MappingContext, MergeStrategy, MetadataStore, NamingConvention, NavigationProperty, OrderByClause, Predicate, PropExpr, QueryOptions, SaveOptions, SelectClause, UnaryPredicate, ValidationError, ValidationOptions, Validator, assertConfig, assertParam, breeze, config, core, makeComplexArray, makePrimitiveArray, makeRelationArray
|
|
13613
|
-
//# sourceMappingURL=breeze-client.
|
|
13603
|
+
export { AbstractDataServiceAdapter, AndOrPredicate, AnyAllPredicate, AutoGeneratedKeyType, BinaryPredicate, BreezeConfig, BreezeEnum, BreezeEvent, ComplexAspect, ComplexType, DataProperty, DataService, DataType, EntityAction, EntityAspect, EntityKey, EntityManager, EntityQuery, EntityState, EntityType, ExpandClause, FetchStrategy, FilterQueryOp, FnExpr, InterfaceRegistry, JsonResultsAdapter, KeyGenerator, LitExpr, LocalQueryComparisonOptions, MappingContext, MergeStrategy, MetadataStore, NamingConvention, NavigationProperty, OrderByClause, Predicate, PropExpr, QueryOptions, SaveOptions, SelectClause, UnaryPredicate, ValidationError, ValidationOptions, Validator, assertConfig, assertParam, breeze, config, core, makeComplexArray, makePrimitiveArray, makeRelationArray };
|
|
13604
|
+
//# sourceMappingURL=breeze-client.mjs.map
|