igniteui-angular-core
Version:
Ignite UI Angular Core logic used in multiple UI components.
1,113 lines (1,112 loc) • 38.3 kB
JavaScript
/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { __extends, __values } from "tslib";
import { Base, IList_$type, runOn, String_$type, EnumUtil, typeCast, Array_$type, fromEnum, delegateRemove, delegateCombine, markType } from "./type";
import { IDataSourceLocalDataProvider_$type } from "./IDataSourceLocalDataProvider";
import { IDataSourceSchema_$type } from "./IDataSourceSchema";
import { DataSourceSchemaPropertyType_$type } from "./DataSourceSchemaPropertyType";
import { DefaultDataSourceSchema } from "./DefaultDataSourceSchema";
import { SortDescriptionCollection } from "./SortDescriptionCollection";
import { FilterExpressionCollection } from "./FilterExpressionCollection";
import { SummaryDescriptionCollection } from "./SummaryDescriptionCollection";
import { Dictionary$2 } from "./Dictionary$2";
import { FastReflectionHelper } from "./FastReflectionHelper";
import { HashSet$1 } from "./HashSet$1";
import { DataSourceDataProviderSchemaChangedEventArgs } from "./DataSourceDataProviderSchemaChangedEventArgs";
import { List$1 } from "./List$1";
import { FastIterationDictionary$2 } from "./FastIterationDictionary$2";
import { INotifyCollectionChanged_$type } from "./INotifyCollectionChanged";
import { getAllPropertyNames } from "./componentUtil";
import { stringStartsWith } from "./string";
/**
* @hidden
*/
var DataSourceLocalDataProvider = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(DataSourceLocalDataProvider, _super);
function DataSourceLocalDataProvider() {
var _this = _super.call(this) || this;
_this.o = null;
_this.n = null;
_this.g = null;
_this.p = null;
_this.f = 0;
_this.ac = 5;
_this.ad = 10;
_this.ag = null;
_this.w = new Dictionary$2(String_$type, DataSourceSchemaPropertyType_$type, 0);
_this.aj = null;
_this.schemaChanged = null;
_this.v = new Dictionary$2(String_$type, FastReflectionHelper.$, 0);
_this.x = new HashSet$1(String_$type, 0);
_this.j = null;
_this.aa = null;
_this.s = false;
_this.i = null;
_this.h = null;
_this.r = false;
_this.a = null;
_this.q = false;
_this.b = null;
_this.o = new SortDescriptionCollection();
_this.o.n(runOn(_this, _this.a3));
_this.n = new SortDescriptionCollection();
_this.p = new SummaryDescriptionCollection();
_this.g = new FilterExpressionCollection();
return _this;
}
DataSourceLocalDataProvider.prototype.a3 = function (a, b) {
this.queueAutoRefresh();
};
DataSourceLocalDataProvider.prototype.clone = function () {
var a = new DataSourceLocalDataProvider();
a.deferAutoRefresh = this.deferAutoRefresh;
a.executionContext = this.executionContext;
a.dataSource = this.dataSource;
a.propertiesRequested = this.propertiesRequested;
a.schemaHints = this.schemaHints;
a.summaryScope = this.summaryScope;
for (var b = 0; b < this.groupDescriptions.k.count; b++) {
a.groupDescriptions.add(this.groupDescriptions.k.item(b));
}
for (var c = 0; c < this.sortDescriptions.k.count; c++) {
a.sortDescriptions.add(this.sortDescriptions.k.item(c));
}
for (var d = 0; d < this.filterExpressions.k.count; d++) {
a.filterExpressions.add(this.filterExpressions.k.item(d));
}
for (var e = 0; e < this.summaryDescriptions.k.count; e++) {
a.summaryDescriptions.add(this.summaryDescriptions.k.item(e));
}
return a;
};
Object.defineProperty(DataSourceLocalDataProvider.prototype, "maxDepth", {
get: function () {
return this.ac;
},
set: function (a) {
var b = a;
this.ac = a;
if (b != a) {
this.az("MaxDepth", b, a);
}
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "maxIteration", {
get: function () {
return this.ad;
},
set: function (a) {
var b = a;
this.ad = a;
if (b != a) {
this.az("MaxIteration", b, a);
}
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "dataSource", {
get: function () {
return this.ag;
},
set: function (a) {
var b = this.ag;
this.ag = a;
if (b != this.ag) {
this.ax("ItemsSource", b, this.ag);
}
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "schemaHints", {
get: function () {
return this.aj;
},
set: function (a) {
var b = this.aj;
this.aj = a;
if (b != this.aj) {
this.ax("SchemaHints", b, this.aj);
}
},
enumerable: false,
configurable: true
});
DataSourceLocalDataProvider.prototype.ay = function () {
if (this.aj == null) {
return;
}
this.w.clear();
var a = this.aj.split(',');
for (var b = 0; b < a.length; b++) {
var c = a[b].trim().split(':');
if (c.length != 2) {
continue;
}
var d = c[0];
var e = this.d(c[1]);
this.w.addItem(d, e);
}
};
DataSourceLocalDataProvider.prototype.d = function (a) {
var b = EnumUtil.parse(DataSourceSchemaPropertyType_$type, a, true);
if (b != null) {
return EnumUtil.getEnumValue(DataSourceSchemaPropertyType_$type, b);
}
return 11;
};
DataSourceLocalDataProvider.prototype.getItemAtIndex = function (a) {
if (this.aa == null) {
return null;
}
if (this.s) {
return this.aa[a];
}
return this.aa.item(a);
};
DataSourceLocalDataProvider.prototype.getItemValue = function (a, b) {
this.as();
var c;
var d = this.v.tryGetValue(b, c);
c = d.p1;
if (c == null && !this.x.contains(b)) {
var e = b.split('.');
var f = a;
var g = true;
for (var h = 0; h < e.length; h++) {
f = f[e[h]];
if ((f === undefined)) {
g = false;
break;
}
}
if (g) {
c = new FastReflectionHelper(false, b);
this.v.addItem(b, c);
}
else {
this.x.add_1(b);
}
}
if (c == null) {
return null;
}
var val_ = c.getPropertyValue(a);
if ((val_ === undefined)) {
return null;
}
return val_;
};
DataSourceLocalDataProvider.prototype.setItemValue = function (a, b, c) {
this.as();
var d;
var e = this.v.tryGetValue(b, d);
d = e.p1;
if (d == null) {
return;
}
d.setPropertyValue(a, c);
};
DataSourceLocalDataProvider.prototype.removeItem = function (a) {
if (this.aa != null) {
var b = this.aa.indexOf(a);
if (this.s) {
this.aa.splice(b, 1);
}
else {
this.aa.removeAt(b);
}
this.notifyRemoveItem(b, a);
}
};
DataSourceLocalDataProvider.prototype.addItem = function (a) {
if (this.aa != null) {
var b = this.actualCount;
if (this.s) {
this.aa.splice(b, 0, a);
}
else {
this.aa.insert(b, a);
}
this.notifyInsertItem(this.actualCount - 1, a);
}
};
DataSourceLocalDataProvider.prototype.as = function () {
if (this.j == null) {
this.j = this.actualSchema;
if (this.schemaChanged != null) {
this.schemaChanged(this, new DataSourceDataProviderSchemaChangedEventArgs(this.j, this.actualCount));
}
}
};
Object.defineProperty(DataSourceLocalDataProvider.prototype, "actualCount", {
get: function () {
if (this.aa == null) {
return 0;
}
if (this.s) {
return (this.aa.length);
}
return this.aa.count;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "actualSchema", {
get: function () {
if (this.j == null) {
if (this.aa == null) {
this.j = new DefaultDataSourceSchema([], [], null, null, []);
}
else {
this.j = this.m();
}
}
return this.j;
},
enumerable: false,
configurable: true
});
DataSourceLocalDataProvider.prototype.m = function () {
this.v.clear();
this.x.clear();
return this.k(this.aa, this.maxIteration, this.maxDepth, null, 0);
};
DataSourceLocalDataProvider.prototype.k = function (a, b, c, d, e) {
var e_1, _a;
var _this = this;
if (e >= c) {
return null;
}
if (a == null) {
if (e == 0) {
return new DefaultDataSourceSchema([], [], null, null, []);
}
else {
return null;
}
}
var f = 0;
var g = typeCast(Array_$type, a) !== null;
if (g) {
f = (a.length);
}
else {
f = a.count;
}
if (f == 0) {
return new DefaultDataSourceSchema([], [], null, null, []);
}
var h = null;
var i = new FastIterationDictionary$2(String_$type, DataSourceSchemaPropertyType_$type, 0);
var j = new HashSet$1(String_$type, 0);
var k = 0;
var l = new List$1(List$1.$.specialize(String_$type), 0);
var m = new List$1(IDataSourceSchema_$type, 0);
if (this.schemaIncludedProperties == null || this.schemaIncludedProperties.length > 0) {
this.at(a, b, function (n, o) {
if (n == null) {
return true;
}
if ((typeof n === 'function')) {
return true;
}
if ((Array.isArray(n))) {
return true;
}
var check_ = n;
if ((check_ instanceof HTMLElement)) {
return true;
}
if ((check_ instanceof Date)) {
return false;
}
if ((typeof check_ === 'number')) {
return false;
}
if ((typeof check_ === 'string')) {
return false;
}
if ((typeof check_ === 'boolean')) {
return false;
}
if ((typeof check_ === 'bigint')) {
return false;
}
if (h == null) {
h = _this.y(n);
}
for (var p = 0; p < h.count; p++) {
var q_1 = h._inner[p];
if (j.contains(q_1)) {
continue;
}
var r = d == null ? q_1 : d + "." + q_1;
if (_this.schemaIncludedProperties != null && _this.schemaIncludedProperties.length > 0) {
var s = false;
for (var t = 0; t < _this.schemaIncludedProperties.length; t++) {
if (_this.schemaIncludedProperties[t] == r) {
s = true;
break;
}
}
if (!s) {
k++;
continue;
}
}
if (!_this.t(check_, q_1)) {
k++;
continue;
}
if (i.d(q_1)) {
i.s(q_1, 11);
_this.v.addItem(r, new FastReflectionHelper(false, r));
}
if (_this.w.containsKey(r)) {
i.item(q_1, _this.w.item(r));
_this.w.removeItem(r);
j.add_1(q_1);
k++;
}
else {
var u = _this.ai(n, q_1);
if (u != null) {
i.item(q_1, DataSourceLocalDataProvider.e(u));
j.add_1(q_1);
k++;
}
else {
continue;
}
}
l.add(_this.z(n, q_1));
if (i.item(q_1) == 11) {
var v = _this.ai(n, q_1);
if (typeCast(Array_$type, v) !== null) {
m.add(_this.k(v, b, c, r, e + 1));
}
else {
var w = new List$1(Base.$, 0);
w.add1(v);
m.add(_this.k(w, 1, c, r, e + 1));
}
}
else {
m.add(null);
}
}
return !(k == h.count);
});
try {
for (var _b = __values(fromEnum(this.w)), _c = _b.next(); !_c.done; _c = _b.next()) {
var n = _c.value;
var o = n.key.split('.');
for (var p = 0; p < o.length; p++) {
if (j.contains(o[p])) {
continue;
}
else {
i.s(o[p], p == o.length - 1 ? n.value : 11);
j.add_1(o[p]);
l.add(new List$1(String_$type, 0));
}
}
}
}
catch (e_1_1) {
e_1 = { error: e_1_1 };
}
finally {
try {
if (_c && !_c.done && (_a = _b.return))
_a.call(_b);
}
finally {
if (e_1)
throw e_1.error;
}
}
}
else {
return new DefaultDataSourceSchema([], [], null, null, []);
}
var q = new Array(l.count);
for (var r = 0; r < l.count; r++) {
q[r] = l._inner[r].toArray();
}
return new DefaultDataSourceSchema(i.o.toArray(), i.q.toArray(), null, q, m.toArray());
};
DataSourceLocalDataProvider.prototype.t = function (a, b) {
if (stringStartsWith(b, "_")) {
return false;
}
if (b == "$hashCode" || b == "$type") {
return false;
}
if ((typeof a[b] === 'function')) {
return false;
}
return true;
};
DataSourceLocalDataProvider.prototype.l = function (a, b, c) {
var e_2, _a;
if (c >= this.maxDepth) {
return null;
}
if (a == null) {
return null;
}
if ((typeof a === 'function')) {
return null;
}
if ((Array.isArray(a))) {
return null;
}
var check_ = a;
if ((check_ instanceof HTMLElement)) {
return null;
}
var d = new List$1(String_$type, 0);
var e = new HashSet$1(String_$type, 0);
var f = new List$1(DataSourceSchemaPropertyType_$type, 0);
var g = new List$1(List$1.$.specialize(String_$type), 0);
var h = this.y(a);
var i = new List$1(IDataSourceSchema_$type, 0);
if (this.schemaIncludedProperties == null || this.schemaIncludedProperties.length > 0) {
for (var j = 0; j < h.count; j++) {
var k = h._inner[j];
if (this.schemaIncludedProperties != null && this.schemaIncludedProperties.length > 0) {
var l = false;
for (var m = 0; m < this.schemaIncludedProperties.length; m++) {
if (this.schemaIncludedProperties[m] == k) {
l = true;
break;
}
}
if (!l) {
continue;
}
}
if (stringStartsWith(k, "_")) {
continue;
}
if (k == "$hashCode" || k == "$type") {
continue;
}
if ((typeof check_[k] === 'function')) {
continue;
}
if (e.contains(k)) {
continue;
}
else {
var n = b == null ? k : b + "." + k;
d.add(k);
e.add_1(k);
this.v.addItem(n, new FastReflectionHelper(false, n));
if (this.w.containsKey(n)) {
f.add(this.w.item(n));
this.w.removeItem(n);
}
else {
f.add(this.c(a, k));
}
g.add(this.z(a, k));
if (f._inner[f.count - 1] == 11) {
i.add(this.l(a[k], n, c + 1));
}
else {
i.add(null);
}
}
}
try {
for (var _b = __values(fromEnum(this.w)), _c = _b.next(); !_c.done; _c = _b.next()) {
var o = _c.value;
var p = o.key.split('.');
for (var q = 0; q < p.length; q++) {
if (e.contains(p[q])) {
continue;
}
else {
d.add(p[q]);
e.add_1(p[q]);
f.add(q == p.length - 1 ? o.value : 11);
g.add(new List$1(String_$type, 0));
}
}
}
}
catch (e_2_1) {
e_2 = { error: e_2_1 };
}
finally {
try {
if (_c && !_c.done && (_a = _b.return))
_a.call(_b);
}
finally {
if (e_2)
throw e_2.error;
}
}
}
var r = new Array(g.count);
for (var s = 0; s < g.count; s++) {
r[s] = g._inner[s].toArray();
}
return new DefaultDataSourceSchema(d.toArray(), f.toArray(), null, r, i.toArray());
};
DataSourceLocalDataProvider.prototype.resolveSchemaPropertyType = function (a) {
var b = a.split('.');
var c = a.indexOf("[") >= 0;
if (b.length == 1) {
for (var d = 0; d < this.actualSchema.propertyNames.length; d++) {
if (this.actualSchema.propertyNames[d] == b[0]) {
return this.actualSchema.propertyTypes[d];
}
}
if (c) {
var e = this.ah();
var f = this.getItemValue(e, a);
if (f == null) {
return 11;
}
else {
return DataSourceLocalDataProvider.e(f);
}
}
return 11;
}
else {
var g = this.ah();
var h = this.getItemValue(g, a);
if (h == null) {
return 11;
}
else {
return DataSourceLocalDataProvider.e(h);
}
}
};
DataSourceLocalDataProvider.prototype.setSchema = function (a) {
this.j = a;
if (this.schemaChanged != null) {
this.schemaChanged(this, new DataSourceDataProviderSchemaChangedEventArgs(this.j, this.actualCount));
}
};
DataSourceLocalDataProvider.prototype.y = function (schemaItem_) {
var e_3, _a;
var a = new HashSet$1(String_$type, 0);
var propertyKey_ = null;
var ret_ = new List$1(String_$type, 0);
var exclusions_ = {};
for (propertyKey_ in schemaItem_) {
if (!isNaN(propertyKey_)) {
continue;
}
if (!exclusions_.hasOwnProperty(propertyKey_)) {
ret_.add(propertyKey_);
}
}
;
try {
for (var _b = __values(fromEnum(ret_)), _c = _b.next(); !_c.done; _c = _b.next()) {
var b = _c.value;
a.add_1(b);
}
}
catch (e_3_1) {
e_3 = { error: e_3_1 };
}
finally {
try {
if (_c && !_c.done && (_a = _b.return))
_a.call(_b);
}
finally {
if (e_3)
throw e_3.error;
}
}
var c = (getAllPropertyNames(schemaItem_));
for (var e = 0; e < c.length; e++) {
var d = c[e];
if (!a.contains(d)) {
a.add_1(d);
ret_.add(d);
}
}
return ret_;
};
DataSourceLocalDataProvider.prototype.av = function (a, item_, propertyName_, b) {
if ((item_.__dataIntents !== undefined)) {
if ((item_.__dataIntents[propertyName_] !== undefined)) {
this.au(a, item_, propertyName_);
}
var selfName_ = "self." + propertyName_;
if (!b && (item_.__dataIntents[selfName_] !== undefined)) {
this.au(a, item_, selfName_);
}
var selfName2_ = "self_" + propertyName_;
if (!b && (item_.__dataIntents[selfName2_] !== undefined)) {
this.au(a, item_, selfName2_);
}
}
};
DataSourceLocalDataProvider.prototype.au = function (a, item_, propertyName_) {
var val_ = item_.__dataIntents[propertyName_];
var b = typeCast(Array_$type, val_) !== null;
if (!b) {
b = (Array.isArray(val_));
}
if (b) {
var c = val_;
for (var d = 0; d < c.length; d++) {
if (c[d] != null) {
a.add(c[d].toString());
}
}
}
};
DataSourceLocalDataProvider.prototype.z = function (item_, propertyName_) {
var a = new List$1(String_$type, 0);
var list_ = this.aa;
var dataIntents_ = null;
this.av(a, item_, propertyName_, false);
this.av(a, list_, propertyName_, true);
return a;
};
DataSourceLocalDataProvider.prototype.ai = function (item_, propertyName_) {
if ((item_[propertyName_] == undefined)) {
return null;
}
return item_[propertyName_];
};
DataSourceLocalDataProvider.prototype.c = function (item_, propertyName_) {
if (item_ == null) {
return 11;
}
if ((item_[propertyName_] == undefined)) {
return 11;
}
var value_ = item_[propertyName_];
return DataSourceLocalDataProvider.e(value_);
};
DataSourceLocalDataProvider.e = function (value_) {
if (value_ == null) {
return 11;
}
if ((typeof value_ == 'number')) {
return 5;
}
if ((typeof value_ == 'boolean')) {
return 2;
}
if ((typeof value_ == 'string')) {
return 0;
}
if ((typeof value_ == 'object')) {
if ((value_ instanceof Date)) {
return 8;
}
}
return 11;
};
DataSourceLocalDataProvider.prototype.ah = function () {
var a = 0;
if (this.s) {
a = (this.aa.length);
}
else {
a = this.aa.count;
}
for (var b = 0; b < a; b++) {
var c = void 0;
if (this.s) {
c = this.aa[b];
}
else {
c = this.aa.item(b);
}
if (c != null) {
return c;
}
}
return null;
};
DataSourceLocalDataProvider.prototype.at = function (a, b, c) {
var d = typeCast(Array_$type, a) !== null;
var e = 0;
if (d) {
e = (a.length);
}
else {
e = a.count;
}
if (b > 0) {
e = Math.min(e, b);
}
for (var f = 0; f < e; f++) {
var g = void 0;
if (d) {
g = a[f];
}
else {
g = a.item(f);
}
if (!c(g, f)) {
break;
}
}
};
DataSourceLocalDataProvider.prototype.ax = function (a, b, c) {
this.az(a, b, c);
};
Object.defineProperty(DataSourceLocalDataProvider.prototype, "ab", {
get: function () {
return this.aa;
},
enumerable: false,
configurable: true
});
DataSourceLocalDataProvider.prototype.az = function (a, b, c) {
switch (a) {
case "ItemsSource":
this.j = null;
if (b != null) {
if (typeCast(INotifyCollectionChanged_$type, b) !== null) {
var d = typeCast(INotifyCollectionChanged_$type, b);
d.collectionChanged = delegateRemove(d.collectionChanged, runOn(this, this.aw));
}
}
if (this.dataSource != null) {
this.s = false;
if (typeCast(Array_$type, this.dataSource) !== null) {
this.s = true;
this.aa = this.dataSource;
}
else if (typeCast(IList_$type, this.dataSource) !== null) {
this.aa = this.dataSource;
}
if (!this.s && this.aa == null) {
var source_ = this.dataSource;
this.s = (Array.isArray(source_));
if (this.s) {
this.aa = this.dataSource;
}
}
if (typeCast(INotifyCollectionChanged_$type, this.dataSource) !== null) {
var e = typeCast(INotifyCollectionChanged_$type, this.dataSource);
e.collectionChanged = delegateCombine(e.collectionChanged, runOn(this, this.aw));
}
}
else {
this.aa = null;
}
this.as();
break;
case "DeferAutoRefresh":
if (!c) {
this.queueAutoRefresh();
}
break;
case "SchemaHints":
this.j = null;
this.ay();
this.as();
break;
case "MaxDepth":
case "MaxIteration":
this.j = null;
this.as();
break;
}
};
DataSourceLocalDataProvider.prototype.aw = function (a, b) {
switch (b.action) {
case 0:
if (b.newItems != null) {
this.notifyInsertItem(b.newStartingIndex, b.newItems.item(0));
}
break;
case 1:
if (b.oldItems != null) {
this.notifyRemoveItem(b.oldStartingIndex, b.oldItems.item(0));
}
break;
case 2:
if (b.newItems != null) {
this.notifySetItem(b.newStartingIndex, b.oldItems.item(0), b.newItems.item(0));
}
break;
case 4:
this.notifyClearItems();
break;
}
};
Object.defineProperty(DataSourceLocalDataProvider.prototype, "executionContext", {
get: function () {
return this.i;
},
set: function (a) {
this.i = a;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "u", {
get: function () {
return false;
},
enumerable: false,
configurable: true
});
DataSourceLocalDataProvider.prototype.notifySetItem = function (a, b, c) {
if (this.u) {
if (this.s) {
this.aa[a] = c;
}
else {
this.aa.item(a, c);
}
}
if (this.updateNotifier != null) {
this.updateNotifier.notifySetItem(a, b, c);
}
};
DataSourceLocalDataProvider.prototype.notifyClearItems = function () {
if (this.u) {
if (this.s) {
this.aa.length = 0;
}
else {
this.aa.clear();
}
}
if (this.updateNotifier != null) {
this.updateNotifier.notifyClearItems();
}
};
DataSourceLocalDataProvider.prototype.notifyInsertItem = function (a, b) {
if (this.u) {
if (this.s) {
this.aa.splice(a, 0, b);
}
else {
this.aa.insert(a, b);
}
}
var c = 0;
if (this.s) {
c = (this.aa.length);
}
else {
c = this.aa.count;
}
if (this.aa != null && c == 1 && (this.actualSchema == null || this.actualSchema.propertyNames.length == 0)) {
this.j = null;
this.as();
}
if (this.updateNotifier != null) {
this.updateNotifier.notifyInsertItem(a, b);
}
};
DataSourceLocalDataProvider.prototype.notifyRemoveItem = function (a, b) {
if (this.u) {
if (this.s) {
this.aa.splice(a, 1);
}
else {
this.aa.remove(a);
}
}
if (this.updateNotifier != null) {
this.updateNotifier.notifyRemoveItem(a, b);
}
};
Object.defineProperty(DataSourceLocalDataProvider.prototype, "updateNotifier", {
get: function () {
return this.h;
},
set: function (a) {
this.h = a;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "deferAutoRefresh", {
get: function () {
return this.r;
},
set: function (a) {
var b = this.r;
this.r = a;
if (this.r != b) {
this.ax("DeferAutoRefresh", b, this.r);
}
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "isSortingSupported", {
get: function () {
return false;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "isFilteringSupported", {
get: function () {
return false;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "sortDescriptions", {
get: function () {
return this.o;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "filterExpressions", {
get: function () {
return this.g;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "summaryDescriptions", {
get: function () {
return this.p;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "summaryScope", {
get: function () {
return this.f;
},
set: function (a) {
this.f = a;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "notifyUsingSourceIndexes", {
get: function () {
return true;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "propertiesRequested", {
get: function () {
return this.a;
},
set: function (a) {
var b = this.a;
this.a = a;
if (b != this.a) {
}
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "isItemIndexLookupSupported", {
get: function () {
return true;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "isKeyIndexLookupSupported", {
get: function () {
return false;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "isGroupingSupported", {
get: function () {
return false;
},
enumerable: false,
configurable: true
});
Object.defineProperty(DataSourceLocalDataProvider.prototype, "groupDescriptions", {
get: function () {
return this.n;
},
enumerable: false,
configurable: true
});
DataSourceLocalDataProvider.prototype.queueAutoRefresh = function () {
if (this.deferAutoRefresh) {
return;
}
if (this.q) {
return;
}
if (this.executionContext != null) {
this.q = true;
this.executionContext.enqueueAction(runOn(this, this.ar));
}
};
DataSourceLocalDataProvider.prototype.ar = function () {
if (this.deferAutoRefresh) {
this.q = false;
return;
}
if (!this.q) {
return;
}
this.q = false;
this.a0();
};
DataSourceLocalDataProvider.prototype.a0 = function () {
this.a1();
};
DataSourceLocalDataProvider.prototype.a1 = function () {
};
DataSourceLocalDataProvider.prototype.flushAutoRefresh = function () {
this.ar();
};
DataSourceLocalDataProvider.prototype.refresh = function () {
this.a0();
};
DataSourceLocalDataProvider.prototype.indexOfItem = function (a) {
if (this.aa == null) {
return -1;
}
return this.aa.indexOf(a);
};
DataSourceLocalDataProvider.prototype.indexOfKey = function (a) {
return -1;
};
Object.defineProperty(DataSourceLocalDataProvider.prototype, "schemaIncludedProperties", {
get: function () {
return this.b;
},
set: function (a) {
var b = this.b;
this.b = a;
if (b != this.b) {
}
},
enumerable: false,
configurable: true
});
DataSourceLocalDataProvider.$t = markType(DataSourceLocalDataProvider, 'DataSourceLocalDataProvider', Base.$, [IDataSourceLocalDataProvider_$type]);
return DataSourceLocalDataProvider;
}(Base));
export { DataSourceLocalDataProvider };