@epam/statgpt-sdmx-toolkit 0.2.0-rc.46 → 0.2.0-rc.48

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/index.mjs CHANGED
@@ -20,8 +20,44 @@ const v = (e) => {
20
20
  return `${n}:${e}${s}`;
21
21
  };
22
22
  var L = /* @__PURE__ */ ((e) => (e.DESCENDANTS = "descendants", e.NONE = "none", e.ALL = "all", e))(L || {}), me = /* @__PURE__ */ ((e) => (e.EXACT = "exact", e.AVAILABLE = "available", e))(me || {});
23
- const Ne = (e = "", t = "", n = "") => `sdmx/3.0/availability/dataflow/${e}/${t}/${n}`;
24
- class En {
23
+ function Ne(e) {
24
+ return {
25
+ data: {
26
+ codelists: e.data.codelists,
27
+ conceptSchemes: e.data.conceptSchemes,
28
+ dataConstraints: e.data.dataConstraints?.map($e),
29
+ dataflows: e.data.dataflows,
30
+ dataStructures: e.data.dataStructures,
31
+ metadataStructures: e.data.metadataStructures
32
+ }
33
+ };
34
+ }
35
+ function $e(e) {
36
+ return {
37
+ ...e,
38
+ cubeRegions: e.cubeRegions?.map(Pe)
39
+ };
40
+ }
41
+ function Pe(e) {
42
+ return {
43
+ isIncluded: e.include,
44
+ memberSelection: e.keyValues.map(be)
45
+ };
46
+ }
47
+ function be(e) {
48
+ return {
49
+ included: e.include,
50
+ componentId: e.id,
51
+ selectionValues: e.values.map(_e)
52
+ };
53
+ }
54
+ function _e(e) {
55
+ return {
56
+ memberValue: e.value
57
+ };
58
+ }
59
+ const Oe = (e = "", t = "", n = "") => `sdmx/3.0/availability/dataflow/${e}/${t}/${n}`;
60
+ class yn {
25
61
  constructor(t) {
26
62
  this.client = t;
27
63
  }
@@ -30,24 +66,36 @@ class En {
30
66
  filters: n || [],
31
67
  mode: me.AVAILABLE,
32
68
  references: L.NONE
33
- }, c = Ne(s, r, o);
34
- return await this.client.postRequest(c, { body: i });
69
+ }, a = Oe(s, r, o);
70
+ if (this.client.config.sdmxProxyUrl) {
71
+ const c = await this.client.postRequest(
72
+ a,
73
+ { body: i },
74
+ this.client.config.sdmxProxyUrl
75
+ );
76
+ return Ne(c);
77
+ }
78
+ return await this.client.postRequest(
79
+ a,
80
+ { body: i },
81
+ this.client.config.constrainsApiUrl || this.client.config.apiUrl
82
+ );
35
83
  }
36
84
  }
37
- var S = /* @__PURE__ */ ((e) => (e.CSV = "csv", e.JSON = "json", e.XML = "xml", e))(S || {}), $e = /* @__PURE__ */ ((e) => (e.ID = "id", e.NAME = "name", e.ID_NAME = "both", e))($e || {}), Pe = /* @__PURE__ */ ((e) => (e.FULL_DATASET = "full", e.DATA_IN_TABLE = "query", e))(Pe || {});
38
- const be = (e, t) => {
85
+ var y = /* @__PURE__ */ ((e) => (e.CSV = "csv", e.JSON = "json", e.XML = "xml", e))(y || {}), Le = /* @__PURE__ */ ((e) => (e.ID = "id", e.NAME = "name", e.ID_NAME = "both", e))(Le || {}), Me = /* @__PURE__ */ ((e) => (e.FULL_DATASET = "full", e.DATA_IN_TABLE = "query", e))(Me || {});
86
+ const Ce = (e, t) => {
39
87
  switch (e) {
40
- case S.CSV:
88
+ case y.CSV:
41
89
  return A(
42
90
  "application/vnd.sdmx.data+csv;version=2.0.0",
43
91
  t
44
92
  );
45
- case S.XML:
93
+ case y.XML:
46
94
  return A(
47
95
  "application/vnd.sdmx.data+xml;version=3.0.0",
48
96
  t
49
97
  );
50
- case S.JSON:
98
+ case y.JSON:
51
99
  return A(`application/${e}`, t);
52
100
  default:
53
101
  return A(
@@ -57,43 +105,43 @@ const be = (e, t) => {
57
105
  }
58
106
  }, A = (e, t) => `${e}; labels=${t}`;
59
107
  var fe = /* @__PURE__ */ ((e) => (e.REFERENCE_PARTIAL = "referencepartial", e.FULL = "full", e))(fe || {});
60
- const _e = "all", Oe = "sdmx/3.0/data/dataflow", ge = "&", J = ":", Le = "=", Me = "+", pn = ",", Ce = "*", X = (e, t, n) => {
61
- const { filterKey: s, timeFilter: r } = n, { agency: o, id: i, version: c } = D(e), a = [r || "", t].filter((d) => !!d).join(ge);
62
- return `${`${Oe}/${o}/${i}/${c}`}/${s || Ce}?${a}`;
63
- }, Ue = (e = "", t = "", n = "", s = L.DESCENDANTS) => `sdmx/3.0/structure/dataflow/${e}/${t}/${n}?references=${s}&detail=${fe.REFERENCE_PARTIAL}`;
64
- class Dn {
108
+ const Ue = "all", xe = "sdmx/3.0/data/dataflow", ge = "&", J = ":", Ye = "=", We = "+", Tn = ",", Ve = "*", X = (e, t, n) => {
109
+ const { filterKey: s, timeFilter: r } = n, { agency: o, id: i, version: a } = D(e), c = [r || "", t].filter((d) => !!d).join(ge);
110
+ return `${`${xe}/${o}/${i}/${a}`}/${s || Ve}?${c}`;
111
+ }, ke = (e = "", t = "", n = "", s = L.DESCENDANTS) => `sdmx/3.0/structure/dataflow/${e}/${t}/${n}?references=${s}&detail=${fe.REFERENCE_PARTIAL}`;
112
+ class vn {
65
113
  constructor(t) {
66
114
  this.client = t;
67
115
  }
68
116
  async getDataSet(t, n) {
69
117
  const { agency: s, id: r, version: o } = D(t);
70
118
  return await this.client.getRequest(
71
- Ue(s, r, o, n)
119
+ ke(s, r, o, n)
72
120
  );
73
121
  }
74
122
  async getDatasetData(t, n) {
75
123
  const s = new URLSearchParams({
76
124
  includeHistory: "false",
77
125
  limit: "1000",
78
- attributes: _e,
126
+ attributes: Ue,
79
127
  dimensionAtObservation: "TIME_PERIOD"
80
128
  // TODO: use time dimensions
81
129
  }).toString(), r = X(t, s, n);
82
130
  return await this.client.getRequest(r);
83
131
  }
84
- async downloadDataSet(t, n, s, r, o, i, c = !1) {
85
- const a = new URLSearchParams({
132
+ async downloadDataSet(t, n, s, r, o, i, a = !1) {
133
+ const c = new URLSearchParams({
86
134
  format: n,
87
135
  compress: "false",
88
- attributes: c ? "all" : "none",
136
+ attributes: a ? "all" : "none",
89
137
  limit: "1000"
90
- }).toString(), u = X(t, a, o);
138
+ }).toString(), u = X(t, c, o);
91
139
  return this.client.streamRequest(
92
140
  u,
93
141
  {
94
142
  method: "GET",
95
143
  headers: {
96
- Accept: be(n, r),
144
+ Accept: Ce(n, r),
97
145
  "Accept-language": s
98
146
  }
99
147
  },
@@ -101,44 +149,44 @@ class Dn {
101
149
  );
102
150
  }
103
151
  }
104
- const xe = (e, t) => e.error || e.message || `${t.status} ${t.statusText}`, Ye = "application/json", We = "Content-Type", P = "Api-Key", ke = "X-CONVERSATION-ID", T = "Ocp-Apim-Subscription-Key";
152
+ const qe = (e, t) => e.error || e.message || `${t.status} ${t.statusText}`, Qe = "application/json", Be = "Content-Type", P = "Api-Key", Fe = "X-CONVERSATION-ID", T = "Ocp-Apim-Subscription-Key";
105
153
  class Z extends Error {
106
154
  constructor(t) {
107
155
  super(t.message), this.isHttpError = !0, this.name = "HttpError", this.code = t.code, this.status = t.status, this.details = t.details;
108
156
  }
109
157
  }
110
- const y = (e) => isNaN(Date.parse(e)) ? null : new Date(e), b = (e, t, n) => {
158
+ const S = (e) => isNaN(Date.parse(e)) ? null : new Date(e), b = (e, t, n) => {
111
159
  const s = {
112
- [We]: t?.contentType || Ye
160
+ [Be]: t?.contentType || Qe
113
161
  };
114
- return t?.jwt && (s.Authorization = `Bearer ${t.jwt}`), t?.chatReference && (s[ke] = t.chatReference), { ...s, ...n };
115
- }, qe = (e) => {
162
+ return t?.jwt && (s.Authorization = `Bearer ${t.jwt}`), t?.chatReference && (s[Fe] = t.chatReference), { ...s, ...n };
163
+ }, Ge = (e) => {
116
164
  const t = { ...e };
117
165
  return t[P] && (t[P] = t[P].substring(0, 8) + "...[REDACTED]"), t.Authorization && (t.Authorization = "Bearer [REDACTED]"), t[T] && (t[T] = t[T].substring(0, 8) + "...[REDACTED]"), t;
118
166
  }, ee = async (e, t, n) => await fetch(e, {
119
167
  method: n.method || "GET",
120
168
  headers: t,
121
169
  body: n.body ? JSON.stringify(n.body) : void 0
122
- }), Qe = async (e, t, n) => await fetch(e, {
170
+ }), Ke = async (e, t, n) => await fetch(e, {
123
171
  method: n.method,
124
172
  headers: t,
125
173
  body: n?.isFormData && typeof n?.body == "string" ? n.body : JSON.stringify(n.body),
126
174
  signal: n?.signal
127
175
  });
128
- class Ve {
176
+ class je {
129
177
  constructor() {
130
178
  this.decoder = new TextDecoder();
131
179
  }
132
180
  async streamChat(t, n, s = {}, r) {
133
- const { onMessage: o, onError: i, onComplete: c, signal: a } = s;
181
+ const { onMessage: o, onError: i, onComplete: a, signal: c } = s;
134
182
  try {
135
183
  const u = await this.initializeStreamRequest(
136
184
  t,
137
185
  n,
138
- a,
186
+ c,
139
187
  r
140
188
  );
141
- await this.processStreamData(u, o), c?.();
189
+ await this.processStreamData(u, o), a?.();
142
190
  } catch (u) {
143
191
  this.handleStreamError(u, i);
144
192
  }
@@ -146,7 +194,7 @@ class Ve {
146
194
  async initializeStreamRequest(t, n, s, r) {
147
195
  const o = b(void 0, {
148
196
  jwt: r
149
- }), i = await Qe(
197
+ }), i = await Ke(
150
198
  t,
151
199
  {
152
200
  Accept: "text/event-stream",
@@ -159,16 +207,16 @@ class Ve {
159
207
  }
160
208
  );
161
209
  if (!i.ok) {
162
- const c = await i.text();
163
- let a = {};
210
+ const a = await i.text();
211
+ let c = {};
164
212
  try {
165
- a = JSON.parse(c);
213
+ c = JSON.parse(a);
166
214
  } catch {
167
- a.error = "Failed to parse error body";
215
+ c.error = "Failed to parse error body";
168
216
  }
169
217
  throw new Z({
170
218
  status: i.status,
171
- message: a.error ?? "No response body"
219
+ message: c.error ?? "No response body"
172
220
  });
173
221
  }
174
222
  if (!i.body)
@@ -189,11 +237,11 @@ class Ve {
189
237
  }
190
238
  const i = this.decoder.decode(o, { stream: !0 });
191
239
  s += i;
192
- const c = s.split(`
240
+ const a = s.split(`
193
241
  `);
194
- s = c.pop() || "";
195
- for (const a of c)
196
- this.parseSSEDataLine(a, n);
242
+ s = a.pop() || "";
243
+ for (const c of a)
244
+ this.parseSSEDataLine(c, n);
197
245
  }
198
246
  } finally {
199
247
  t.releaseLock();
@@ -221,8 +269,8 @@ class Ve {
221
269
  }
222
270
  }
223
271
  }
224
- new Ve();
225
- class An {
272
+ new je();
273
+ class Rn {
226
274
  constructor(t) {
227
275
  this.config = t, console.info("SdmxApiClient initialized", {
228
276
  apiUrl: t.apiUrl || "NOT SET"
@@ -231,8 +279,8 @@ class An {
231
279
  async getRequest(t, n) {
232
280
  return this.request(t, { ...n, method: "GET" });
233
281
  }
234
- async postRequest(t, n) {
235
- return this.request(t, { ...n, method: "POST" });
282
+ async postRequest(t, n, s) {
283
+ return this.request(t, { ...n, method: "POST" }, s);
236
284
  }
237
285
  async streamRequest(t, n, s) {
238
286
  const r = `${this.config.apiUrl}/${t}`, o = {
@@ -243,7 +291,7 @@ class An {
243
291
  };
244
292
  this.config.apiKey != null && (o[T] = this.config.apiKey);
245
293
  const i = new ReadableStream({
246
- async start(a) {
294
+ async start(c) {
247
295
  try {
248
296
  const u = await ee(r, o, n);
249
297
  if (!u.ok) {
@@ -255,69 +303,69 @@ class An {
255
303
  const d = u.body?.getReader();
256
304
  if (!d) throw new Error("Failed to create stream reader");
257
305
  const l = new Uint8Array([239, 187, 191]);
258
- a.enqueue(l);
306
+ c.enqueue(l);
259
307
  const m = async () => {
260
- const { done: f, value: E } = await d.read();
261
- f ? a.close() : (a.enqueue(E), await m());
308
+ const { done: f, value: p } = await d.read();
309
+ f ? c.close() : (c.enqueue(p), await m());
262
310
  };
263
311
  m();
264
312
  } catch (u) {
265
- a.error(u);
313
+ c.error(u);
266
314
  }
267
315
  }
268
- }), c = new Headers({
316
+ }), a = new Headers({
269
317
  "Content-Disposition": `attachment; filename=${encodeURIComponent(s)}`
270
318
  });
271
- return new Response(i, { headers: c });
319
+ return new Response(i, { headers: a });
272
320
  }
273
- async request(t, n) {
274
- const s = Date.now(), r = t.includes("availability") && this.config.constrainsApiUrl ? `${this.config.constrainsApiUrl}/${t}` : `${this.config.apiUrl}/${t}`, o = {
321
+ async request(t, n, s) {
322
+ const r = Date.now(), o = `${s || this.config.apiUrl}/${t}`, i = {
275
323
  ...b(void 0, {
276
324
  jwt: this.config.jwt
277
325
  }),
278
326
  ...n.headers
279
327
  };
280
- this.config.apiKey != null && (o["Ocp-Apim-Subscription-Key"] = this.config.apiKey), this.addInfoRequestLog("API Request", r, n, o);
328
+ this.config.apiKey != null && (i["Ocp-Apim-Subscription-Key"] = this.config.apiKey), this.addInfoRequestLog("API Request", o, n, i);
281
329
  try {
282
- const i = await ee(r, o, n), c = Date.now() - s;
283
- let a;
284
- const u = await i.text();
330
+ const a = await ee(o, i, n), c = Date.now() - r;
331
+ let u;
332
+ const d = await a.text();
285
333
  try {
286
- a = u ? JSON.parse(u) : {};
334
+ u = d ? JSON.parse(d) : {};
287
335
  } catch {
288
336
  if (this.addErrorRequestParsing(
289
- r,
337
+ o,
290
338
  n,
291
- i,
339
+ a,
292
340
  c,
293
- u
294
- ), !i.ok)
341
+ d
342
+ ), !a.ok)
295
343
  throw new Error(
296
- `API request failed: ${i.status} ${i.statusText} - ${u.substring(0, 100)}`
344
+ `API request failed: ${a.status} ${a.statusText} - ${d.substring(0, 100)}`
297
345
  );
298
- a = { data: u };
346
+ u = { data: d };
299
347
  }
300
- if (!i.ok) {
301
- this.addErrorRequestLog(r, n, i, c, a);
302
- const d = xe(a, i);
303
- throw new Error(`API request failed: ${d}`);
348
+ if (!a.ok) {
349
+ this.addErrorRequestLog(o, n, a, c, u);
350
+ const l = qe(u, a);
351
+ throw new Error(`API request failed: ${l}`);
304
352
  }
305
- return a;
306
- } catch (i) {
307
- const c = Date.now() - s;
353
+ return u;
354
+ } catch (a) {
355
+ const c = Date.now() - r;
308
356
  throw console.error("API Request Exception", {
309
357
  method: n.method,
310
- url: r,
358
+ url: o,
311
359
  duration: `${c}ms`,
312
- error: i instanceof Error ? i.message : String(i)
313
- }), i;
360
+ error: a instanceof Error ? a.message : String(a)
361
+ }), a;
314
362
  }
315
363
  }
316
364
  addInfoRequestLog(t, n, s, r) {
317
365
  const o = {
318
366
  method: s.method || "GET",
319
367
  url: n,
320
- headers: qe(r)
368
+ headers: Ge(r)
321
369
  };
322
370
  s.body && (o.body = s.body), console.info(t, o);
323
371
  }
@@ -343,17 +391,17 @@ class An {
343
391
  });
344
392
  }
345
393
  }
346
- const yn = ["FREQ", "FREQUENCY"];
347
- var Be = /* @__PURE__ */ ((e) => (e.CONDITIONAL = "Conditional", e.MANDATORY = "Mandatory", e))(Be || {}), M = /* @__PURE__ */ ((e) => (e.DIMENSION = "Dimension", e.MEASURE_DIMENSION = "MeasureDimension", e.TIME_DIMENSION = "TimeDimension", e))(M || {}), Fe = /* @__PURE__ */ ((e) => (e.UNBOUNDED = "unbounded", e))(Fe || {});
348
- const Ge = (e, t) => {
394
+ const wn = ["FREQ", "FREQUENCY"];
395
+ var He = /* @__PURE__ */ ((e) => (e.CONDITIONAL = "Conditional", e.MANDATORY = "Mandatory", e))(He || {}), M = /* @__PURE__ */ ((e) => (e.DIMENSION = "Dimension", e.MEASURE_DIMENSION = "MeasureDimension", e.TIME_DIMENSION = "TimeDimension", e))(M || {}), ze = /* @__PURE__ */ ((e) => (e.UNBOUNDED = "unbounded", e))(ze || {});
396
+ const Je = (e, t) => {
349
397
  const n = e?.data?.dataSets?.[0], r = e?.data?.structures?.[0]?.attributes?.dimensionGroup || [], o = n?.dimensionGroupAttributes, i = {};
350
- for (const c of r) {
351
- const a = c.relationship.dimensions, { codedSeriesKey: u, decodedSeriesKey: d } = he(
398
+ for (const a of r) {
399
+ const c = a.relationship.dimensions, { codedSeriesKey: u, decodedSeriesKey: d } = he(
352
400
  e,
353
401
  t,
354
- a
402
+ c
355
403
  );
356
- i[c.id] = {
404
+ i[a.id] = {
357
405
  values: o?.[u] || [],
358
406
  decodedSeriesKey: d,
359
407
  codedSeriesKey: u
@@ -365,54 +413,54 @@ const Ge = (e, t) => {
365
413
  ...s?.dimensions.series || [],
366
414
  ...s?.dimensions.observation || []
367
415
  ], o = new Array(r?.length), i = new Array(r?.length);
368
- return n?.forEach((c) => {
369
- const a = r?.findIndex((l) => l.id === c) || 0, u = t[a], d = r[a].values.findIndex(
416
+ return n?.forEach((a) => {
417
+ const c = r?.findIndex((l) => l.id === a) || 0, u = t[c], d = r[c].values.findIndex(
370
418
  (l) => l.id === u || l.value === u
371
419
  ) || 0;
372
- o[a] = d >= 0 ? d : u, i[a] = u;
420
+ o[c] = d >= 0 ? d : u, i[c] = u;
373
421
  }), {
374
422
  codedSeriesKey: o.join(":"),
375
423
  decodedSeriesKey: i.join(":")
376
424
  };
377
- }, Sn = (e, t, n) => {
425
+ }, In = (e, t, n) => {
378
426
  const s = e?.data?.dataSets?.[0], r = e?.data?.structures?.[0], o = (r?.attributes?.dimensionGroup || []).filter(
379
427
  (l) => l.relationship.dimensions?.length === 1 && l.relationship.dimensions.includes(t || "")
380
- ), i = s?.dimensionGroupAttributes, c = [
428
+ ), i = s?.dimensionGroupAttributes, a = [
381
429
  ...r?.dimensions.series || [],
382
430
  ...r?.dimensions.observation || []
383
- ], a = c?.findIndex((l) => l.id === t), u = new Array(c?.length);
384
- u[a] = n || "";
431
+ ], c = a?.findIndex((l) => l.id === t), u = new Array(a?.length);
432
+ u[c] = n || "";
385
433
  const d = {};
386
434
  for (const l of o) {
387
- const m = l.relationship.dimensions, { codedSeriesKey: f, decodedSeriesKey: E } = he(
435
+ const m = l.relationship.dimensions, { codedSeriesKey: f, decodedSeriesKey: p } = he(
388
436
  e,
389
437
  u,
390
438
  m
391
439
  );
392
440
  d[l.id] = {
393
441
  values: i?.[f] || [],
394
- decodedSeriesKey: E,
442
+ decodedSeriesKey: p,
395
443
  codedSeriesKey: f
396
444
  };
397
445
  }
398
446
  return d;
399
- }, Ke = (e, t) => {
447
+ }, Xe = (e, t) => {
400
448
  if (t == null)
401
449
  return;
402
450
  const n = e.values?.[t];
403
451
  return n ?? (t instanceof Array ? { values: t } : { value: t.toString() });
404
- }, je = "Observation", Tn = (e) => {
452
+ }, Ze = "Observation", Nn = (e) => {
405
453
  const t = e?.data?.dataSets, n = e?.data?.structures?.[0];
406
454
  if (!t || !n)
407
455
  return [];
408
- const s = n.attributes, r = n.dimensions, o = s?.dimensionGroup || [], i = t[0].series || t[0].observations, c = r.series?.length ? r.series : r.observation, a = [];
456
+ const s = n.attributes, r = n.dimensions, o = s?.dimensionGroup || [], i = t[0].series || t[0].observations, a = r.series?.length ? r.series : r.observation, c = [];
409
457
  for (const u in i) {
410
- const d = [], { name: l, parsedTimeSeriesValue: m } = He(
458
+ const d = [], { name: l, parsedTimeSeriesValue: m } = et(
411
459
  u,
412
- c
413
- ), f = i[u], E = f.attributes || [];
460
+ a
461
+ ), f = i[u], p = f.attributes || [];
414
462
  if (Object.keys(f).length === 0) {
415
- a.push({
463
+ c.push({
416
464
  name: l,
417
465
  parsedTimeSeriesValue: m,
418
466
  values: d,
@@ -422,29 +470,29 @@ const Ge = (e, t) => {
422
470
  continue;
423
471
  }
424
472
  d.push(
425
- ...Ze(f, n)
473
+ ...rt(f, n)
426
474
  );
427
475
  const w = _(
428
476
  s?.series || [],
429
- (p) => E[p]
430
- ), I = et(
477
+ (E) => p[E]
478
+ ), I = ot(
431
479
  n.attributes?.dataSet || [],
432
- t[0].attributes?.filter((p) => p != null) || []
433
- ), N = Ge(
480
+ t[0].attributes?.filter((E) => E != null) || []
481
+ ), N = Je(
434
482
  e,
435
483
  m
436
- ), $ = o.map((p, ve) => {
437
- const z = N[p.id], Re = Ke(
438
- p,
484
+ ), $ = o.map((E, ve) => {
485
+ const z = N[E.id], Re = Xe(
486
+ E,
439
487
  z.values[ve]
440
488
  );
441
489
  return {
442
- attribute: p,
490
+ attribute: E,
443
491
  dimensionGroupValue: Re,
444
492
  dimensionGroupData: z
445
493
  };
446
494
  });
447
- a.push({
495
+ c.push({
448
496
  name: l,
449
497
  parsedTimeSeriesValue: m,
450
498
  values: d,
@@ -453,38 +501,38 @@ const Ge = (e, t) => {
453
501
  dimensionGroupAttributes: $
454
502
  });
455
503
  }
456
- return a;
457
- }, He = (e, t) => {
504
+ return c;
505
+ }, et = (e, t) => {
458
506
  const n = e.split(new RegExp("(?<!\\|):(?!\\||$)")), s = [];
459
507
  for (let r = 0; r < n.length; r++) {
460
508
  const o = t?.[r], i = Number(n[r]);
461
509
  if (i < 0 || o == null)
462
510
  continue;
463
- const c = o.values[i];
464
- if (c == null) {
511
+ const a = o.values[i];
512
+ if (a == null) {
465
513
  s.push(n[r].replace("|:", ":"));
466
514
  continue;
467
515
  }
468
- s.push(c?.id || c?.value || "");
516
+ s.push(a?.id || a?.value || "");
469
517
  }
470
518
  return {
471
- name: Je(s),
519
+ name: nt(s),
472
520
  parsedTimeSeriesValue: s
473
521
  };
474
522
  }, _ = (e, t) => {
475
523
  const n = [];
476
524
  for (let s = 0; s < e.length; s++) {
477
- const r = e[s], o = t(s), i = o != null && r.values != null ? ze(o, r) : void 0;
525
+ const r = e[s], o = t(s), i = o != null && r.values != null ? tt(o, r) : void 0;
478
526
  n.push({
479
527
  name: r.id,
480
528
  value: i
481
529
  });
482
530
  }
483
531
  return n;
484
- }, ze = (e, t) => {
532
+ }, tt = (e, t) => {
485
533
  const n = t.values[e];
486
534
  return n == null ? typeof e == "object" ? e : e.toString() : n?.id || n?.value || n?.ids || n?.values;
487
- }, Je = (e) => e.map((t) => t ? Xe(t) : "").join("."), Xe = (e) => e.replace(/\./g, "|.").replace(/:/g, "|:"), Ze = (e, t) => {
535
+ }, nt = (e) => e.map((t) => t ? st(t) : "").join("."), st = (e) => e.replace(/\./g, "|.").replace(/:/g, "|:"), rt = (e, t) => {
488
536
  const n = t.measures?.observation?.length;
489
537
  if (e.observations == null)
490
538
  return [
@@ -494,38 +542,38 @@ const Ge = (e, t) => {
494
542
  t.attributes?.observation || [],
495
543
  (i) => e[i + n]
496
544
  ),
497
- dimensionAtObservation: je
545
+ dimensionAtObservation: Ze
498
546
  }
499
547
  ];
500
548
  const s = e.observations, r = t.dimensions.observation?.[0], o = [];
501
549
  for (const i in s) {
502
- const c = r?.values[i];
550
+ const a = r?.values[i];
503
551
  o.push({
504
- dimensionAtObservation: c?.value || c?.id,
552
+ dimensionAtObservation: a?.value || a?.id,
505
553
  values: te(
506
554
  s[i],
507
555
  t.measures
508
556
  ),
509
557
  obsAttributes: _(
510
558
  t.attributes?.observation || [],
511
- (a) => s[i][a + n]
559
+ (c) => s[i][c + n]
512
560
  )
513
561
  });
514
562
  }
515
563
  return o;
516
- }, te = (e, t) => t?.observation?.map((n, s) => ({ name: n.id, value: e[s] })) || [], et = (e, t) => e.reduce(
564
+ }, te = (e, t) => t?.observation?.map((n, s) => ({ name: n.id, value: e[s] })) || [], ot = (e, t) => e.reduce(
517
565
  (n, s, r) => {
518
566
  const o = t[r];
519
- return tt(n, s, o, ""), n;
567
+ return it(n, s, o, ""), n;
520
568
  },
521
569
  []
522
- ), tt = (e, t, n, s) => {
570
+ ), it = (e, t, n, s) => {
523
571
  const r = n != null ? t?.values?.length > 0 ? t.values[n]?.id || t.values[n]?.value : String(n) : s;
524
572
  e.push({
525
573
  name: t.id,
526
574
  value: r || ""
527
575
  });
528
- }, nt = /^[0-9][0-9][0-9][0-9]-Q[1-4]$/, st = /^[0-9][0-9][0-9][0-9]-W[0-9][0-9]?$/, rt = /^[0-9][0-9][0-9][0-9]-S[1-2]$/, ot = /^[0-9][0-9][0-9][0-9]$/, it = /^[0-9][0-9][0-9][0-9]-(0[1-9]|1[0-2])-[0-9][0-9]$/, at = /^[0-9][0-9][0-9][0-9]-M(0[1-9]|(1[0-2]))$/, C = (e) => ot.exec(e), U = (e) => !!C(e), ct = (e) => rt.exec(e), x = (e) => !!ct(e), Y = (e) => at.exec(e), W = (e) => !!Y(e), k = (e) => nt.exec(e), q = (e) => !!k(e), ut = (e) => it.exec(e), dt = (e) => !!ut(e), lt = (e) => st.exec(e), Q = (e) => !!lt(e), V = 1440 * 60 * 1e3, B = 7 * V;
576
+ }, at = /^[0-9][0-9][0-9][0-9]-Q[1-4]$/, ct = /^[0-9][0-9][0-9][0-9]-W[0-9][0-9]?$/, ut = /^[0-9][0-9][0-9][0-9]-S[1-2]$/, dt = /^[0-9][0-9][0-9][0-9]$/, lt = /^[0-9][0-9][0-9][0-9]-(0[1-9]|1[0-2])-[0-9][0-9]$/, mt = /^[0-9][0-9][0-9][0-9]-M(0[1-9]|(1[0-2]))$/, C = (e) => dt.exec(e), U = (e) => !!C(e), ft = (e) => ut.exec(e), x = (e) => !!ft(e), Y = (e) => mt.exec(e), W = (e) => !!Y(e), V = (e) => at.exec(e), k = (e) => !!V(e), gt = (e) => lt.exec(e), ht = (e) => !!gt(e), pt = (e) => ct.exec(e), q = (e) => !!pt(e), Q = 1440 * 60 * 1e3, B = 7 * Q;
529
577
  function F(e) {
530
578
  const t = `${e}-01-01`, n = new Date(t);
531
579
  if (n.getDay() !== 4) {
@@ -534,7 +582,7 @@ function F(e) {
534
582
  }
535
583
  return n;
536
584
  }
537
- function mt(e) {
585
+ function Et(e) {
538
586
  const t = new Date(e), s = -((t.getDay() + 6) % 7) + 3;
539
587
  return t.setDate(t.getDate() + s), new Date(t.valueOf());
540
588
  }
@@ -545,44 +593,44 @@ function ne(e, t = "W") {
545
593
  const r = `${e}-12-24`;
546
594
  return R(new Date(r), t).weekNumber;
547
595
  }
548
- function Ee(e, t, n = "W") {
596
+ function pe(e, t, n = "W") {
549
597
  return `${e}-${n}${t < 10 ? "0" + t : t}`;
550
598
  }
551
599
  function R(e, t = "W") {
552
- const n = mt(e), s = n.getFullYear(), r = F(s), o = 1 + Math.ceil(
600
+ const n = Et(e), s = n.getFullYear(), r = F(s), o = 1 + Math.ceil(
553
601
  (n.getTime() - r.getTime()) / B
554
602
  );
555
603
  return {
556
- code: Ee(s, o, t),
604
+ code: pe(s, o, t),
557
605
  weekNumber: o,
558
606
  weekYear: s
559
607
  };
560
608
  }
561
- function ft(e) {
562
- const [t, n] = e.split("-W"), r = F(+t).getTime() + (+n - 1) * B - 3 * V;
609
+ function Dt(e) {
610
+ const [t, n] = e.split("-W"), r = F(+t).getTime() + (+n - 1) * B - 3 * Q;
563
611
  return new Date(r);
564
612
  }
565
- function gt(e) {
566
- const [t, n] = e.split("-W"), r = F(+t).getTime() + (+n - 1) * B + 3 * V;
613
+ function At(e) {
614
+ const [t, n] = e.split("-W"), r = F(+t).getTime() + (+n - 1) * B + 3 * Q;
567
615
  return new Date(r);
568
616
  }
569
- function pe(e) {
570
- return U(e) ? ht(e) : x(e) ? pt(e) : q(e) ? At(e) : W(e) ? St(e) : Q(e) ? ft(e) : vt(e);
617
+ function Ee(e) {
618
+ return U(e) ? St(e) : x(e) ? Tt(e) : k(e) ? Rt(e) : W(e) ? It(e) : q(e) ? Dt(e) : $t(e);
571
619
  }
572
620
  function De(e) {
573
- return U(e) ? Et(e) : x(e) ? Dt(e) : q(e) ? yt(e) : W(e) ? Tt(e) : Q(e) ? gt(e) : Rt(e);
621
+ return U(e) ? yt(e) : x(e) ? vt(e) : k(e) ? wt(e) : W(e) ? Nt(e) : q(e) ? At(e) : Pt(e);
574
622
  }
575
- function ht(e) {
623
+ function St(e) {
576
624
  const t = C(e);
577
625
  if (t)
578
626
  return new Date(Number(t[0]), 0, 1);
579
627
  }
580
- function Et(e) {
628
+ function yt(e) {
581
629
  const t = C(e);
582
630
  if (t)
583
631
  return new Date(Number(t[0]) + 1, 0, 1);
584
632
  }
585
- function pt(e) {
633
+ function Tt(e) {
586
634
  const [t, n] = e.split("-S");
587
635
  switch (+n) {
588
636
  case 1:
@@ -591,7 +639,7 @@ function pt(e) {
591
639
  return new Date(+t, 6, 1);
592
640
  }
593
641
  }
594
- function Dt(e) {
642
+ function vt(e) {
595
643
  const [t, n] = e.split("-S");
596
644
  switch (+n) {
597
645
  case 1:
@@ -600,8 +648,8 @@ function Dt(e) {
600
648
  return new Date(+t + 1, 0, 1);
601
649
  }
602
650
  }
603
- function At(e) {
604
- const t = k(e);
651
+ function Rt(e) {
652
+ const t = V(e);
605
653
  if (!t)
606
654
  return;
607
655
  const [n, s] = t[0].split("-Q");
@@ -616,8 +664,8 @@ function At(e) {
616
664
  return new Date(+n, 9, 1);
617
665
  }
618
666
  }
619
- function yt(e) {
620
- const t = k(e);
667
+ function wt(e) {
668
+ const t = V(e);
621
669
  if (!t)
622
670
  return;
623
671
  const [n, s] = t[0].split("-Q");
@@ -632,45 +680,45 @@ function yt(e) {
632
680
  return new Date(+n + 1, 0, 1);
633
681
  }
634
682
  }
635
- function St(e) {
683
+ function It(e) {
636
684
  const t = Y(e);
637
685
  if (!t)
638
686
  return;
639
687
  const [n, s] = t[0].split("-M");
640
688
  return new Date(+n, +s - 1, 1);
641
689
  }
642
- function Tt(e) {
690
+ function Nt(e) {
643
691
  const t = Y(e);
644
692
  if (!t)
645
693
  return;
646
694
  const [n, s] = t[0].split("-M");
647
695
  return new Date(+n, +s, 1);
648
696
  }
649
- const vt = (e) => /* @__PURE__ */ new Date(`${e}T00:00:00`), Rt = (e) => {
697
+ const $t = (e) => /* @__PURE__ */ new Date(`${e}T00:00:00`), Pt = (e) => {
650
698
  const t = /* @__PURE__ */ new Date(`${e}T23:59:00`);
651
699
  return t.setMinutes(t.getMinutes() + 1), t;
652
- }, wt = 1, It = (e, t, n, s = !0, r = "Q") => {
653
- const o = [], i = t && t > 3 ? Lt(t, s) : 1, c = n ? Math.floor((n - 1) / 3) : 4;
654
- for (let a = i; a <= c; a++)
655
- o.push(`${e}-${r}${a}`);
700
+ }, bt = 1, _t = (e, t, n, s = !0, r = "Q") => {
701
+ const o = [], i = t && t > 3 ? Yt(t, s) : 1, a = n ? Math.floor((n - 1) / 3) : 4;
702
+ for (let c = i; c <= a; c++)
703
+ o.push(`${e}-${r}${c}`);
656
704
  return o;
657
- }, Nt = (e, t, n, s = "S") => {
705
+ }, Ot = (e, t, n, s = "S") => {
658
706
  const r = [];
659
707
  return (t || 1) < 7 && (n || 12) > 6 && r.push(`${e}-${s}1`), n == null && r.push(`${e}-${s}2`), r;
660
- }, vn = (e) => Math.ceil(e / 3), Ae = (e, t, n = "M") => `${e}-${n}${t.toString().padStart(2, "0")}`, $t = (e, t, n = "M") => {
708
+ }, $n = (e) => Math.ceil(e / 3), Ae = (e, t, n = "M") => `${e}-${n}${t.toString().padStart(2, "0")}`, Lt = (e, t, n = "M") => {
661
709
  const s = [];
662
710
  for (let r = t; r <= 12; r++)
663
711
  s.push(Ae(e, r, n));
664
712
  return s;
665
- }, Pt = (e, t, n, s = "M") => {
713
+ }, Mt = (e, t, n, s = "M") => {
666
714
  const r = [];
667
715
  for (let o = t; o < n; o++)
668
716
  r.push(Ae(e, o, s));
669
717
  return r;
670
- }, bt = (e, t, n, s = "M") => {
718
+ }, Ct = (e, t, n, s = "M") => {
671
719
  const r = t || 1, o = n == null, i = n || 12;
672
- return o ? $t(e, r, s) : Pt(e, r, i, s);
673
- }, Rn = (e, t, n = "M") => {
720
+ return o ? Lt(e, r, s) : Mt(e, r, i, s);
721
+ }, Pn = (e, t, n = "M") => {
674
722
  switch (t) {
675
723
  case 0:
676
724
  return [
@@ -699,165 +747,165 @@ const vt = (e) => /* @__PURE__ */ new Date(`${e}T00:00:00`), Rt = (e) => {
699
747
  default:
700
748
  return [];
701
749
  }
702
- }, _t = (e, t) => {
703
- const n = g(t, !0), s = g(e), r = n.getFullYear(), o = s.getFullYear(), i = n.getTime() <= s.getTime() ? o + wt - r : 0;
704
- return Array.from({ length: i }, (a, u) => r + u);
750
+ }, Ut = (e, t) => {
751
+ const n = g(t, !0), s = g(e), r = n.getFullYear(), o = s.getFullYear(), i = n.getTime() <= s.getTime() ? o + bt - r : 0;
752
+ return Array.from({ length: i }, (c, u) => r + u);
705
753
  }, g = (e, t = !1) => {
706
- const n = Ot(e, t);
754
+ const n = xt(e, t);
707
755
  return n ? (n.getTimezoneOffset() > 0 && n.setMinutes(n.getMinutes() + n.getTimezoneOffset()), n) : /* @__PURE__ */ new Date();
708
- }, Ot = (e, t = !1) => {
756
+ }, xt = (e, t = !1) => {
709
757
  const n = Number(e);
710
- return e.toString().length !== 13 ? t ? pe(e) : De(e) : isNaN(n) ? /* @__PURE__ */ new Date(`${e}T00:00:00.000Z`) : new Date(n);
711
- }, Lt = (e, t) => t ? Math.floor((e + 1) / 3) : Math.ceil((e + 1) / 3), wn = (e, t) => {
758
+ return e.toString().length !== 13 ? t ? Ee(e) : De(e) : isNaN(n) ? /* @__PURE__ */ new Date(`${e}T00:00:00.000Z`) : new Date(n);
759
+ }, Yt = (e, t) => t ? Math.floor((e + 1) / 3) : Math.ceil((e + 1) / 3), bn = (e, t) => {
712
760
  const n = re(e) - re(t);
713
761
  if (n === 0 && e !== t) {
714
762
  const s = se(e), r = se(t);
715
763
  return s - r;
716
764
  }
717
765
  return n;
718
- }, se = (e) => U(e) ? 6 : x(e) ? 5 : q(e) ? 4 : W(e) ? 3 : Q(e) ? 2 : dt(e) ? 1 : 0, re = (e, t = !1) => (t ? pe(e) : De(e))?.getTime() || 0;
719
- var G = /* @__PURE__ */ ((e) => (e.LAST_UPDATE_AT = "lastUpdatedAt", e.SERIES_COUNT = "series_count", e))(G || {}), Mt = /* @__PURE__ */ ((e) => (e.C = "c", e))(Mt || {}), h = /* @__PURE__ */ ((e) => (e.EQUALS = "eq", e.NOT_EQUALS = "ne", e.LESS = "lt", e.LESS_OR_EQUAL = "le", e.GREATER = "gt", e.GREATER_OR_EQUAL = "ge", e.CONTAINS = "co", e.NOT_CONTAINS = "nc", e.STARTS = "sw", e.ENDS = "ew", e))(h || {}), Ct = /* @__PURE__ */ ((e) => (e.BOOLEAN = "Boolean", e.DATE_TIME = "DateTime", e.DECIMAL = "Decimal", e.INTEGER = "Integer", e.OBSERVATION_TIME_PERIOD = "ObservationalTimePeriod", e.STRING = "String", e.TIME = "Time", e.TIME_RANGE = "TimeRange", e.URI = "URI", e))(Ct || {}), Ut = /* @__PURE__ */ ((e) => (e.ANNUAL = "A", e.QUARTERLY = "Q", e.MONTHLY = "M", e))(Ut || {});
720
- function In(e) {
766
+ }, se = (e) => U(e) ? 6 : x(e) ? 5 : k(e) ? 4 : W(e) ? 3 : q(e) ? 2 : ht(e) ? 1 : 0, re = (e, t = !1) => (t ? Ee(e) : De(e))?.getTime() || 0;
767
+ var G = /* @__PURE__ */ ((e) => (e.LAST_UPDATE_AT = "lastUpdatedAt", e.SERIES_COUNT = "series_count", e))(G || {}), Wt = /* @__PURE__ */ ((e) => (e.C = "c", e))(Wt || {}), h = /* @__PURE__ */ ((e) => (e.EQUALS = "eq", e.NOT_EQUALS = "ne", e.LESS = "lt", e.LESS_OR_EQUAL = "le", e.GREATER = "gt", e.GREATER_OR_EQUAL = "ge", e.CONTAINS = "co", e.NOT_CONTAINS = "nc", e.STARTS = "sw", e.ENDS = "ew", e))(h || {}), Vt = /* @__PURE__ */ ((e) => (e.BOOLEAN = "Boolean", e.DATE_TIME = "DateTime", e.DECIMAL = "Decimal", e.INTEGER = "Integer", e.OBSERVATION_TIME_PERIOD = "ObservationalTimePeriod", e.STRING = "String", e.TIME = "Time", e.TIME_RANGE = "TimeRange", e.URI = "URI", e))(Vt || {}), kt = /* @__PURE__ */ ((e) => (e.ANNUAL = "A", e.QUARTERLY = "Q", e.MONTHLY = "M", e))(kt || {});
768
+ function _n(e) {
721
769
  return e?.annotations?.find((t) => {
722
770
  if (t.id === G.LAST_UPDATE_AT)
723
771
  return t;
724
772
  })?.value;
725
773
  }
726
- const K = (e, t) => e?.names && e?.names[t] || e?.name, ye = (e, t, n) => {
774
+ const K = (e, t) => e?.names && e?.names[t] || e?.name, Se = (e, t, n) => {
727
775
  if (!(!e || t?.has(e?.id)) && (t?.set(e?.id, e), e?.parent)) {
728
776
  const s = n?.get(e?.parent);
729
- ye(s, t, n);
777
+ Se(s, t, n);
730
778
  }
731
- }, xt = (e, t) => {
779
+ }, qt = (e, t) => {
732
780
  const n = /* @__PURE__ */ new Map(), s = new Map(e?.map((r) => [r.id, r]));
733
781
  return t?.forEach((r) => {
734
- ye(r, n, s);
782
+ Se(r, n, s);
735
783
  }), Array.from(n?.values());
736
- }, Yt = "time_period_end", Wt = "time_period_start", kt = "TIME_PERIOD", Nn = (e) => {
784
+ }, Qt = "time_period_end", Bt = "time_period_start", Ft = "TIME_PERIOD", On = (e) => {
737
785
  const t = e?.find(
738
- (o) => o.id === Wt
786
+ (o) => o.id === Bt
739
787
  ), n = e?.find(
740
- (o) => o.id === Yt
788
+ (o) => o.id === Qt
741
789
  ), s = n?.title ? new Date(n?.title) : null;
742
790
  return {
743
791
  startPeriod: t?.title ? new Date(t?.title) : null,
744
792
  endPeriod: s
745
793
  };
746
- }, qt = (e, t) => e.id.localeCompare(t.id), Qt = (e, t) => e.memberValue.localeCompare(t.memberValue), Vt = (e, t) => {
747
- const n = new Array(e.length), s = e.map((i, c) => [i, c]);
794
+ }, Gt = (e, t) => e.id.localeCompare(t.id), Kt = (e, t) => e.memberValue.localeCompare(t.memberValue), jt = (e, t) => {
795
+ const n = new Array(e.length), s = e.map((i, a) => [i, a]);
748
796
  s.sort(
749
- (i, c) => qt(i[0], c[0])
797
+ (i, a) => Gt(i[0], a[0])
750
798
  );
751
799
  const r = [...t];
752
- r.sort(Qt);
800
+ r.sort(Kt);
753
801
  let o = 0;
754
802
  for (const i of s) {
755
- const c = i[0];
756
- for (; o < r.length && r[o].memberValue.localeCompare(c.id) < 0; )
803
+ const a = i[0];
804
+ for (; o < r.length && r[o].memberValue.localeCompare(a.id) < 0; )
757
805
  o += 1;
758
- o < r.length && r[o].memberValue === c.id && (n[i[1]] = i[0]);
806
+ o < r.length && r[o].memberValue === a.id && (n[i[1]] = i[0]);
759
807
  }
760
808
  return n.filter((i) => i != null);
761
- }, Bt = (e) => !!e?.some((t) => t.parent), $n = (e, t, n, s, r = []) => {
809
+ }, Ht = (e) => !!e?.some((t) => t.parent), Ln = (e, t, n, s, r = []) => {
762
810
  let o = e || [];
763
- if (Ft(n || [], t || "")) {
811
+ if (zt(n || [], t || "")) {
764
812
  const i = (n || [])[0].cubeRegions?.find(
765
- ({ isIncluded: c }) => c
813
+ ({ isIncluded: a }) => a
766
814
  );
767
815
  if (i) {
768
- const c = i.memberSelection?.find(
769
- ({ componentId: a }) => a === t
816
+ const a = i.memberSelection?.find(
817
+ ({ componentId: c }) => c === t
770
818
  );
771
- c ? o = o.length === 0 ? (c.selectionValues || []).map(({ memberValue: a }) => ({
772
- id: a,
773
- name: a
774
- })) : Vt(o, c.selectionValues) : o = [];
819
+ a ? o = o.length === 0 ? (a.selectionValues || []).map(({ memberValue: c }) => ({
820
+ id: c,
821
+ name: c
822
+ })) : jt(o, a.selectionValues) : o = [];
775
823
  }
776
824
  } else r.length !== 0 && (o = o.filter(({ id: i }) => r.includes(i)));
777
- return Bt(e) && (o = xt(e, o)), o?.map((i) => ({
825
+ return Ht(e) && (o = qt(e, o)), o?.map((i) => ({
778
826
  ...i,
779
827
  name: s ? K(i, s) : i?.name
780
828
  }));
781
- }, Ft = (e, t) => e != null && e.length > 0 && t != null, Pn = (e) => {
829
+ }, zt = (e, t) => e != null && e.length > 0 && t != null, Mn = (e) => {
782
830
  const t = [];
783
831
  return e?.filters?.forEach((n) => {
784
- n.componentCode !== kt && t.push({
832
+ n.componentCode !== Ft && t.push({
785
833
  componentCode: n.componentCode,
786
834
  operator: h.EQUALS,
787
835
  value: n.values.join(",")
788
836
  });
789
837
  }), t;
790
- }, Gt = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, oe = (e) => {
838
+ }, Jt = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, oe = (e) => {
791
839
  if (typeof e != "string")
792
840
  throw new TypeError("Invalid argument expected string");
793
- const t = e.match(Gt);
841
+ const t = e.match(Jt);
794
842
  if (!t)
795
843
  throw new Error(`Invalid argument not valid semver ('${e}' received)`);
796
844
  return t.shift(), t;
797
845
  }, ie = (e) => e === "*" || e === "x" || e === "X", ae = (e) => {
798
846
  const t = parseInt(e, 10);
799
847
  return isNaN(t) ? e : t;
800
- }, Kt = (e, t) => typeof e != typeof t ? [String(e), String(t)] : [e, t], jt = (e, t) => {
848
+ }, Xt = (e, t) => typeof e != typeof t ? [String(e), String(t)] : [e, t], Zt = (e, t) => {
801
849
  if (ie(e) || ie(t))
802
850
  return 0;
803
- const [n, s] = Kt(ae(e), ae(t));
851
+ const [n, s] = Xt(ae(e), ae(t));
804
852
  return n > s ? 1 : n < s ? -1 : 0;
805
853
  }, ce = (e, t) => {
806
854
  for (let n = 0; n < Math.max(e.length, t.length); n++) {
807
- const s = jt(e[n] || "0", t[n] || "0");
855
+ const s = Zt(e[n] || "0", t[n] || "0");
808
856
  if (s !== 0)
809
857
  return s;
810
858
  }
811
859
  return 0;
812
- }, Ht = (e, t) => {
860
+ }, en = (e, t) => {
813
861
  const n = oe(e), s = oe(t), r = n.pop(), o = s.pop(), i = ce(n, s);
814
862
  return i !== 0 ? i : r && o ? ce(r.split("."), o.split(".")) : r || o ? r ? -1 : 1 : 0;
815
- }, zt = (e, t, n) => {
816
- Jt(n);
817
- const s = Ht(e, t);
818
- return Se[n].includes(s);
819
- }, Se = {
863
+ }, tn = (e, t, n) => {
864
+ nn(n);
865
+ const s = en(e, t);
866
+ return ye[n].includes(s);
867
+ }, ye = {
820
868
  ">": [1],
821
869
  ">=": [0, 1],
822
870
  "=": [0],
823
871
  "<=": [-1, 0],
824
872
  "<": [-1],
825
873
  "!=": [-1, 1]
826
- }, ue = Object.keys(Se), Jt = (e) => {
874
+ }, ue = Object.keys(ye), nn = (e) => {
827
875
  if (ue.indexOf(e) === -1)
828
876
  throw new Error(`Invalid operator, expected one of ${ue.join("|")}`);
829
877
  }, O = "+", j = (e, t) => {
830
878
  const { agency: n, id: s, version: r } = D(e), o = t.filter(
831
- (a) => a.agencyID === n && a.id === s && !a?.version?.includes(O)
879
+ (c) => c.agencyID === n && c.id === s && !c?.version?.includes(O)
832
880
  );
833
881
  if (o.length === 1)
834
882
  return o[0];
835
883
  if (!r?.includes(O))
836
- return o.find((a) => a.version === r);
884
+ return o.find((c) => c.version === r);
837
885
  const i = o.map(
838
- (a) => a.version
839
- ), c = Xt(r, i);
886
+ (c) => c.version
887
+ ), a = sn(r, i);
840
888
  return o.find(
841
- (a) => a.version === c[0]
889
+ (c) => c.version === a[0]
842
890
  );
843
- }, Xt = (e, t) => {
844
- const n = Zt(e, t);
891
+ }, sn = (e, t) => {
892
+ const n = rn(e, t);
845
893
  return n.length > 0 ? [n[0]] : [];
846
- }, Zt = (e, t) => {
894
+ }, rn = (e, t) => {
847
895
  const n = [];
848
896
  return t.forEach((s) => {
849
- tn(e, s) && n.push(s);
897
+ an(e, s) && n.push(s);
850
898
  }), n;
851
- }, en = (e) => {
899
+ }, on = (e) => {
852
900
  const t = e.trim().replace(/\d+\+/, "*"), [n] = t.split("*");
853
901
  return new RegExp(`^${n}`);
854
- }, tn = (e, t) => {
902
+ }, an = (e, t) => {
855
903
  const n = e.trim().replace(/\+/, "");
856
- return en(e).test(t) && zt(t, n, ">=");
904
+ return on(e).test(t) && tn(t, n, ">=");
857
905
  }, H = (e, t) => {
858
- const { concept: n } = nn(e, t);
906
+ const { concept: n } = cn(e, t);
859
907
  return n;
860
- }, nn = (e, t) => {
908
+ }, cn = (e, t) => {
861
909
  if (e == null)
862
910
  return {
863
911
  concept: void 0,
@@ -875,7 +923,7 @@ const K = (e, t) => e?.names && e?.names[t] || e?.name, ye = (e, t, n) => {
875
923
  };
876
924
  }
877
925
  for (const i of t)
878
- if (sn(i, r, s, o))
926
+ if (un(i, r, s, o))
879
927
  return {
880
928
  concept: de(i?.concepts || [], n),
881
929
  scheme: i
@@ -884,15 +932,15 @@ const K = (e, t) => e?.names && e?.names[t] || e?.name, ye = (e, t, n) => {
884
932
  concept: void 0,
885
933
  scheme: void 0
886
934
  };
887
- }, de = (e, t) => e?.find((n) => n.id === t), sn = (e, t, n, s) => e.id === t && e.agencyID === n && e.version === s, bn = (e = [], t = [], n) => {
935
+ }, de = (e, t) => e?.find((n) => n.id === t), un = (e, t, n, s) => e.id === t && e.agencyID === n && e.version === s, Cn = (e = [], t = [], n) => {
888
936
  const s = n?.conceptIdentity || "", r = H(s, t), o = v(
889
937
  n?.localRepresentation?.enumeration
890
938
  ), i = v(
891
939
  r?.coreRepresentation?.enumeration
892
- ), c = o || i;
893
- if (c != null)
894
- return j(c, e);
895
- }, _n = (e, t, n, s) => {
940
+ ), a = o || i;
941
+ if (a != null)
942
+ return j(a, e);
943
+ }, Un = (e, t, n, s) => {
896
944
  const r = t?.find(
897
945
  (o) => o?.id === e?.id
898
946
  )?.values;
@@ -900,7 +948,7 @@ const K = (e, t) => e?.names && e?.names[t] || e?.name, ye = (e, t, n) => {
900
948
  ...o,
901
949
  name: s ? K(o, s) : o?.name
902
950
  })) || [];
903
- }, rn = (e, t) => {
951
+ }, dn = (e, t) => {
904
952
  const n = t?.dataStructureComponents?.attributeList, s = e?.metadataStructureComponents?.metadataAttributeList;
905
953
  return n?.metadataAttributeUsages?.map((r) => {
906
954
  const o = s?.metadataAttributes?.find(
@@ -912,55 +960,55 @@ const K = (e, t) => e?.names && e?.names[t] || e?.name, ye = (e, t, n) => {
912
960
  isMandatory: Number(o?.minOccurs) > 0
913
961
  };
914
962
  });
915
- }, On = (e = [], t, n) => {
963
+ }, xn = (e = [], t, n) => {
916
964
  const s = v(t?.conceptIdentity) || "", r = H(s, e);
917
965
  return n ? K(r, n) : r?.name ?? r?.id ?? t?.id;
918
966
  };
919
967
  function le(e) {
920
968
  return e?.dataStructures?.[0]?.dataStructureComponents?.dimensionList;
921
969
  }
922
- function Ln(e) {
970
+ function Yn(e) {
923
971
  return e?.data?.structures?.[0]?.dimensions?.series || [];
924
972
  }
925
- function Mn(e) {
973
+ function Wn(e) {
926
974
  return e?.data?.structures?.[0]?.dimensions?.observation?.[0].values.map((t) => t.value).filter((t) => t != null) || [];
927
975
  }
928
- function Cn(e) {
976
+ function Vn(e) {
929
977
  return e.find(
930
978
  (t) => t.type === M.TIME_DIMENSION
931
979
  );
932
980
  }
933
- const Un = (e) => {
981
+ const kn = (e) => {
934
982
  const t = /* @__PURE__ */ new Map(), n = e?.dataStructures?.[0], s = e?.metadataStructures?.[0], r = e?.conceptSchemes || [], o = e?.codelists || [];
935
983
  return e && [
936
984
  ...le(e)?.dimensions || [],
937
985
  ...le(e)?.timeDimensions || [],
938
- ...rn(s, n),
986
+ ...dn(s, n),
939
987
  ...n?.dataStructureComponents?.attributeList?.attributes || []
940
988
  ].forEach(
941
- (c) => {
942
- const a = H(
943
- c?.conceptIdentity,
989
+ (a) => {
990
+ const c = H(
991
+ a?.conceptIdentity,
944
992
  r
945
- ), u = c?.localRepresentation?.enumeration || a?.coreRepresentation?.enumeration, d = j(
993
+ ), u = a?.localRepresentation?.enumeration || c?.coreRepresentation?.enumeration, d = j(
946
994
  u,
947
995
  o
948
996
  );
949
- c?.id && (u ? t.set(c?.id, {
997
+ a?.id && (u ? t.set(a?.id, {
950
998
  ...d,
951
- name: a?.name,
952
- names: a?.names
953
- }) : t.set(c?.id, {
954
- id: c?.id,
955
- name: a?.name,
956
- names: a?.names
999
+ name: c?.name,
1000
+ names: c?.names
1001
+ }) : t.set(a?.id, {
1002
+ id: a?.id,
1003
+ name: c?.name,
1004
+ names: c?.names
957
1005
  }));
958
1006
  }
959
1007
  ), t;
960
- }, xn = (e) => e?.find(
1008
+ }, qn = (e) => e?.find(
961
1009
  (t) => t.id === G.SERIES_COUNT
962
- )?.title || "", on = "/api/download", Yn = (e, t, n, s, r, o, i) => {
963
- const c = new URLSearchParams({
1010
+ )?.title || "", ln = "/api/download", Qn = (e, t, n, s, r, o, i) => {
1011
+ const a = new URLSearchParams({
964
1012
  urn: e,
965
1013
  format: t,
966
1014
  compress: "false",
@@ -969,18 +1017,18 @@ const Un = (e) => {
969
1017
  attribute: s,
970
1018
  language: n,
971
1019
  isMetadata: i ? "true" : "none"
972
- }).toString(), a = `${on}?${c}`;
973
- window.open(a, "_blank");
974
- }, Wn = (e, t) => {
1020
+ }).toString(), c = `${ln}?${a}`;
1021
+ window.open(c, "_blank");
1022
+ }, Bn = (e, t) => {
975
1023
  const n = [];
976
1024
  for (const s of e) {
977
1025
  if (s.type !== M.DIMENSION)
978
1026
  continue;
979
1027
  const r = t.find((o) => o.componentCode === s.id);
980
- r != null && r.values?.length > 0 ? n.push(r.values?.join(Me)) : n.push("*");
1028
+ r != null && r.values?.length > 0 ? n.push(r.values?.join(We)) : n.push("*");
981
1029
  }
982
1030
  return n.join(".");
983
- }, an = (e, t) => {
1031
+ }, mn = (e, t) => {
984
1032
  if (!e || !e.startPeriod && !e.endPeriod)
985
1033
  return null;
986
1034
  const n = [], { startPeriod: s, endPeriod: r } = e;
@@ -992,46 +1040,46 @@ const Un = (e) => {
992
1040
  return null;
993
1041
  const o = t;
994
1042
  return n.map(
995
- (i) => `${encodeURIComponent(`c[${o}]`)}${Le}${encodeURIComponent(i)}`
1043
+ (i) => `${encodeURIComponent(`c[${o}]`)}${Ye}${encodeURIComponent(i)}`
996
1044
  ).join(ge);
997
- }, kn = (e, t) => {
998
- const n = cn(e, t) || null;
999
- return n ? an(n, t?.id) : null;
1000
- }, cn = (e, t) => {
1045
+ }, Fn = (e, t) => {
1046
+ const n = fn(e, t) || null;
1047
+ return n ? mn(n, t?.id) : null;
1048
+ }, fn = (e, t) => {
1001
1049
  const n = t.id, s = e?.filters?.find(
1002
- (a) => a.componentCode === n
1050
+ (c) => c.componentCode === n
1003
1051
  );
1004
1052
  if (!s || !s.values)
1005
1053
  return null;
1006
- const r = s.values?.filter((a) => !!a);
1054
+ const r = s.values?.filter((c) => !!c);
1007
1055
  if (!r.length)
1008
1056
  return null;
1009
1057
  const o = s.operator;
1010
1058
  if (o === h.LESS_OR_EQUAL || o === h.LESS)
1011
- return { startPeriod: null, endPeriod: y(r[0]) };
1059
+ return { startPeriod: null, endPeriod: S(r[0]) };
1012
1060
  if (o === h.GREATER_OR_EQUAL || o === h.GREATER)
1013
- return { startPeriod: y(r[0]), endPeriod: null };
1014
- const i = y(r[0]), c = y(r[1]);
1015
- return { startPeriod: i, endPeriod: c };
1061
+ return { startPeriod: S(r[0]), endPeriod: null };
1062
+ const i = S(r[0]), a = S(r[1]);
1063
+ return { startPeriod: i, endPeriod: a };
1016
1064
  }, Te = (e, t, n) => {
1017
- const s = g(t, !0), r = g(n), o = g(e, !0), i = g(e), c = s.getTime() > o.getTime() ? s : o, a = r.getTime() < i.getTime() ? r : i;
1065
+ const s = g(t, !0), r = g(n), o = g(e, !0), i = g(e), a = s.getTime() > o.getTime() ? s : o, c = r.getTime() < i.getTime() ? r : i;
1018
1066
  return {
1019
- start: c,
1020
- end: a
1067
+ start: a,
1068
+ end: c
1021
1069
  };
1022
- }, un = (e, t, n, s = "W") => {
1070
+ }, gn = (e, t, n, s = "W") => {
1023
1071
  const r = +e, { start: o, end: i } = Te(e, t, n);
1024
1072
  if (o.getTime() > i.getTime())
1025
1073
  return [];
1026
- const c = R(o, s), a = c.weekYear === r ? c.weekNumber : c.weekYear < r ? 1 : ne(r, s), u = R(i, s), d = u.weekYear === r ? u.weekNumber : u.weekYear > r ? ne(r, s) : 1, l = [];
1027
- if (a < d)
1028
- for (let m = a; m <= d; m++)
1029
- l.push(Ee(r, m, s));
1074
+ const a = R(o, s), c = a.weekYear === r ? a.weekNumber : a.weekYear < r ? 1 : ne(r, s), u = R(i, s), d = u.weekYear === r ? u.weekNumber : u.weekYear > r ? ne(r, s) : 1, l = [];
1075
+ if (c < d)
1076
+ for (let m = c; m <= d; m++)
1077
+ l.push(pe(r, m, s));
1030
1078
  return l;
1031
- }, dn = (e) => {
1079
+ }, hn = (e) => {
1032
1080
  const t = new Date(e);
1033
1081
  return t.setMinutes(t.getMinutes() - t.getTimezoneOffset()), t.toISOString().slice(0, 10);
1034
- }, ln = (e, t, n) => {
1082
+ }, pn = (e, t, n) => {
1035
1083
  const { start: s, end: r } = Te(e, t, n);
1036
1084
  if (s.getTime() > r.getTime())
1037
1085
  return [];
@@ -1039,13 +1087,13 @@ const Un = (e) => {
1039
1087
  s.getFullYear(),
1040
1088
  s.getMonth(),
1041
1089
  s.getDate()
1042
- ), c = new Date(r.getFullYear(), r.getMonth(), r.getDate());
1043
- for (; i.getTime() < c.getTime(); ) {
1044
- const a = dn(i);
1045
- o.push(a), i.setDate(i.getDate() + 1);
1090
+ ), a = new Date(r.getFullYear(), r.getMonth(), r.getDate());
1091
+ for (; i.getTime() < a.getTime(); ) {
1092
+ const c = hn(i);
1093
+ o.push(c), i.setDate(i.getDate() + 1);
1046
1094
  }
1047
1095
  return o;
1048
- }, mn = (e) => ({
1096
+ }, En = (e) => ({
1049
1097
  isDailyExist: !!e?.some(({ memberValue: t }) => t === "D"),
1050
1098
  isWeeklyExist: !!e?.some(({ memberValue: t }) => t === "W"),
1051
1099
  isMonthlyExist: !!e?.some(({ memberValue: t }) => t === "M"),
@@ -1054,157 +1102,157 @@ const Un = (e) => {
1054
1102
  isYearlyExist: !!e?.some(
1055
1103
  ({ memberValue: t }) => t === "A" || t === "Y"
1056
1104
  )
1057
- }), fn = (e, t, n, s) => {
1105
+ }), Dn = (e, t, n, s) => {
1058
1106
  const r = s === 0 ? g(t.toString(), !0)?.getMonth() + 1 : void 0, o = s === e.length - 1 ? g(n.toString())?.getMonth() + 1 || 1 : void 0;
1059
1107
  return { startMonth: r, endMonth: o };
1060
- }, gn = ["FREQUENCY", "FREQ"], qn = (e, t) => {
1108
+ }, An = ["FREQUENCY", "FREQ"], Gn = (e, t) => {
1061
1109
  const n = e?.[0]?.cubeRegions?.[0]?.memberSelection?.find(
1062
- (a) => gn.includes(a.componentId)
1063
- )?.selectionValues, s = mn(n || []), r = t?.startPeriod?.getTime() || 1, o = t?.endPeriod?.getTime() || 1, i = _t(o, r), c = [];
1064
- return i.forEach((a, u) => {
1065
- const d = [], { startMonth: l, endMonth: m } = fn(
1110
+ (c) => An.includes(c.componentId)
1111
+ )?.selectionValues, s = En(n || []), r = t?.startPeriod?.getTime() || 1, o = t?.endPeriod?.getTime() || 1, i = Ut(o, r), a = [];
1112
+ return i.forEach((c, u) => {
1113
+ const d = [], { startMonth: l, endMonth: m } = Dn(
1066
1114
  i,
1067
1115
  new Date(r),
1068
1116
  new Date(o),
1069
1117
  u
1070
1118
  ), {
1071
1119
  isDailyExist: f,
1072
- isWeeklyExist: E,
1120
+ isWeeklyExist: p,
1073
1121
  isMonthlyExist: w,
1074
1122
  isQuarterlyExist: I,
1075
1123
  isSemiAnnualExist: N,
1076
1124
  isYearlyExist: $
1077
1125
  } = s;
1078
- $ && d.push(a.toString()), N && d.push(...Nt(a, l, m)), I && d.push(
1079
- ...It(a, l, m, !1)
1080
- ), w && d.push(...bt(a, l, m)), E && d.push(
1081
- ...un(a, r.toString(), o.toString())
1126
+ $ && d.push(c.toString()), N && d.push(...Ot(c, l, m)), I && d.push(
1127
+ ..._t(c, l, m, !1)
1128
+ ), w && d.push(...Ct(c, l, m)), p && d.push(
1129
+ ...gn(c, r.toString(), o.toString())
1082
1130
  ), f && d.push(
1083
- ...ln(a, r.toString(), o.toString())
1084
- ), c.push(...d);
1085
- }), c;
1131
+ ...pn(c, r.toString(), o.toString())
1132
+ ), a.push(...d);
1133
+ }), a;
1086
1134
  };
1087
- function hn(e) {
1135
+ function Sn(e) {
1088
1136
  const { urn: t } = e.details;
1089
1137
  return Ie(t.resourceId, t.version, t.agencyId);
1090
1138
  }
1091
- function Qn(e) {
1139
+ function Kn(e) {
1092
1140
  const t = {};
1093
1141
  for (const n of e.datasets) {
1094
- const s = n.dataset, r = hn(s);
1142
+ const s = n.dataset, r = Sn(s);
1095
1143
  t[r] = s.details.dimensions;
1096
1144
  }
1097
1145
  return t;
1098
1146
  }
1099
1147
  export {
1100
1148
  G as Annotations,
1101
- Be as AssignmentStatus,
1102
- En as AvailabilityApi,
1103
- Oe as DATASET_DATA_URL,
1104
- Dn as DatasetApi,
1149
+ He as AssignmentStatus,
1150
+ yn as AvailabilityApi,
1151
+ xe as DATASET_DATA_URL,
1152
+ vn as DatasetApi,
1105
1153
  M as DimensionType,
1106
- Pe as DownloadType,
1107
- yn as FREQUENCY_DIMENSION_ID,
1108
- gn as FREQUENCY_DIM_ID,
1109
- $e as FileColumnsAttribute,
1110
- Ce as GET_v3_FILTER_ALL,
1111
- pn as GET_v3_FILTER_AND,
1112
- Me as GET_v3_FILTER_OR,
1113
- je as OBSERVATION_KEY,
1114
- Fe as OccurrenceType,
1115
- Ut as Periods,
1116
- Ct as RepresentationTextType,
1117
- Mt as SDMX_DATA_QUERY_PARAMS,
1154
+ Me as DownloadType,
1155
+ wn as FREQUENCY_DIMENSION_ID,
1156
+ An as FREQUENCY_DIM_ID,
1157
+ Le as FileColumnsAttribute,
1158
+ Ve as GET_v3_FILTER_ALL,
1159
+ Tn as GET_v3_FILTER_AND,
1160
+ We as GET_v3_FILTER_OR,
1161
+ Ze as OBSERVATION_KEY,
1162
+ ze as OccurrenceType,
1163
+ kt as Periods,
1164
+ Vt as RepresentationTextType,
1165
+ Wt as SDMX_DATA_QUERY_PARAMS,
1118
1166
  O as SINGLE_WILDCARD_SYMBOL,
1119
- An as SdmxApiClient,
1167
+ Rn as SdmxApiClient,
1120
1168
  me as SdmxAvailabilityMode,
1121
- S as SdmxDataFormat,
1169
+ y as SdmxDataFormat,
1122
1170
  fe as SdmxDetails,
1123
1171
  L as SdmxReferences,
1124
1172
  h as SeriesFilterOperator,
1125
- kt as TIME_PERIOD,
1126
- Yt as TIME_PERIOD_END,
1127
- Wt as TIME_PERIOD_START,
1128
- Qn as buildDatasetDimensionsMetadataMap,
1129
- it as dailyPattern,
1130
- Xe as decodeDimensionId,
1131
- bn as findCodelistByDimension,
1173
+ Ft as TIME_PERIOD,
1174
+ Qt as TIME_PERIOD_END,
1175
+ Bt as TIME_PERIOD_START,
1176
+ Kn as buildDatasetDimensionsMetadataMap,
1177
+ lt as dailyPattern,
1178
+ st as decodeDimensionId,
1179
+ Cn as findCodelistByDimension,
1132
1180
  X as generateDatasetDataRequest,
1133
1181
  Ie as generateShortUrn,
1134
- qn as getAdditionalColumns,
1135
- Nn as getAnnotationPeriod,
1182
+ Gn as getAdditionalColumns,
1183
+ On as getAnnotationPeriod,
1136
1184
  j as getArtifactByUrnWithWildCard,
1137
- Sn as getAttachedDimensionsSeriesByDimension,
1138
- Ge as getAttachedDimensionsSeriesByTsId,
1185
+ In as getAttachedDimensionsSeriesByDimension,
1186
+ Je as getAttachedDimensionsSeriesByTsId,
1139
1187
  he as getAttachedDimensionsSeriesKey,
1140
- Ke as getAttributeValueFromDataQueryResponse,
1141
- _n as getAvailableCodes,
1142
- $n as getAvailableCodesFromConstrains,
1188
+ Xe as getAttributeValueFromDataQueryResponse,
1189
+ Un as getAvailableCodes,
1190
+ Ln as getAvailableCodesFromConstrains,
1143
1191
  we as getChildParsedUrn,
1144
1192
  H as getConcept,
1145
1193
  de as getConceptByUrn,
1146
- nn as getConceptWithScheme,
1147
- rn as getConvertedMetaAttributes,
1148
- ut as getDailyRegExp,
1149
- ln as getDaysColumns,
1150
- On as getDimensionTitle,
1194
+ cn as getConceptWithScheme,
1195
+ dn as getConvertedMetaAttributes,
1196
+ gt as getDailyRegExp,
1197
+ pn as getDaysColumns,
1198
+ xn as getDimensionTitle,
1151
1199
  le as getDimensions,
1152
- xt as getFilteredItemsWithParents,
1153
- Pn as getFiltersDtoFromDataQuery,
1200
+ qt as getFilteredItemsWithParents,
1201
+ Mn as getFiltersDtoFromDataQuery,
1154
1202
  R as getISOWeek,
1155
1203
  v as getKeyFromUrn,
1156
- In as getLastUpdatedTime,
1204
+ _n as getLastUpdatedTime,
1157
1205
  ne as getLastWeekNumberOfYear,
1158
1206
  K as getLocalizedName,
1159
- bt as getMonthlyData,
1160
- Rn as getMonthlyDataByQuarter,
1207
+ Ct as getMonthlyData,
1208
+ Pn as getMonthlyDataByQuarter,
1161
1209
  Y as getMonthlyRegExp,
1162
1210
  De as getParsedEndPeriodDate,
1163
- Tn as getParsedResponse,
1164
- pe as getParsedStartPeriodDate,
1211
+ Nn as getParsedResponse,
1212
+ Ee as getParsedStartPeriodDate,
1165
1213
  g as getPeriodDate,
1166
- mn as getPeriods,
1167
- vn as getQuarterByMonth,
1168
- k as getQuarterlyRegExp,
1169
- It as getQuartersData,
1170
- an as getQueryTimePeriodFilters,
1171
- be as getRequestAcceptHeader,
1172
- Xt as getResolvedVersionBySingleWildcard,
1173
- Nt as getSemiAnnualData,
1174
- ct as getSemiAnnuallyRegExp,
1214
+ En as getPeriods,
1215
+ $n as getQuarterByMonth,
1216
+ V as getQuarterlyRegExp,
1217
+ _t as getQuartersData,
1218
+ mn as getQueryTimePeriodFilters,
1219
+ Ce as getRequestAcceptHeader,
1220
+ sn as getResolvedVersionBySingleWildcard,
1221
+ Ot as getSemiAnnualData,
1222
+ ft as getSemiAnnuallyRegExp,
1175
1223
  _ as getSeriesAttributes,
1176
- He as getSeriesName,
1177
- Un as getStructureComponentsMap,
1178
- Ln as getStructureDimensions,
1179
- Cn as getTimeDimension,
1180
- Mn as getTimePeriods,
1181
- kn as getTimeQueryFilter,
1182
- cn as getTimeRangeFromAttachment,
1183
- xn as getTimeSeriesCount,
1184
- Wn as getTimeSeriesFilterKey,
1185
- Je as getTimeSeriesId,
1186
- Ee as getWeekCode,
1187
- gt as getWeeklyPeriodEndDate,
1188
- ft as getWeeklyPeriodStartDate,
1189
- lt as getWeeklyRegExp,
1190
- un as getWeeksColumns,
1191
- en as getWildCardRegexp,
1224
+ et as getSeriesName,
1225
+ kn as getStructureComponentsMap,
1226
+ Yn as getStructureDimensions,
1227
+ Vn as getTimeDimension,
1228
+ Wn as getTimePeriods,
1229
+ Fn as getTimeQueryFilter,
1230
+ fn as getTimeRangeFromAttachment,
1231
+ qn as getTimeSeriesCount,
1232
+ Bn as getTimeSeriesFilterKey,
1233
+ nt as getTimeSeriesId,
1234
+ pe as getWeekCode,
1235
+ At as getWeeklyPeriodEndDate,
1236
+ Dt as getWeeklyPeriodStartDate,
1237
+ pt as getWeeklyRegExp,
1238
+ gn as getWeeksColumns,
1239
+ on as getWildCardRegexp,
1192
1240
  Te as getYearPeriod,
1193
1241
  C as getYearlyRegExp,
1194
- _t as getYears,
1195
- dt as isDaily,
1242
+ Ut as getYears,
1243
+ ht as isDaily,
1196
1244
  W as isMonthly,
1197
- q as isQuarterly,
1245
+ k as isQuarterly,
1198
1246
  x as isSemiAnnually,
1199
- Q as isWeekly,
1200
- tn as isWildCardVersionCorrect,
1247
+ q as isWeekly,
1248
+ an as isWildCardVersionCorrect,
1201
1249
  U as isYearly,
1202
- at as monthlyPattern,
1203
- Yn as openDownloadWindow,
1204
- nt as quarterPattern,
1205
- rt as semiAnnuallyPattern,
1206
- wn as sortPeriods,
1250
+ mt as monthlyPattern,
1251
+ Qn as openDownloadWindow,
1252
+ at as quarterPattern,
1253
+ ut as semiAnnuallyPattern,
1254
+ bn as sortPeriods,
1207
1255
  D as splitUrn,
1208
- st as weeklyPattern,
1209
- ot as yearlyPattern
1256
+ ct as weeklyPattern,
1257
+ dt as yearlyPattern
1210
1258
  };