igniteui-angular-core
Version:
Ignite UI Angular Core logic used in multiple UI components.
77 lines (76 loc) • 2.53 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 { JsonDictionaryItem } from "./JsonDictionaryItem";
import { Dictionary$2 } from "./Dictionary$2";
import { List$1 } from "./List$1";
import { String_$type, fromEnum, markType } from "./type";
/**
* @hidden
*/
export let JsonDictionaryObject = /*@__PURE__*/ (() => {
class JsonDictionaryObject extends JsonDictionaryItem {
constructor() {
super();
this.h = new Dictionary$2(String_$type, JsonDictionaryItem.$, 0);
}
i(a, b) {
this.h.item(a, b);
}
k(a) {
this.h.removeItem(a);
}
j() {
this.h.clear();
}
item(a, b) {
if (arguments.length === 2) {
this.h.item(a, b);
return b;
}
else {
return this.h.item(a);
}
}
g(a) {
return this.h.containsKey(a);
}
e() {
let a = new List$1(String_$type, 0);
for (let b of fromEnum(this.h.keys)) {
a.add(b);
}
return a.toArray();
}
d(a) {
a.i("{");
a.h();
a.g();
let b = this.e();
if (b != null) {
for (let c = 0; c < b.length; c++) {
if (c > 0) {
a.j(",");
}
let d = b[c];
let e = this.h.item(d);
a.i("\"" + this.a(d) + "\": ");
if (e == null) {
a.i("null");
}
else {
e.d(a);
}
}
}
a.h();
a.e();
a.i("}");
}
}
JsonDictionaryObject.$t = markType(JsonDictionaryObject, 'JsonDictionaryObject', JsonDictionaryItem.$);
return JsonDictionaryObject;
})();