igniteui-webcomponents-datasources 1.4.1 → 1.4.2
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/bundles/igniteui-webcomponents-datasources.umd.js +2279 -1
- package/bundles/igniteui-webcomponents-datasources.umd.min.js +7 -2
- package/esm2015/igniteui-webcomponents-datasources.js +0 -1
- package/esm2015/lib/Entity.js +0 -1
- package/esm2015/lib/EntityProperty.js +0 -1
- package/esm2015/lib/EntitySet.js +0 -1
- package/esm2015/lib/ODataDataSourcePage.js +0 -1
- package/esm2015/lib/ODataSchemaProvider.js +0 -1
- package/esm2015/lib/ODataVirtualDataSource.js +0 -1
- package/esm2015/lib/ODataVirtualDataSourceDataProvider.js +0 -1
- package/esm2015/lib/ODataVirtualDataSourceDataProviderWorker.js +0 -1
- package/esm2015/lib/ODataVirtualDataSourceDataProviderWorkerSettings.js +0 -1
- package/esm2015/lib/ODataVirtualDataSourceProviderTaskDataHolder.js +0 -1
- package/esm2015/lib/RestVirtualDataSource.js +272 -0
- package/esm2015/lib/RestVirtualDataSourceDataProvider.js +528 -0
- package/esm2015/lib/RestVirtualDataSourceDataProviderWorker.js +744 -0
- package/esm2015/lib/RestVirtualDataSourceDataProviderWorkerSettings.js +154 -0
- package/esm2015/lib/RestVirtualDataSourcePage.js +67 -0
- package/esm2015/lib/RestVirtualDataSourceProviderTaskDataHolder.js +8 -0
- package/esm2015/lib/Schema.js +0 -1
- package/esm2015/lib/util.js +0 -1
- package/esm2015/public_api.js +6 -1
- package/esm5/igniteui-webcomponents-datasources.js +0 -1
- package/esm5/lib/Entity.js +0 -1
- package/esm5/lib/EntityProperty.js +0 -1
- package/esm5/lib/EntitySet.js +0 -1
- package/esm5/lib/ODataDataSourcePage.js +0 -1
- package/esm5/lib/ODataSchemaProvider.js +0 -1
- package/esm5/lib/ODataVirtualDataSource.js +0 -1
- package/esm5/lib/ODataVirtualDataSourceDataProvider.js +0 -1
- package/esm5/lib/ODataVirtualDataSourceDataProviderWorker.js +0 -1
- package/esm5/lib/ODataVirtualDataSourceDataProviderWorkerSettings.js +0 -1
- package/esm5/lib/ODataVirtualDataSourceProviderTaskDataHolder.js +0 -1
- package/esm5/lib/RestVirtualDataSource.js +357 -0
- package/esm5/lib/RestVirtualDataSourceDataProvider.js +675 -0
- package/esm5/lib/RestVirtualDataSourceDataProviderWorker.js +948 -0
- package/esm5/lib/RestVirtualDataSourceDataProviderWorkerSettings.js +240 -0
- package/esm5/lib/RestVirtualDataSourcePage.js +73 -0
- package/esm5/lib/RestVirtualDataSourceProviderTaskDataHolder.js +12 -0
- package/esm5/lib/Schema.js +0 -1
- package/esm5/lib/util.js +0 -1
- package/esm5/public_api.js +6 -1
- package/fesm2015/igniteui-webcomponents-datasources.js +1754 -3
- package/fesm5/igniteui-webcomponents-datasources.js +2275 -3
- package/lib/RestVirtualDataSource.d.ts +60 -0
- package/lib/RestVirtualDataSourceDataProvider.d.ts +135 -0
- package/lib/RestVirtualDataSourceDataProviderWorker.d.ts +69 -0
- package/lib/RestVirtualDataSourceDataProviderWorkerSettings.d.ts +60 -0
- package/lib/RestVirtualDataSourcePage.d.ts +19 -0
- package/lib/RestVirtualDataSourceProviderTaskDataHolder.d.ts +5 -0
- package/package.json +2 -2
- package/public_api.d.ts +6 -0
- package/bundles/igniteui-webcomponents-datasources.umd.js.map +0 -1
- package/bundles/igniteui-webcomponents-datasources.umd.min.js.map +0 -1
- package/esm2015/igniteui-webcomponents-datasources.js.map +0 -1
- package/esm2015/lib/Entity.js.map +0 -1
- package/esm2015/lib/EntityProperty.js.map +0 -1
- package/esm2015/lib/EntitySet.js.map +0 -1
- package/esm2015/lib/ODataDataSourcePage.js.map +0 -1
- package/esm2015/lib/ODataSchemaProvider.js.map +0 -1
- package/esm2015/lib/ODataVirtualDataSource.js.map +0 -1
- package/esm2015/lib/ODataVirtualDataSourceDataProvider.js.map +0 -1
- package/esm2015/lib/ODataVirtualDataSourceDataProviderWorker.js.map +0 -1
- package/esm2015/lib/ODataVirtualDataSourceDataProviderWorkerSettings.js.map +0 -1
- package/esm2015/lib/ODataVirtualDataSourceProviderTaskDataHolder.js.map +0 -1
- package/esm2015/lib/Schema.js.map +0 -1
- package/esm2015/lib/util.js.map +0 -1
- package/esm2015/public_api.js.map +0 -1
- package/esm5/igniteui-webcomponents-datasources.js.map +0 -1
- package/esm5/lib/Entity.js.map +0 -1
- package/esm5/lib/EntityProperty.js.map +0 -1
- package/esm5/lib/EntitySet.js.map +0 -1
- package/esm5/lib/ODataDataSourcePage.js.map +0 -1
- package/esm5/lib/ODataSchemaProvider.js.map +0 -1
- package/esm5/lib/ODataVirtualDataSource.js.map +0 -1
- package/esm5/lib/ODataVirtualDataSourceDataProvider.js.map +0 -1
- package/esm5/lib/ODataVirtualDataSourceDataProviderWorker.js.map +0 -1
- package/esm5/lib/ODataVirtualDataSourceDataProviderWorkerSettings.js.map +0 -1
- package/esm5/lib/ODataVirtualDataSourceProviderTaskDataHolder.js.map +0 -1
- package/esm5/lib/Schema.js.map +0 -1
- package/esm5/lib/util.js.map +0 -1
- package/esm5/public_api.js.map +0 -1
- package/fesm2015/igniteui-webcomponents-datasources.js.map +0 -1
- package/fesm5/igniteui-webcomponents-datasources.js.map +0 -1
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
import { VirtualDataSource } from "igniteui-webcomponents-core";
|
|
2
|
+
import { RestVirtualDataSourceDataProvider } from "./RestVirtualDataSourceDataProvider";
|
|
3
|
+
export class RestVirtualDataSource extends VirtualDataSource {
|
|
4
|
+
constructor() {
|
|
5
|
+
super();
|
|
6
|
+
this._baseUri = null;
|
|
7
|
+
this._isFilteringSupportedByServer = false;
|
|
8
|
+
this._entitySet = null;
|
|
9
|
+
this._timeoutMilliseconds = 10000;
|
|
10
|
+
this._isAggregationSupportedByServer = false;
|
|
11
|
+
this._enableJsonp = true;
|
|
12
|
+
this._fixedFullCount = -1;
|
|
13
|
+
this._provideFullCount = null;
|
|
14
|
+
this._provideOrderByParameter = null;
|
|
15
|
+
this._provideFilterParameter = null;
|
|
16
|
+
this._provideAggregationParameter = null;
|
|
17
|
+
this._provideAggregatedCount = null;
|
|
18
|
+
this._provideUri = null;
|
|
19
|
+
this._performFetch = null;
|
|
20
|
+
this._providePagingParameter = null;
|
|
21
|
+
this._provideDesiredPropertiesParameter = null;
|
|
22
|
+
this.dataProvider = ((() => {
|
|
23
|
+
let $ret = new RestVirtualDataSourceDataProvider();
|
|
24
|
+
$ret.executionContext = this.executionContext;
|
|
25
|
+
$ret.enableJsonp = this.enableJsonp;
|
|
26
|
+
$ret.isAggregationSupported = this.isGroupingSupported;
|
|
27
|
+
return $ret;
|
|
28
|
+
})());
|
|
29
|
+
this.externalDataSource = this;
|
|
30
|
+
}
|
|
31
|
+
onBaseUriChanged(oldValue, newValue) {
|
|
32
|
+
if (this.actualDataProvider) {
|
|
33
|
+
this.actualDataProvider.baseUri = this.baseUri;
|
|
34
|
+
this.queueAutoRefresh();
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
get baseUri() {
|
|
38
|
+
return this._baseUri;
|
|
39
|
+
}
|
|
40
|
+
set baseUri(value) {
|
|
41
|
+
let oldValue = this._baseUri;
|
|
42
|
+
this._baseUri = value;
|
|
43
|
+
if (oldValue != this._baseUri) {
|
|
44
|
+
this.onBaseUriChanged(oldValue, this._baseUri);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
onEntitySetChanged(oldValue, newValue) {
|
|
48
|
+
if (this.actualDataProvider) {
|
|
49
|
+
this.actualDataProvider.entitySet = this.entitySet;
|
|
50
|
+
this.queueAutoRefresh();
|
|
51
|
+
}
|
|
52
|
+
this.queueAutoRefresh();
|
|
53
|
+
}
|
|
54
|
+
set isFilteringSupportedByServer(v) {
|
|
55
|
+
this._isFilteringSupportedByServer = v;
|
|
56
|
+
}
|
|
57
|
+
get isFilteringSupportedByServer() {
|
|
58
|
+
return this._isFilteringSupportedByServer;
|
|
59
|
+
}
|
|
60
|
+
get_isFilteringSupported() {
|
|
61
|
+
if (this._isFilteringSupportedByServer) {
|
|
62
|
+
return true;
|
|
63
|
+
}
|
|
64
|
+
return false;
|
|
65
|
+
}
|
|
66
|
+
get entitySet() {
|
|
67
|
+
return this._entitySet;
|
|
68
|
+
}
|
|
69
|
+
set entitySet(value) {
|
|
70
|
+
let oldValue = this._entitySet;
|
|
71
|
+
this._entitySet = value;
|
|
72
|
+
if (this._entitySet != oldValue) {
|
|
73
|
+
this.onEntitySetChanged(oldValue, this._entitySet);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
onTimeoutMillisecondsChanged(oldValue, newValue) {
|
|
77
|
+
if (this.actualDataProvider) {
|
|
78
|
+
this.actualDataProvider.timeoutMilliseconds = this.timeoutMilliseconds;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
get timeoutMilliseconds() {
|
|
82
|
+
return this._timeoutMilliseconds;
|
|
83
|
+
}
|
|
84
|
+
set timeoutMilliseconds(value) {
|
|
85
|
+
let oldValue = this._timeoutMilliseconds;
|
|
86
|
+
this._timeoutMilliseconds = value;
|
|
87
|
+
if (oldValue != this._timeoutMilliseconds) {
|
|
88
|
+
this.onTimeoutMillisecondsChanged(oldValue, this._timeoutMilliseconds);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
get isSortingSupportedOverride() {
|
|
92
|
+
return true;
|
|
93
|
+
}
|
|
94
|
+
get isFilteringSupportedOverride() {
|
|
95
|
+
return true;
|
|
96
|
+
}
|
|
97
|
+
get isGroupingSupportedOverride() {
|
|
98
|
+
return this.isAggregationSupportedByServer;
|
|
99
|
+
}
|
|
100
|
+
get isAggregationSupportedByServer() {
|
|
101
|
+
return this._isAggregationSupportedByServer;
|
|
102
|
+
}
|
|
103
|
+
set isAggregationSupportedByServer(isSupported) {
|
|
104
|
+
this._isAggregationSupportedByServer = isSupported;
|
|
105
|
+
if (this.actualDataProvider) {
|
|
106
|
+
this.actualDataProvider.isAggregationSupported = this.isAggregationSupportedByServer;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
get enableJsonp() {
|
|
110
|
+
return this._enableJsonp;
|
|
111
|
+
}
|
|
112
|
+
set enableJsonp(isEnabled) {
|
|
113
|
+
this._enableJsonp = isEnabled;
|
|
114
|
+
if (this.actualDataProvider) {
|
|
115
|
+
this.actualDataProvider.enableJsonp = this.enableJsonp;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
get fixedFullCount() {
|
|
119
|
+
return this._fixedFullCount;
|
|
120
|
+
}
|
|
121
|
+
set fixedFullCount(value) {
|
|
122
|
+
this._fixedFullCount = value;
|
|
123
|
+
}
|
|
124
|
+
get provideFullCount() {
|
|
125
|
+
return this._provideFullCount;
|
|
126
|
+
}
|
|
127
|
+
set provideFullCount(value) {
|
|
128
|
+
this._provideFullCount = value;
|
|
129
|
+
if (this.actualDataProvider) {
|
|
130
|
+
this.actualDataProvider.provideFullCount = this.provideFullCount;
|
|
131
|
+
this.queueAutoRefresh();
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
get provideOrderByParameter() {
|
|
135
|
+
return this._provideOrderByParameter;
|
|
136
|
+
}
|
|
137
|
+
set provideOrderByParameter(value) {
|
|
138
|
+
this._provideOrderByParameter = value;
|
|
139
|
+
if (this.actualDataProvider) {
|
|
140
|
+
this.actualDataProvider.provideOrderByParameter = this.provideOrderByParameter;
|
|
141
|
+
this.queueAutoRefresh();
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
get provideFilterParameter() {
|
|
145
|
+
return this._provideFilterParameter;
|
|
146
|
+
}
|
|
147
|
+
set provideFilterParameter(value) {
|
|
148
|
+
this._provideFilterParameter = value;
|
|
149
|
+
if (this.actualDataProvider) {
|
|
150
|
+
this.actualDataProvider.provideFilterParameter = this.provideFilterParameter;
|
|
151
|
+
this.queueAutoRefresh();
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
get provideAggregationParameter() {
|
|
155
|
+
return this._provideAggregationParameter;
|
|
156
|
+
}
|
|
157
|
+
set provideAggregationParameter(value) {
|
|
158
|
+
this._provideAggregationParameter = value;
|
|
159
|
+
if (this.actualDataProvider) {
|
|
160
|
+
this.actualDataProvider.provideAggregationParameter = this.provideAggregationParameter;
|
|
161
|
+
this.queueAutoRefresh();
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
get provideAggregatedCount() {
|
|
165
|
+
return this._provideAggregatedCount;
|
|
166
|
+
}
|
|
167
|
+
set provideAggregatedCount(value) {
|
|
168
|
+
this._provideAggregatedCount = value;
|
|
169
|
+
if (this.actualDataProvider) {
|
|
170
|
+
this.actualDataProvider.provideAggregatedCount = this.provideAggregatedCount;
|
|
171
|
+
this.queueAutoRefresh();
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
get provideUri() {
|
|
175
|
+
return this._provideUri;
|
|
176
|
+
}
|
|
177
|
+
set provideUri(value) {
|
|
178
|
+
this._provideUri = value;
|
|
179
|
+
if (this.actualDataProvider) {
|
|
180
|
+
this.actualDataProvider.provideUri = this.provideUri;
|
|
181
|
+
this.queueAutoRefresh();
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
get performFetch() {
|
|
185
|
+
return this._performFetch;
|
|
186
|
+
}
|
|
187
|
+
set performFetch(value) {
|
|
188
|
+
this._performFetch = value;
|
|
189
|
+
if (this.actualDataProvider) {
|
|
190
|
+
this.actualDataProvider.performFetch = this.performFetch;
|
|
191
|
+
this.queueAutoRefresh();
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
get providePagingParameter() {
|
|
195
|
+
return this._providePagingParameter;
|
|
196
|
+
}
|
|
197
|
+
set providePagingParameter(value) {
|
|
198
|
+
this._providePagingParameter = value;
|
|
199
|
+
if (this.actualDataProvider) {
|
|
200
|
+
this.actualDataProvider.providePagingParameter = this.providePagingParameter;
|
|
201
|
+
this.queueAutoRefresh();
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
get provideDesiredPropertiesParameter() {
|
|
205
|
+
return this._provideDesiredPropertiesParameter;
|
|
206
|
+
}
|
|
207
|
+
set provideDesiredPropertiesParameter(value) {
|
|
208
|
+
this._provideDesiredPropertiesParameter = value;
|
|
209
|
+
if (this.actualDataProvider) {
|
|
210
|
+
this.actualDataProvider.provideDesiredPropertiesParameter = this.provideDesiredPropertiesParameter;
|
|
211
|
+
this.queueAutoRefresh();
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
get provideItems() {
|
|
215
|
+
return this._provideItems;
|
|
216
|
+
}
|
|
217
|
+
set provideItems(value) {
|
|
218
|
+
this._provideItems = value;
|
|
219
|
+
if (this.actualDataProvider) {
|
|
220
|
+
this.actualDataProvider.provideItems = this.provideItems;
|
|
221
|
+
this.queueAutoRefresh();
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
clone() {
|
|
225
|
+
let dataSource = new RestVirtualDataSource();
|
|
226
|
+
dataSource.executionContext = this.executionContext;
|
|
227
|
+
dataSource.includeSummaryRowsInSection = this.includeSummaryRowsInSection;
|
|
228
|
+
dataSource.isSectionCollapsable = this.isSectionCollapsable;
|
|
229
|
+
dataSource.isSectionExpandedDefault = this.isSectionExpandedDefault;
|
|
230
|
+
//dataSource.isSectionHeaderNormalRow = this.isSectionHeaderNormalRow;
|
|
231
|
+
dataSource.isSectionSummaryRowsAtBottom = this.isSectionSummaryRowsAtBottom;
|
|
232
|
+
//dataSource.isSectionContentVisible = this.isSectionContentVisible;
|
|
233
|
+
dataSource.primaryKey = this.primaryKey;
|
|
234
|
+
dataSource.propertiesRequested = this.propertiesRequested;
|
|
235
|
+
dataSource.sectionHeaderDisplayMode = this.sectionHeaderDisplayMode;
|
|
236
|
+
dataSource.shouldEmitSectionFooters = this.shouldEmitSectionFooters;
|
|
237
|
+
dataSource.shouldEmitSectionHeaders = this.shouldEmitSectionHeaders;
|
|
238
|
+
dataSource.shouldEmitShiftedRows = this.shouldEmitShiftedRows;
|
|
239
|
+
dataSource.summaryScope = this.summaryScope;
|
|
240
|
+
for (var i = 0; i < this.groupDescriptions.size(); i++) {
|
|
241
|
+
dataSource.groupDescriptions.add(this.groupDescriptions.get(i));
|
|
242
|
+
}
|
|
243
|
+
for (var i = 0; i < this.sortDescriptions.size(); i++) {
|
|
244
|
+
dataSource.sortDescriptions.add(this.sortDescriptions.get(i));
|
|
245
|
+
}
|
|
246
|
+
for (var i = 0; i < this.filterExpressions.size(); i++) {
|
|
247
|
+
dataSource.filterExpressions.add(this.filterExpressions.get(i));
|
|
248
|
+
}
|
|
249
|
+
for (var i = 0; i < this.summaryDescriptions.size(); i++) {
|
|
250
|
+
dataSource.summaryDescriptions.add(this.summaryDescriptions.get(i));
|
|
251
|
+
}
|
|
252
|
+
dataSource.pageSizeRequested = this.pageSizeRequested;
|
|
253
|
+
dataSource.maxCachedPages = this.maxCachedPages;
|
|
254
|
+
dataSource.baseUri = this.baseUri;
|
|
255
|
+
dataSource.entitySet = this.entitySet;
|
|
256
|
+
dataSource.timeoutMilliseconds = this.timeoutMilliseconds;
|
|
257
|
+
dataSource.isAggregationSupportedByServer = this.isAggregationSupportedByServer;
|
|
258
|
+
dataSource.enableJsonp = this.enableJsonp;
|
|
259
|
+
dataSource.fixedFullCount = this.fixedFullCount;
|
|
260
|
+
dataSource.provideAggregationParameter = this.provideAggregationParameter;
|
|
261
|
+
dataSource.provideAggregatedCount = this.provideAggregatedCount;
|
|
262
|
+
dataSource.provideFilterParameter = this.provideFilterParameter;
|
|
263
|
+
dataSource.provideFullCount = this.provideFullCount;
|
|
264
|
+
dataSource.provideOrderByParameter = this.provideOrderByParameter;
|
|
265
|
+
dataSource.provideUri = this.provideUri;
|
|
266
|
+
dataSource.performFetch = this.performFetch;
|
|
267
|
+
dataSource.providePagingParameter = this.providePagingParameter;
|
|
268
|
+
dataSource.provideItems = this.provideItems;
|
|
269
|
+
dataSource.provideDesiredPropertiesParameter = this.provideDesiredPropertiesParameter;
|
|
270
|
+
return dataSource;
|
|
271
|
+
}
|
|
272
|
+
}
|