igniteui-angular-core
Version:
Ignite UI Angular Core logic used in multiple UI components.
184 lines (183 loc) • 6.18 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 { Base, String_$type, fromEnum, Number_$type, markType } from "./type";
import { List$1 } from "./List$1";
import { CodeGenerationItemBuilderPropertyInfo } from "./CodeGenerationItemBuilderPropertyInfo";
import { HashSet$1 } from "./HashSet$1";
import { Dictionary$2 } from "./Dictionary$2";
import { CodeGeneratingImportManager } from "./CodeGeneratingImportManager";
/**
* @hidden
*/
export let CodeGeneratingRendererResult = /*@__PURE__*/ (() => {
class CodeGeneratingRendererResult extends Base {
constructor() {
super(...arguments);
this.q = new List$1(CodeGenerationItemBuilderPropertyInfo.$, 0);
this._platform = 0;
this._generationOptions = null;
this.l = new Dictionary$2(String_$type, List$1.$.specialize(String_$type), 0);
this.n = new Dictionary$2(String_$type, List$1.$.specialize(CodeGeneratingImportManager.$), 0);
this.k = new Dictionary$2(String_$type, List$1.$.specialize(String_$type), 0);
this.p = new HashSet$1(String_$type, 0);
this.i = new Dictionary$2(String_$type, Number_$type, 0);
this.o = new Dictionary$2(String_$type, String_$type, 0);
this.m = new Dictionary$2(String_$type, String_$type, 0);
this.j = new Dictionary$2(String_$type, Number_$type, 0);
}
get t() {
return this.q;
}
get platform() {
return this._platform;
}
set platform(a) {
this._platform = a;
}
get generationOptions() {
return this._generationOptions;
}
set generationOptions(a) {
this._generationOptions = a;
}
addPackageRef(a) {
this.p.add_1(a);
}
addContainerResult(a, b) {
if (!this.l.containsKey(a)) {
this.l.addItem(a, new List$1(String_$type, 0));
}
let c = this.l.item(a);
c.add(b);
}
addImportResult(a, b) {
if (!this.n.containsKey(a)) {
this.n.addItem(a, new List$1(CodeGeneratingImportManager.$, 0));
}
let c = this.n.item(a);
c.add(b);
}
addContainerNewFileResult(a, b) {
if (!this.k.containsKey(a)) {
this.k.addItem(a, new List$1(String_$type, 0));
}
let c = this.k.item(a);
c.add(b);
}
getPackages() {
let a = new List$1(String_$type, 0);
for (let b of fromEnum(this.p)) {
a.add(b);
}
return a.toArray();
}
getKeys() {
let a = new List$1(String_$type, 0);
for (let b of fromEnum(this.l.keys)) {
a.add(b);
}
return a.toArray();
}
getImportsKeys() {
let a = new List$1(String_$type, 0);
for (let b of fromEnum(this.n.keys)) {
a.add(b);
}
return a.toArray();
}
getContentForKey(a) {
if (!this.l.containsKey(a)) {
return "";
}
let b = this.l.item(a);
if (b.count == 1) {
return b._inner[0];
}
let c = "";
for (let d of fromEnum(b)) {
c += d;
}
return c;
}
r(a) {
if (!this.n.containsKey(a)) {
return null;
}
return this.n.item(a);
}
getImportsArrayForKey(a) {
let b = this.r(a);
if (b == null) {
return null;
}
return b.toArray();
}
u(a) {
if (!this.i.containsKey(a)) {
this.i.item(a, 1);
}
let b = this.i.item(a);
let c = a + b;
this.i.item(a, b + 1);
return c;
}
af(a) {
this.q.add(a);
}
getNewFiles() {
let a = new List$1(String_$type, 0);
for (let b of fromEnum(this.k.keys)) {
a.add(b);
}
return a;
}
getNewFileContent(a) {
let b = this.k.item(a);
let c = "";
for (let d of fromEnum(b)) {
c += d;
}
return c;
}
defineString(a, b) {
this.o.item(a, b);
}
getStringNames() {
let a = new List$1(String_$type, 0);
for (let b of fromEnum(this.o.keys)) {
a.add(b);
}
return a.toArray();
}
getString(a) {
return this.o.item(a);
}
trackDescriptionField(a, b) {
this.m.item(a, b);
}
hasDescription(a) {
return this.m.containsKey(a);
}
getDescriptionField(a) {
return this.m.item(a);
}
v(a) {
let b = 0;
if (!this.j.containsKey(a)) {
this.j.addItem(a, b);
}
else {
b = this.j.item(a);
}
b++;
this.j.item(a, b);
return a + b;
}
}
CodeGeneratingRendererResult.$t = markType(CodeGeneratingRendererResult, 'CodeGeneratingRendererResult');
return CodeGeneratingRendererResult;
})();