@malloydata/render 0.0.225-dev250106171109 → 0.0.225-dev250110175536
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/dist/module/index.mjs
CHANGED
|
@@ -41129,48 +41129,46 @@ class fme extends ame.StaticSpace {
|
|
|
41129
41129
|
structDef() {
|
|
41130
41130
|
if (this.complete = !0, this.sourceDef === void 0) {
|
|
41131
41131
|
const e = {};
|
|
41132
|
-
for (const [
|
|
41133
|
-
|
|
41132
|
+
for (const [a, l] of this.entries())
|
|
41133
|
+
l instanceof MP.SpaceParam && (e[a] = l.parameter());
|
|
41134
41134
|
this.sourceDef = { ...this.fromSource, fields: [] }, this.sourceDef.parameters = e;
|
|
41135
|
-
const n = /* @__PURE__ */ new Map(), r = [], i = [], s = []
|
|
41136
|
-
for (const [
|
|
41137
|
-
|
|
41138
|
-
const
|
|
41139
|
-
for (const [
|
|
41140
|
-
if (
|
|
41141
|
-
const
|
|
41142
|
-
ime.ErrorFactory.didCreate(
|
|
41135
|
+
const n = /* @__PURE__ */ new Map(), r = [], i = [], s = [];
|
|
41136
|
+
for (const [a, l] of this.entries())
|
|
41137
|
+
l instanceof lme.StructSpaceFieldBase ? i.push([a, l]) : l instanceof ume.ViewField ? s.push([a, l]) : l instanceof sme.SpaceField && r.push([a, l]);
|
|
41138
|
+
const o = [...r, ...i, ...s], u = this.parameterSpace();
|
|
41139
|
+
for (const [a, l] of o)
|
|
41140
|
+
if (l instanceof ome.JoinSpaceField) {
|
|
41141
|
+
const c = l.join.structDef(u);
|
|
41142
|
+
ime.ErrorFactory.didCreate(c) || (n.set(a, this.sourceDef.fields.length), this.sourceDef.fields.push(c), l.join.fixupJoinOn(this, c));
|
|
41143
41143
|
} else {
|
|
41144
|
-
const
|
|
41145
|
-
|
|
41144
|
+
const c = l.fieldDef();
|
|
41145
|
+
c && (n.set(a, this.sourceDef.fields.length), this.sourceDef.fields.push(c));
|
|
41146
41146
|
}
|
|
41147
|
-
for (const [
|
|
41148
|
-
|
|
41149
|
-
|
|
41150
|
-
|
|
41151
|
-
var h;
|
|
41152
|
-
return (h = x.as) !== null && h !== void 0 ? h : x.name === l;
|
|
41147
|
+
for (const [a, l] of this.newAccessModifiers) {
|
|
41148
|
+
const c = this.sourceDef.fields.findIndex((f) => {
|
|
41149
|
+
var x;
|
|
41150
|
+
return (x = f.as) !== null && x !== void 0 ? x : f.name === a;
|
|
41153
41151
|
});
|
|
41154
|
-
if (
|
|
41155
|
-
throw new Error(`Can't find field '${
|
|
41156
|
-
|
|
41157
|
-
...this.sourceDef.fields[
|
|
41158
|
-
accessModifier:
|
|
41152
|
+
if (c === -1)
|
|
41153
|
+
throw new Error(`Can't find field '${a}' to set access modifier`);
|
|
41154
|
+
l === "public" ? delete this.sourceDef.fields[c].accessModifier : this.sourceDef.fields[c] = {
|
|
41155
|
+
...this.sourceDef.fields[c],
|
|
41156
|
+
accessModifier: l
|
|
41159
41157
|
};
|
|
41160
41158
|
}
|
|
41161
|
-
for (const [
|
|
41162
|
-
const
|
|
41163
|
-
var
|
|
41164
|
-
return (
|
|
41159
|
+
for (const [a, l] of this.newNotes) {
|
|
41160
|
+
const c = this.sourceDef.fields.findIndex((x) => {
|
|
41161
|
+
var h;
|
|
41162
|
+
return (h = x.as) !== null && h !== void 0 ? h : x.name === a;
|
|
41165
41163
|
});
|
|
41166
|
-
if (
|
|
41167
|
-
throw new Error(`Can't find field '${
|
|
41168
|
-
const
|
|
41169
|
-
this.sourceDef.fields[
|
|
41170
|
-
...
|
|
41164
|
+
if (c === -1)
|
|
41165
|
+
throw new Error(`Can't find field '${a}' to set access modifier`);
|
|
41166
|
+
const f = this.sourceDef.fields[c];
|
|
41167
|
+
this.sourceDef.fields[c] = {
|
|
41168
|
+
...f,
|
|
41171
41169
|
annotation: {
|
|
41172
|
-
...
|
|
41173
|
-
inherits:
|
|
41170
|
+
...l,
|
|
41171
|
+
inherits: f.annotation
|
|
41174
41172
|
}
|
|
41175
41173
|
};
|
|
41176
41174
|
}
|