@hpcc-js/comms 3.6.2 → 3.7.0
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/browser/index.js +881 -13
- package/dist/browser/index.js.map +1 -1
- package/dist/browser/index.umd.cjs +2 -2
- package/dist/browser/index.umd.cjs.map +1 -1
- package/dist/node/index.cjs +110 -13
- package/dist/node/index.cjs.map +4 -4
- package/dist/node/index.js +110 -13
- package/dist/node/index.js.map +4 -4
- package/package.json +11 -11
- package/src/__package__.ts +2 -2
- package/src/clienttools/eclMeta.ts +2 -2
- package/src/clienttools/eclcc.ts +4 -4
- package/src/ecl/logicalFile.ts +4 -0
- package/src/ecl/scope.ts +0 -4
- package/src/index.node.ts +1 -1
- package/src/services/wsAccount.ts +1 -1
- package/src/services/wsDFU.ts +16 -0
- package/src/services/wsdl/ws_account/v1.07/ws_account.ts +114 -0
- package/types/__package__.d.ts +2 -2
- package/types/ecl/logicalFile.d.ts +1 -0
- package/types/services/wsAccount.d.ts +1 -1
- package/types/services/wsDFU.d.ts +4 -0
- package/types/services/wsdl/ws_account/{v1.06 → v1.07}/ws_account.d.ts +4 -0
package/dist/browser/index.js
CHANGED
|
@@ -2,10 +2,7 @@ var __defProp = Object.defineProperty;
|
|
|
2
2
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: !0, configurable: !0, writable: !0, value }) : obj[key] = value;
|
|
3
3
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key != "symbol" ? key + "" : key, value);
|
|
4
4
|
import { scopedLogger, join, promiseTimeout, exists, deepMixin, xml2json, StateObject, Cache, Graph, Subgraph as Subgraph$1, Vertex as Vertex$1, Edge as Edge$1, SAXStackParser, Stack, espTime2Seconds as espTime2Seconds$1, deepMixinT, XMLNode, debounce, Message, Dispatch } from "@hpcc-js/util";
|
|
5
|
-
|
|
6
|
-
import { format } from "d3-format";
|
|
7
|
-
import { utcFormat, utcParse } from "d3-time-format";
|
|
8
|
-
const PKG_NAME = "@hpcc-js/comms", PKG_VERSION = "3.6.1", BUILD_VERSION = "3.7.1", logger$6 = scopedLogger("comms/connection.ts");
|
|
5
|
+
const PKG_NAME = "@hpcc-js/comms", PKG_VERSION = "3.6.3", BUILD_VERSION = "3.7.3", logger$6 = scopedLogger("comms/connection.ts");
|
|
9
6
|
function instanceOfIOptions(object) {
|
|
10
7
|
return "baseUrl" in object;
|
|
11
8
|
}
|
|
@@ -549,7 +546,7 @@ class AccessService extends AccessServiceBase {
|
|
|
549
546
|
}
|
|
550
547
|
class AccountServiceBase extends Service {
|
|
551
548
|
constructor(optsConnection) {
|
|
552
|
-
super(optsConnection, "ws_account", "1.
|
|
549
|
+
super(optsConnection, "ws_account", "1.07");
|
|
553
550
|
}
|
|
554
551
|
MyAccount(request) {
|
|
555
552
|
return this._connection.send("MyAccount", request, "json", !1, void 0, "MyAccountResponse");
|
|
@@ -874,6 +871,16 @@ class DFUService extends DfuServiceBase {
|
|
|
874
871
|
DFUFile(request) {
|
|
875
872
|
return this._connection.send("DFUDefFile", request, "text");
|
|
876
873
|
}
|
|
874
|
+
async recursiveFetchLogicalFiles(superFiles) {
|
|
875
|
+
const childSuperFiles = [], logicalFiles = [];
|
|
876
|
+
return await Promise.all(superFiles.map((superFile) => this.DFUInfo({ Cluster: superFile.NodeGroup, Name: superFile.Name, IncludeJsonTypeInfo: !1, IncludeBinTypeInfo: !1, ForceIndexInfo: !1 }).then((response) => {
|
|
877
|
+
var _a, _b, _c, _d;
|
|
878
|
+
for (const child of ((_b = (_a = response == null ? void 0 : response.FileDetail) == null ? void 0 : _a.Superfiles) == null ? void 0 : _b.DFULogicalFile) ?? [])
|
|
879
|
+
childSuperFiles.push(child);
|
|
880
|
+
for (const child of ((_d = (_c = response == null ? void 0 : response.FileDetail) == null ? void 0 : _c.subfiles) == null ? void 0 : _d.Item) ?? [])
|
|
881
|
+
logicalFiles.push(child);
|
|
882
|
+
}))), logicalFiles.concat(childSuperFiles.length ? await this.recursiveFetchLogicalFiles(childSuperFiles) : []);
|
|
883
|
+
}
|
|
877
884
|
}
|
|
878
885
|
class DFUXRefService extends Service {
|
|
879
886
|
constructor(optsConnection) {
|
|
@@ -944,7 +951,6 @@ function jsonToIField(id, item) {
|
|
|
944
951
|
fields: jsonToIFieldObj(item)
|
|
945
952
|
};
|
|
946
953
|
}
|
|
947
|
-
// Fall through ---
|
|
948
954
|
default:
|
|
949
955
|
throw new Error("Unknown field type");
|
|
950
956
|
}
|
|
@@ -1192,6 +1198,60 @@ class LogaccessService extends LogaccessServiceBase {
|
|
|
1192
1198
|
});
|
|
1193
1199
|
}
|
|
1194
1200
|
}
|
|
1201
|
+
function ascending(a, b) {
|
|
1202
|
+
return a < b ? -1 : a > b ? 1 : a >= b ? 0 : NaN;
|
|
1203
|
+
}
|
|
1204
|
+
function bisector(compare) {
|
|
1205
|
+
return compare.length === 1 && (compare = ascendingComparator(compare)), {
|
|
1206
|
+
left: function(a, x, lo, hi) {
|
|
1207
|
+
for (lo == null && (lo = 0), hi == null && (hi = a.length); lo < hi; ) {
|
|
1208
|
+
var mid = lo + hi >>> 1;
|
|
1209
|
+
compare(a[mid], x) < 0 ? lo = mid + 1 : hi = mid;
|
|
1210
|
+
}
|
|
1211
|
+
return lo;
|
|
1212
|
+
},
|
|
1213
|
+
right: function(a, x, lo, hi) {
|
|
1214
|
+
for (lo == null && (lo = 0), hi == null && (hi = a.length); lo < hi; ) {
|
|
1215
|
+
var mid = lo + hi >>> 1;
|
|
1216
|
+
compare(a[mid], x) > 0 ? hi = mid : lo = mid + 1;
|
|
1217
|
+
}
|
|
1218
|
+
return lo;
|
|
1219
|
+
}
|
|
1220
|
+
};
|
|
1221
|
+
}
|
|
1222
|
+
function ascendingComparator(f) {
|
|
1223
|
+
return function(d, x) {
|
|
1224
|
+
return ascending(f(d), x);
|
|
1225
|
+
};
|
|
1226
|
+
}
|
|
1227
|
+
bisector(ascending);
|
|
1228
|
+
function number(x) {
|
|
1229
|
+
return x === null ? NaN : +x;
|
|
1230
|
+
}
|
|
1231
|
+
function d3Max(values, valueof) {
|
|
1232
|
+
var n = values.length, i = -1, value, max;
|
|
1233
|
+
if (valueof == null) {
|
|
1234
|
+
for (; ++i < n; )
|
|
1235
|
+
if ((value = values[i]) != null && value >= value)
|
|
1236
|
+
for (max = value; ++i < n; )
|
|
1237
|
+
(value = values[i]) != null && value > max && (max = value);
|
|
1238
|
+
} else
|
|
1239
|
+
for (; ++i < n; )
|
|
1240
|
+
if ((value = valueof(values[i], i, values)) != null && value >= value)
|
|
1241
|
+
for (max = value; ++i < n; )
|
|
1242
|
+
(value = valueof(values[i], i, values)) != null && value > max && (max = value);
|
|
1243
|
+
return max;
|
|
1244
|
+
}
|
|
1245
|
+
function d3Mean(values, valueof) {
|
|
1246
|
+
var n = values.length, m = n, i = -1, value, sum = 0;
|
|
1247
|
+
if (valueof == null)
|
|
1248
|
+
for (; ++i < n; )
|
|
1249
|
+
isNaN(value = number(values[i])) ? --m : sum += value;
|
|
1250
|
+
else
|
|
1251
|
+
for (; ++i < n; )
|
|
1252
|
+
isNaN(value = number(valueof(values[i], i, values))) ? --m : sum += value;
|
|
1253
|
+
if (m) return sum / m;
|
|
1254
|
+
}
|
|
1195
1255
|
class MachineServiceBase extends Service {
|
|
1196
1256
|
constructor(optsConnection) {
|
|
1197
1257
|
super(optsConnection, "ws_machine", "1.17");
|
|
@@ -1246,8 +1306,8 @@ class MachineService extends MachineServiceBase {
|
|
|
1246
1306
|
NetAddress: mu.NetAddress,
|
|
1247
1307
|
Description: mu.Description,
|
|
1248
1308
|
DiskUsages,
|
|
1249
|
-
mean:
|
|
1250
|
-
max:
|
|
1309
|
+
mean: d3Mean(DiskUsages.filter((du) => !isNaN(du.PercentUsed)), (du) => du.PercentUsed),
|
|
1310
|
+
max: d3Max(DiskUsages.filter((du) => !isNaN(du.PercentUsed)), (du) => du.PercentUsed)
|
|
1251
1311
|
};
|
|
1252
1312
|
});
|
|
1253
1313
|
return {
|
|
@@ -1256,8 +1316,8 @@ class MachineService extends MachineServiceBase {
|
|
|
1256
1316
|
Description: cu.Description,
|
|
1257
1317
|
MachineUsages,
|
|
1258
1318
|
MachineUsagesDescription: MachineUsages.reduce((prev, mu) => prev + (mu.Description || ""), ""),
|
|
1259
|
-
mean:
|
|
1260
|
-
max:
|
|
1319
|
+
mean: d3Mean(MachineUsages.filter((mu) => !isNaN(mu.mean)), (mu) => mu.mean),
|
|
1320
|
+
max: d3Max(MachineUsages.filter((mu) => !isNaN(mu.max)), (mu) => mu.max)
|
|
1261
1321
|
};
|
|
1262
1322
|
});
|
|
1263
1323
|
return {
|
|
@@ -1265,8 +1325,8 @@ class MachineService extends MachineServiceBase {
|
|
|
1265
1325
|
Description: tcu.Description,
|
|
1266
1326
|
ComponentUsages,
|
|
1267
1327
|
ComponentUsagesDescription: ComponentUsages.reduce((prev, cu) => prev + (cu.MachineUsagesDescription || ""), ""),
|
|
1268
|
-
mean:
|
|
1269
|
-
max:
|
|
1328
|
+
mean: d3Mean(ComponentUsages.filter((cu) => !isNaN(cu.mean)), (cu) => cu.mean),
|
|
1329
|
+
max: d3Max(ComponentUsages.filter((cu) => !isNaN(cu.max)), (cu) => cu.max)
|
|
1270
1330
|
};
|
|
1271
1331
|
}));
|
|
1272
1332
|
}
|
|
@@ -1973,6 +2033,811 @@ class WorkunitsServiceEx extends WorkunitsServiceBase {
|
|
|
1973
2033
|
return this._connection.send("WUPublishWorkunit", request);
|
|
1974
2034
|
}
|
|
1975
2035
|
}
|
|
2036
|
+
function formatDecimal(x) {
|
|
2037
|
+
return Math.abs(x = Math.round(x)) >= 1e21 ? x.toLocaleString("en").replace(/,/g, "") : x.toString(10);
|
|
2038
|
+
}
|
|
2039
|
+
function formatDecimalParts(x, p) {
|
|
2040
|
+
if ((i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf("e")) < 0) return null;
|
|
2041
|
+
var i, coefficient = x.slice(0, i);
|
|
2042
|
+
return [
|
|
2043
|
+
coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient,
|
|
2044
|
+
+x.slice(i + 1)
|
|
2045
|
+
];
|
|
2046
|
+
}
|
|
2047
|
+
function exponent(x) {
|
|
2048
|
+
return x = formatDecimalParts(Math.abs(x)), x ? x[1] : NaN;
|
|
2049
|
+
}
|
|
2050
|
+
function formatGroup(grouping, thousands) {
|
|
2051
|
+
return function(value, width) {
|
|
2052
|
+
for (var i = value.length, t = [], j = 0, g = grouping[0], length = 0; i > 0 && g > 0 && (length + g + 1 > width && (g = Math.max(1, width - length)), t.push(value.substring(i -= g, i + g)), !((length += g + 1) > width)); )
|
|
2053
|
+
g = grouping[j = (j + 1) % grouping.length];
|
|
2054
|
+
return t.reverse().join(thousands);
|
|
2055
|
+
};
|
|
2056
|
+
}
|
|
2057
|
+
function formatNumerals(numerals) {
|
|
2058
|
+
return function(value) {
|
|
2059
|
+
return value.replace(/[0-9]/g, function(i) {
|
|
2060
|
+
return numerals[+i];
|
|
2061
|
+
});
|
|
2062
|
+
};
|
|
2063
|
+
}
|
|
2064
|
+
var re = /^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;
|
|
2065
|
+
function formatSpecifier(specifier) {
|
|
2066
|
+
if (!(match = re.exec(specifier))) throw new Error("invalid format: " + specifier);
|
|
2067
|
+
var match;
|
|
2068
|
+
return new FormatSpecifier({
|
|
2069
|
+
fill: match[1],
|
|
2070
|
+
align: match[2],
|
|
2071
|
+
sign: match[3],
|
|
2072
|
+
symbol: match[4],
|
|
2073
|
+
zero: match[5],
|
|
2074
|
+
width: match[6],
|
|
2075
|
+
comma: match[7],
|
|
2076
|
+
precision: match[8] && match[8].slice(1),
|
|
2077
|
+
trim: match[9],
|
|
2078
|
+
type: match[10]
|
|
2079
|
+
});
|
|
2080
|
+
}
|
|
2081
|
+
formatSpecifier.prototype = FormatSpecifier.prototype;
|
|
2082
|
+
function FormatSpecifier(specifier) {
|
|
2083
|
+
this.fill = specifier.fill === void 0 ? " " : specifier.fill + "", this.align = specifier.align === void 0 ? ">" : specifier.align + "", this.sign = specifier.sign === void 0 ? "-" : specifier.sign + "", this.symbol = specifier.symbol === void 0 ? "" : specifier.symbol + "", this.zero = !!specifier.zero, this.width = specifier.width === void 0 ? void 0 : +specifier.width, this.comma = !!specifier.comma, this.precision = specifier.precision === void 0 ? void 0 : +specifier.precision, this.trim = !!specifier.trim, this.type = specifier.type === void 0 ? "" : specifier.type + "";
|
|
2084
|
+
}
|
|
2085
|
+
FormatSpecifier.prototype.toString = function() {
|
|
2086
|
+
return this.fill + this.align + this.sign + this.symbol + (this.zero ? "0" : "") + (this.width === void 0 ? "" : Math.max(1, this.width | 0)) + (this.comma ? "," : "") + (this.precision === void 0 ? "" : "." + Math.max(0, this.precision | 0)) + (this.trim ? "~" : "") + this.type;
|
|
2087
|
+
};
|
|
2088
|
+
function formatTrim(s) {
|
|
2089
|
+
out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i)
|
|
2090
|
+
switch (s[i]) {
|
|
2091
|
+
case ".":
|
|
2092
|
+
i0 = i1 = i;
|
|
2093
|
+
break;
|
|
2094
|
+
case "0":
|
|
2095
|
+
i0 === 0 && (i0 = i), i1 = i;
|
|
2096
|
+
break;
|
|
2097
|
+
default:
|
|
2098
|
+
if (!+s[i]) break out;
|
|
2099
|
+
i0 > 0 && (i0 = 0);
|
|
2100
|
+
break;
|
|
2101
|
+
}
|
|
2102
|
+
return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s;
|
|
2103
|
+
}
|
|
2104
|
+
var prefixExponent;
|
|
2105
|
+
function formatPrefixAuto(x, p) {
|
|
2106
|
+
var d = formatDecimalParts(x, p);
|
|
2107
|
+
if (!d) return x + "";
|
|
2108
|
+
var coefficient = d[0], exponent2 = d[1], i = exponent2 - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent2 / 3))) * 3) + 1, n = coefficient.length;
|
|
2109
|
+
return i === n ? coefficient : i > n ? coefficient + new Array(i - n + 1).join("0") : i > 0 ? coefficient.slice(0, i) + "." + coefficient.slice(i) : "0." + new Array(1 - i).join("0") + formatDecimalParts(x, Math.max(0, p + i - 1))[0];
|
|
2110
|
+
}
|
|
2111
|
+
function formatRounded(x, p) {
|
|
2112
|
+
var d = formatDecimalParts(x, p);
|
|
2113
|
+
if (!d) return x + "";
|
|
2114
|
+
var coefficient = d[0], exponent2 = d[1];
|
|
2115
|
+
return exponent2 < 0 ? "0." + new Array(-exponent2).join("0") + coefficient : coefficient.length > exponent2 + 1 ? coefficient.slice(0, exponent2 + 1) + "." + coefficient.slice(exponent2 + 1) : coefficient + new Array(exponent2 - coefficient.length + 2).join("0");
|
|
2116
|
+
}
|
|
2117
|
+
const formatTypes = {
|
|
2118
|
+
"%": function(x, p) {
|
|
2119
|
+
return (x * 100).toFixed(p);
|
|
2120
|
+
},
|
|
2121
|
+
b: function(x) {
|
|
2122
|
+
return Math.round(x).toString(2);
|
|
2123
|
+
},
|
|
2124
|
+
c: function(x) {
|
|
2125
|
+
return x + "";
|
|
2126
|
+
},
|
|
2127
|
+
d: formatDecimal,
|
|
2128
|
+
e: function(x, p) {
|
|
2129
|
+
return x.toExponential(p);
|
|
2130
|
+
},
|
|
2131
|
+
f: function(x, p) {
|
|
2132
|
+
return x.toFixed(p);
|
|
2133
|
+
},
|
|
2134
|
+
g: function(x, p) {
|
|
2135
|
+
return x.toPrecision(p);
|
|
2136
|
+
},
|
|
2137
|
+
o: function(x) {
|
|
2138
|
+
return Math.round(x).toString(8);
|
|
2139
|
+
},
|
|
2140
|
+
p: function(x, p) {
|
|
2141
|
+
return formatRounded(x * 100, p);
|
|
2142
|
+
},
|
|
2143
|
+
r: formatRounded,
|
|
2144
|
+
s: formatPrefixAuto,
|
|
2145
|
+
X: function(x) {
|
|
2146
|
+
return Math.round(x).toString(16).toUpperCase();
|
|
2147
|
+
},
|
|
2148
|
+
x: function(x) {
|
|
2149
|
+
return Math.round(x).toString(16);
|
|
2150
|
+
}
|
|
2151
|
+
};
|
|
2152
|
+
function identity(x) {
|
|
2153
|
+
return x;
|
|
2154
|
+
}
|
|
2155
|
+
var map = Array.prototype.map, prefixes = ["y", "z", "a", "f", "p", "n", "µ", "m", "", "k", "M", "G", "T", "P", "E", "Z", "Y"];
|
|
2156
|
+
function formatLocale$1(locale2) {
|
|
2157
|
+
var group = locale2.grouping === void 0 || locale2.thousands === void 0 ? identity : formatGroup(map.call(locale2.grouping, Number), locale2.thousands + ""), currencyPrefix = locale2.currency === void 0 ? "" : locale2.currency[0] + "", currencySuffix = locale2.currency === void 0 ? "" : locale2.currency[1] + "", decimal = locale2.decimal + "", numerals = locale2.numerals === void 0 ? identity : formatNumerals(map.call(locale2.numerals, String)), percent = locale2.percent === void 0 ? "%" : locale2.percent + "", minus = locale2.minus + "", nan = locale2.nan === void 0 ? "NaN" : locale2.nan + "";
|
|
2158
|
+
function newFormat(specifier) {
|
|
2159
|
+
specifier = formatSpecifier(specifier);
|
|
2160
|
+
var fill = specifier.fill, align = specifier.align, sign = specifier.sign, symbol = specifier.symbol, zero = specifier.zero, width = specifier.width, comma = specifier.comma, precision = specifier.precision, trim = specifier.trim, type = specifier.type;
|
|
2161
|
+
type === "n" ? (comma = !0, type = "g") : formatTypes[type] || (precision === void 0 && (precision = 12), trim = !0, type = "g"), (zero || fill === "0" && align === "=") && (zero = !0, fill = "0", align = "=");
|
|
2162
|
+
var prefix = symbol === "$" ? currencyPrefix : symbol === "#" && /[boxX]/.test(type) ? "0" + type.toLowerCase() : "", suffix = symbol === "$" ? currencySuffix : /[%p]/.test(type) ? percent : "", formatType = formatTypes[type], maybeSuffix = /[defgprs%]/.test(type);
|
|
2163
|
+
precision = precision === void 0 ? 6 : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision)) : Math.max(0, Math.min(20, precision));
|
|
2164
|
+
function format2(value) {
|
|
2165
|
+
var valuePrefix = prefix, valueSuffix = suffix, i, n, c;
|
|
2166
|
+
if (type === "c")
|
|
2167
|
+
valueSuffix = formatType(value) + valueSuffix, value = "";
|
|
2168
|
+
else {
|
|
2169
|
+
value = +value;
|
|
2170
|
+
var valueNegative = value < 0 || 1 / value < 0;
|
|
2171
|
+
if (value = isNaN(value) ? nan : formatType(Math.abs(value), precision), trim && (value = formatTrim(value)), valueNegative && +value == 0 && sign !== "+" && (valueNegative = !1), valuePrefix = (valueNegative ? sign === "(" ? sign : minus : sign === "-" || sign === "(" ? "" : sign) + valuePrefix, valueSuffix = (type === "s" ? prefixes[8 + prefixExponent / 3] : "") + valueSuffix + (valueNegative && sign === "(" ? ")" : ""), maybeSuffix) {
|
|
2172
|
+
for (i = -1, n = value.length; ++i < n; )
|
|
2173
|
+
if (c = value.charCodeAt(i), 48 > c || c > 57) {
|
|
2174
|
+
valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix, value = value.slice(0, i);
|
|
2175
|
+
break;
|
|
2176
|
+
}
|
|
2177
|
+
}
|
|
2178
|
+
}
|
|
2179
|
+
comma && !zero && (value = group(value, 1 / 0));
|
|
2180
|
+
var length = valuePrefix.length + value.length + valueSuffix.length, padding = length < width ? new Array(width - length + 1).join(fill) : "";
|
|
2181
|
+
switch (comma && zero && (value = group(padding + value, padding.length ? width - valueSuffix.length : 1 / 0), padding = ""), align) {
|
|
2182
|
+
case "<":
|
|
2183
|
+
value = valuePrefix + value + valueSuffix + padding;
|
|
2184
|
+
break;
|
|
2185
|
+
case "=":
|
|
2186
|
+
value = valuePrefix + padding + value + valueSuffix;
|
|
2187
|
+
break;
|
|
2188
|
+
case "^":
|
|
2189
|
+
value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length);
|
|
2190
|
+
break;
|
|
2191
|
+
default:
|
|
2192
|
+
value = padding + valuePrefix + value + valueSuffix;
|
|
2193
|
+
break;
|
|
2194
|
+
}
|
|
2195
|
+
return numerals(value);
|
|
2196
|
+
}
|
|
2197
|
+
return format2.toString = function() {
|
|
2198
|
+
return specifier + "";
|
|
2199
|
+
}, format2;
|
|
2200
|
+
}
|
|
2201
|
+
function formatPrefix(specifier, value) {
|
|
2202
|
+
var f = newFormat((specifier = formatSpecifier(specifier), specifier.type = "f", specifier)), e = Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3, k = Math.pow(10, -e), prefix = prefixes[8 + e / 3];
|
|
2203
|
+
return function(value2) {
|
|
2204
|
+
return f(k * value2) + prefix;
|
|
2205
|
+
};
|
|
2206
|
+
}
|
|
2207
|
+
return {
|
|
2208
|
+
format: newFormat,
|
|
2209
|
+
formatPrefix
|
|
2210
|
+
};
|
|
2211
|
+
}
|
|
2212
|
+
var locale$1, format;
|
|
2213
|
+
defaultLocale$1({
|
|
2214
|
+
decimal: ".",
|
|
2215
|
+
thousands: ",",
|
|
2216
|
+
grouping: [3],
|
|
2217
|
+
currency: ["$", ""],
|
|
2218
|
+
minus: "-"
|
|
2219
|
+
});
|
|
2220
|
+
function defaultLocale$1(definition) {
|
|
2221
|
+
return locale$1 = formatLocale$1(definition), format = locale$1.format, locale$1.formatPrefix, locale$1;
|
|
2222
|
+
}
|
|
2223
|
+
var t0 = /* @__PURE__ */ new Date(), t1 = /* @__PURE__ */ new Date();
|
|
2224
|
+
function newInterval(floori, offseti, count, field) {
|
|
2225
|
+
function interval(date) {
|
|
2226
|
+
return floori(date = arguments.length === 0 ? /* @__PURE__ */ new Date() : /* @__PURE__ */ new Date(+date)), date;
|
|
2227
|
+
}
|
|
2228
|
+
return interval.floor = function(date) {
|
|
2229
|
+
return floori(date = /* @__PURE__ */ new Date(+date)), date;
|
|
2230
|
+
}, interval.ceil = function(date) {
|
|
2231
|
+
return floori(date = new Date(date - 1)), offseti(date, 1), floori(date), date;
|
|
2232
|
+
}, interval.round = function(date) {
|
|
2233
|
+
var d0 = interval(date), d1 = interval.ceil(date);
|
|
2234
|
+
return date - d0 < d1 - date ? d0 : d1;
|
|
2235
|
+
}, interval.offset = function(date, step) {
|
|
2236
|
+
return offseti(date = /* @__PURE__ */ new Date(+date), step == null ? 1 : Math.floor(step)), date;
|
|
2237
|
+
}, interval.range = function(start, stop, step) {
|
|
2238
|
+
var range = [], previous;
|
|
2239
|
+
if (start = interval.ceil(start), step = step == null ? 1 : Math.floor(step), !(start < stop) || !(step > 0)) return range;
|
|
2240
|
+
do
|
|
2241
|
+
range.push(previous = /* @__PURE__ */ new Date(+start)), offseti(start, step), floori(start);
|
|
2242
|
+
while (previous < start && start < stop);
|
|
2243
|
+
return range;
|
|
2244
|
+
}, interval.filter = function(test) {
|
|
2245
|
+
return newInterval(function(date) {
|
|
2246
|
+
if (date >= date) for (; floori(date), !test(date); ) date.setTime(date - 1);
|
|
2247
|
+
}, function(date, step) {
|
|
2248
|
+
if (date >= date)
|
|
2249
|
+
if (step < 0) for (; ++step <= 0; )
|
|
2250
|
+
for (; offseti(date, -1), !test(date); )
|
|
2251
|
+
;
|
|
2252
|
+
else for (; --step >= 0; )
|
|
2253
|
+
for (; offseti(date, 1), !test(date); )
|
|
2254
|
+
;
|
|
2255
|
+
});
|
|
2256
|
+
}, count && (interval.count = function(start, end) {
|
|
2257
|
+
return t0.setTime(+start), t1.setTime(+end), floori(t0), floori(t1), Math.floor(count(t0, t1));
|
|
2258
|
+
}, interval.every = function(step) {
|
|
2259
|
+
return step = Math.floor(step), !isFinite(step) || !(step > 0) ? null : step > 1 ? interval.filter(field ? function(d) {
|
|
2260
|
+
return field(d) % step === 0;
|
|
2261
|
+
} : function(d) {
|
|
2262
|
+
return interval.count(0, d) % step === 0;
|
|
2263
|
+
}) : interval;
|
|
2264
|
+
}), interval;
|
|
2265
|
+
}
|
|
2266
|
+
var durationMinute = 6e4, durationDay = 864e5, durationWeek = 6048e5, day = newInterval(function(date) {
|
|
2267
|
+
date.setHours(0, 0, 0, 0);
|
|
2268
|
+
}, function(date, step) {
|
|
2269
|
+
date.setDate(date.getDate() + step);
|
|
2270
|
+
}, function(start, end) {
|
|
2271
|
+
return (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * durationMinute) / durationDay;
|
|
2272
|
+
}, function(date) {
|
|
2273
|
+
return date.getDate() - 1;
|
|
2274
|
+
});
|
|
2275
|
+
day.range;
|
|
2276
|
+
function weekday(i) {
|
|
2277
|
+
return newInterval(function(date) {
|
|
2278
|
+
date.setDate(date.getDate() - (date.getDay() + 7 - i) % 7), date.setHours(0, 0, 0, 0);
|
|
2279
|
+
}, function(date, step) {
|
|
2280
|
+
date.setDate(date.getDate() + step * 7);
|
|
2281
|
+
}, function(start, end) {
|
|
2282
|
+
return (end - start - (end.getTimezoneOffset() - start.getTimezoneOffset()) * durationMinute) / durationWeek;
|
|
2283
|
+
});
|
|
2284
|
+
}
|
|
2285
|
+
var sunday = weekday(0), monday = weekday(1), tuesday = weekday(2), wednesday = weekday(3), thursday = weekday(4), friday = weekday(5), saturday = weekday(6);
|
|
2286
|
+
sunday.range;
|
|
2287
|
+
monday.range;
|
|
2288
|
+
tuesday.range;
|
|
2289
|
+
wednesday.range;
|
|
2290
|
+
thursday.range;
|
|
2291
|
+
friday.range;
|
|
2292
|
+
saturday.range;
|
|
2293
|
+
var year = newInterval(function(date) {
|
|
2294
|
+
date.setMonth(0, 1), date.setHours(0, 0, 0, 0);
|
|
2295
|
+
}, function(date, step) {
|
|
2296
|
+
date.setFullYear(date.getFullYear() + step);
|
|
2297
|
+
}, function(start, end) {
|
|
2298
|
+
return end.getFullYear() - start.getFullYear();
|
|
2299
|
+
}, function(date) {
|
|
2300
|
+
return date.getFullYear();
|
|
2301
|
+
});
|
|
2302
|
+
year.every = function(k) {
|
|
2303
|
+
return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : newInterval(function(date) {
|
|
2304
|
+
date.setFullYear(Math.floor(date.getFullYear() / k) * k), date.setMonth(0, 1), date.setHours(0, 0, 0, 0);
|
|
2305
|
+
}, function(date, step) {
|
|
2306
|
+
date.setFullYear(date.getFullYear() + step * k);
|
|
2307
|
+
});
|
|
2308
|
+
};
|
|
2309
|
+
year.range;
|
|
2310
|
+
var utcDay = newInterval(function(date) {
|
|
2311
|
+
date.setUTCHours(0, 0, 0, 0);
|
|
2312
|
+
}, function(date, step) {
|
|
2313
|
+
date.setUTCDate(date.getUTCDate() + step);
|
|
2314
|
+
}, function(start, end) {
|
|
2315
|
+
return (end - start) / durationDay;
|
|
2316
|
+
}, function(date) {
|
|
2317
|
+
return date.getUTCDate() - 1;
|
|
2318
|
+
});
|
|
2319
|
+
utcDay.range;
|
|
2320
|
+
function utcWeekday(i) {
|
|
2321
|
+
return newInterval(function(date) {
|
|
2322
|
+
date.setUTCDate(date.getUTCDate() - (date.getUTCDay() + 7 - i) % 7), date.setUTCHours(0, 0, 0, 0);
|
|
2323
|
+
}, function(date, step) {
|
|
2324
|
+
date.setUTCDate(date.getUTCDate() + step * 7);
|
|
2325
|
+
}, function(start, end) {
|
|
2326
|
+
return (end - start) / durationWeek;
|
|
2327
|
+
});
|
|
2328
|
+
}
|
|
2329
|
+
var utcSunday = utcWeekday(0), utcMonday = utcWeekday(1), utcTuesday = utcWeekday(2), utcWednesday = utcWeekday(3), utcThursday = utcWeekday(4), utcFriday = utcWeekday(5), utcSaturday = utcWeekday(6);
|
|
2330
|
+
utcSunday.range;
|
|
2331
|
+
utcMonday.range;
|
|
2332
|
+
utcTuesday.range;
|
|
2333
|
+
utcWednesday.range;
|
|
2334
|
+
utcThursday.range;
|
|
2335
|
+
utcFriday.range;
|
|
2336
|
+
utcSaturday.range;
|
|
2337
|
+
var utcYear = newInterval(function(date) {
|
|
2338
|
+
date.setUTCMonth(0, 1), date.setUTCHours(0, 0, 0, 0);
|
|
2339
|
+
}, function(date, step) {
|
|
2340
|
+
date.setUTCFullYear(date.getUTCFullYear() + step);
|
|
2341
|
+
}, function(start, end) {
|
|
2342
|
+
return end.getUTCFullYear() - start.getUTCFullYear();
|
|
2343
|
+
}, function(date) {
|
|
2344
|
+
return date.getUTCFullYear();
|
|
2345
|
+
});
|
|
2346
|
+
utcYear.every = function(k) {
|
|
2347
|
+
return !isFinite(k = Math.floor(k)) || !(k > 0) ? null : newInterval(function(date) {
|
|
2348
|
+
date.setUTCFullYear(Math.floor(date.getUTCFullYear() / k) * k), date.setUTCMonth(0, 1), date.setUTCHours(0, 0, 0, 0);
|
|
2349
|
+
}, function(date, step) {
|
|
2350
|
+
date.setUTCFullYear(date.getUTCFullYear() + step * k);
|
|
2351
|
+
});
|
|
2352
|
+
};
|
|
2353
|
+
utcYear.range;
|
|
2354
|
+
function localDate(d) {
|
|
2355
|
+
if (0 <= d.y && d.y < 100) {
|
|
2356
|
+
var date = new Date(-1, d.m, d.d, d.H, d.M, d.S, d.L);
|
|
2357
|
+
return date.setFullYear(d.y), date;
|
|
2358
|
+
}
|
|
2359
|
+
return new Date(d.y, d.m, d.d, d.H, d.M, d.S, d.L);
|
|
2360
|
+
}
|
|
2361
|
+
function utcDate(d) {
|
|
2362
|
+
if (0 <= d.y && d.y < 100) {
|
|
2363
|
+
var date = new Date(Date.UTC(-1, d.m, d.d, d.H, d.M, d.S, d.L));
|
|
2364
|
+
return date.setUTCFullYear(d.y), date;
|
|
2365
|
+
}
|
|
2366
|
+
return new Date(Date.UTC(d.y, d.m, d.d, d.H, d.M, d.S, d.L));
|
|
2367
|
+
}
|
|
2368
|
+
function newDate(y, m, d) {
|
|
2369
|
+
return { y, m, d, H: 0, M: 0, S: 0, L: 0 };
|
|
2370
|
+
}
|
|
2371
|
+
function formatLocale(locale2) {
|
|
2372
|
+
var locale_dateTime = locale2.dateTime, locale_date = locale2.date, locale_time = locale2.time, locale_periods = locale2.periods, locale_weekdays = locale2.days, locale_shortWeekdays = locale2.shortDays, locale_months = locale2.months, locale_shortMonths = locale2.shortMonths, periodRe = formatRe(locale_periods), periodLookup = formatLookup(locale_periods), weekdayRe = formatRe(locale_weekdays), weekdayLookup = formatLookup(locale_weekdays), shortWeekdayRe = formatRe(locale_shortWeekdays), shortWeekdayLookup = formatLookup(locale_shortWeekdays), monthRe = formatRe(locale_months), monthLookup = formatLookup(locale_months), shortMonthRe = formatRe(locale_shortMonths), shortMonthLookup = formatLookup(locale_shortMonths), formats = {
|
|
2373
|
+
a: formatShortWeekday,
|
|
2374
|
+
A: formatWeekday,
|
|
2375
|
+
b: formatShortMonth,
|
|
2376
|
+
B: formatMonth,
|
|
2377
|
+
c: null,
|
|
2378
|
+
d: formatDayOfMonth,
|
|
2379
|
+
e: formatDayOfMonth,
|
|
2380
|
+
f: formatMicroseconds,
|
|
2381
|
+
g: formatYearISO,
|
|
2382
|
+
G: formatFullYearISO,
|
|
2383
|
+
H: formatHour24,
|
|
2384
|
+
I: formatHour12,
|
|
2385
|
+
j: formatDayOfYear,
|
|
2386
|
+
L: formatMilliseconds,
|
|
2387
|
+
m: formatMonthNumber,
|
|
2388
|
+
M: formatMinutes,
|
|
2389
|
+
p: formatPeriod,
|
|
2390
|
+
q: formatQuarter,
|
|
2391
|
+
Q: formatUnixTimestamp,
|
|
2392
|
+
s: formatUnixTimestampSeconds,
|
|
2393
|
+
S: formatSeconds,
|
|
2394
|
+
u: formatWeekdayNumberMonday,
|
|
2395
|
+
U: formatWeekNumberSunday,
|
|
2396
|
+
V: formatWeekNumberISO,
|
|
2397
|
+
w: formatWeekdayNumberSunday,
|
|
2398
|
+
W: formatWeekNumberMonday,
|
|
2399
|
+
x: null,
|
|
2400
|
+
X: null,
|
|
2401
|
+
y: formatYear,
|
|
2402
|
+
Y: formatFullYear,
|
|
2403
|
+
Z: formatZone,
|
|
2404
|
+
"%": formatLiteralPercent
|
|
2405
|
+
}, utcFormats = {
|
|
2406
|
+
a: formatUTCShortWeekday,
|
|
2407
|
+
A: formatUTCWeekday,
|
|
2408
|
+
b: formatUTCShortMonth,
|
|
2409
|
+
B: formatUTCMonth,
|
|
2410
|
+
c: null,
|
|
2411
|
+
d: formatUTCDayOfMonth,
|
|
2412
|
+
e: formatUTCDayOfMonth,
|
|
2413
|
+
f: formatUTCMicroseconds,
|
|
2414
|
+
g: formatUTCYearISO,
|
|
2415
|
+
G: formatUTCFullYearISO,
|
|
2416
|
+
H: formatUTCHour24,
|
|
2417
|
+
I: formatUTCHour12,
|
|
2418
|
+
j: formatUTCDayOfYear,
|
|
2419
|
+
L: formatUTCMilliseconds,
|
|
2420
|
+
m: formatUTCMonthNumber,
|
|
2421
|
+
M: formatUTCMinutes,
|
|
2422
|
+
p: formatUTCPeriod,
|
|
2423
|
+
q: formatUTCQuarter,
|
|
2424
|
+
Q: formatUnixTimestamp,
|
|
2425
|
+
s: formatUnixTimestampSeconds,
|
|
2426
|
+
S: formatUTCSeconds,
|
|
2427
|
+
u: formatUTCWeekdayNumberMonday,
|
|
2428
|
+
U: formatUTCWeekNumberSunday,
|
|
2429
|
+
V: formatUTCWeekNumberISO,
|
|
2430
|
+
w: formatUTCWeekdayNumberSunday,
|
|
2431
|
+
W: formatUTCWeekNumberMonday,
|
|
2432
|
+
x: null,
|
|
2433
|
+
X: null,
|
|
2434
|
+
y: formatUTCYear,
|
|
2435
|
+
Y: formatUTCFullYear,
|
|
2436
|
+
Z: formatUTCZone,
|
|
2437
|
+
"%": formatLiteralPercent
|
|
2438
|
+
}, parses = {
|
|
2439
|
+
a: parseShortWeekday,
|
|
2440
|
+
A: parseWeekday,
|
|
2441
|
+
b: parseShortMonth,
|
|
2442
|
+
B: parseMonth,
|
|
2443
|
+
c: parseLocaleDateTime,
|
|
2444
|
+
d: parseDayOfMonth,
|
|
2445
|
+
e: parseDayOfMonth,
|
|
2446
|
+
f: parseMicroseconds,
|
|
2447
|
+
g: parseYear,
|
|
2448
|
+
G: parseFullYear,
|
|
2449
|
+
H: parseHour24,
|
|
2450
|
+
I: parseHour24,
|
|
2451
|
+
j: parseDayOfYear,
|
|
2452
|
+
L: parseMilliseconds,
|
|
2453
|
+
m: parseMonthNumber,
|
|
2454
|
+
M: parseMinutes,
|
|
2455
|
+
p: parsePeriod,
|
|
2456
|
+
q: parseQuarter,
|
|
2457
|
+
Q: parseUnixTimestamp,
|
|
2458
|
+
s: parseUnixTimestampSeconds,
|
|
2459
|
+
S: parseSeconds,
|
|
2460
|
+
u: parseWeekdayNumberMonday,
|
|
2461
|
+
U: parseWeekNumberSunday,
|
|
2462
|
+
V: parseWeekNumberISO,
|
|
2463
|
+
w: parseWeekdayNumberSunday,
|
|
2464
|
+
W: parseWeekNumberMonday,
|
|
2465
|
+
x: parseLocaleDate,
|
|
2466
|
+
X: parseLocaleTime,
|
|
2467
|
+
y: parseYear,
|
|
2468
|
+
Y: parseFullYear,
|
|
2469
|
+
Z: parseZone,
|
|
2470
|
+
"%": parseLiteralPercent
|
|
2471
|
+
};
|
|
2472
|
+
formats.x = newFormat(locale_date, formats), formats.X = newFormat(locale_time, formats), formats.c = newFormat(locale_dateTime, formats), utcFormats.x = newFormat(locale_date, utcFormats), utcFormats.X = newFormat(locale_time, utcFormats), utcFormats.c = newFormat(locale_dateTime, utcFormats);
|
|
2473
|
+
function newFormat(specifier, formats2) {
|
|
2474
|
+
return function(date) {
|
|
2475
|
+
var string = [], i = -1, j = 0, n = specifier.length, c, pad2, format2;
|
|
2476
|
+
for (date instanceof Date || (date = /* @__PURE__ */ new Date(+date)); ++i < n; )
|
|
2477
|
+
specifier.charCodeAt(i) === 37 && (string.push(specifier.slice(j, i)), (pad2 = pads[c = specifier.charAt(++i)]) != null ? c = specifier.charAt(++i) : pad2 = c === "e" ? " " : "0", (format2 = formats2[c]) && (c = format2(date, pad2)), string.push(c), j = i + 1);
|
|
2478
|
+
return string.push(specifier.slice(j, i)), string.join("");
|
|
2479
|
+
};
|
|
2480
|
+
}
|
|
2481
|
+
function newParse(specifier, Z) {
|
|
2482
|
+
return function(string) {
|
|
2483
|
+
var d = newDate(1900, void 0, 1), i = parseSpecifier(d, specifier, string += "", 0), week, day$1;
|
|
2484
|
+
if (i != string.length) return null;
|
|
2485
|
+
if ("Q" in d) return new Date(d.Q);
|
|
2486
|
+
if ("s" in d) return new Date(d.s * 1e3 + ("L" in d ? d.L : 0));
|
|
2487
|
+
if (Z && !("Z" in d) && (d.Z = 0), "p" in d && (d.H = d.H % 12 + d.p * 12), d.m === void 0 && (d.m = "q" in d ? d.q : 0), "V" in d) {
|
|
2488
|
+
if (d.V < 1 || d.V > 53) return null;
|
|
2489
|
+
"w" in d || (d.w = 1), "Z" in d ? (week = utcDate(newDate(d.y, 0, 1)), day$1 = week.getUTCDay(), week = day$1 > 4 || day$1 === 0 ? utcMonday.ceil(week) : utcMonday(week), week = utcDay.offset(week, (d.V - 1) * 7), d.y = week.getUTCFullYear(), d.m = week.getUTCMonth(), d.d = week.getUTCDate() + (d.w + 6) % 7) : (week = localDate(newDate(d.y, 0, 1)), day$1 = week.getDay(), week = day$1 > 4 || day$1 === 0 ? monday.ceil(week) : monday(week), week = day.offset(week, (d.V - 1) * 7), d.y = week.getFullYear(), d.m = week.getMonth(), d.d = week.getDate() + (d.w + 6) % 7);
|
|
2490
|
+
} else ("W" in d || "U" in d) && ("w" in d || (d.w = "u" in d ? d.u % 7 : "W" in d ? 1 : 0), day$1 = "Z" in d ? utcDate(newDate(d.y, 0, 1)).getUTCDay() : localDate(newDate(d.y, 0, 1)).getDay(), d.m = 0, d.d = "W" in d ? (d.w + 6) % 7 + d.W * 7 - (day$1 + 5) % 7 : d.w + d.U * 7 - (day$1 + 6) % 7);
|
|
2491
|
+
return "Z" in d ? (d.H += d.Z / 100 | 0, d.M += d.Z % 100, utcDate(d)) : localDate(d);
|
|
2492
|
+
};
|
|
2493
|
+
}
|
|
2494
|
+
function parseSpecifier(d, specifier, string, j) {
|
|
2495
|
+
for (var i = 0, n = specifier.length, m = string.length, c, parse; i < n; ) {
|
|
2496
|
+
if (j >= m) return -1;
|
|
2497
|
+
if (c = specifier.charCodeAt(i++), c === 37) {
|
|
2498
|
+
if (c = specifier.charAt(i++), parse = parses[c in pads ? specifier.charAt(i++) : c], !parse || (j = parse(d, string, j)) < 0) return -1;
|
|
2499
|
+
} else if (c != string.charCodeAt(j++))
|
|
2500
|
+
return -1;
|
|
2501
|
+
}
|
|
2502
|
+
return j;
|
|
2503
|
+
}
|
|
2504
|
+
function parsePeriod(d, string, i) {
|
|
2505
|
+
var n = periodRe.exec(string.slice(i));
|
|
2506
|
+
return n ? (d.p = periodLookup[n[0].toLowerCase()], i + n[0].length) : -1;
|
|
2507
|
+
}
|
|
2508
|
+
function parseShortWeekday(d, string, i) {
|
|
2509
|
+
var n = shortWeekdayRe.exec(string.slice(i));
|
|
2510
|
+
return n ? (d.w = shortWeekdayLookup[n[0].toLowerCase()], i + n[0].length) : -1;
|
|
2511
|
+
}
|
|
2512
|
+
function parseWeekday(d, string, i) {
|
|
2513
|
+
var n = weekdayRe.exec(string.slice(i));
|
|
2514
|
+
return n ? (d.w = weekdayLookup[n[0].toLowerCase()], i + n[0].length) : -1;
|
|
2515
|
+
}
|
|
2516
|
+
function parseShortMonth(d, string, i) {
|
|
2517
|
+
var n = shortMonthRe.exec(string.slice(i));
|
|
2518
|
+
return n ? (d.m = shortMonthLookup[n[0].toLowerCase()], i + n[0].length) : -1;
|
|
2519
|
+
}
|
|
2520
|
+
function parseMonth(d, string, i) {
|
|
2521
|
+
var n = monthRe.exec(string.slice(i));
|
|
2522
|
+
return n ? (d.m = monthLookup[n[0].toLowerCase()], i + n[0].length) : -1;
|
|
2523
|
+
}
|
|
2524
|
+
function parseLocaleDateTime(d, string, i) {
|
|
2525
|
+
return parseSpecifier(d, locale_dateTime, string, i);
|
|
2526
|
+
}
|
|
2527
|
+
function parseLocaleDate(d, string, i) {
|
|
2528
|
+
return parseSpecifier(d, locale_date, string, i);
|
|
2529
|
+
}
|
|
2530
|
+
function parseLocaleTime(d, string, i) {
|
|
2531
|
+
return parseSpecifier(d, locale_time, string, i);
|
|
2532
|
+
}
|
|
2533
|
+
function formatShortWeekday(d) {
|
|
2534
|
+
return locale_shortWeekdays[d.getDay()];
|
|
2535
|
+
}
|
|
2536
|
+
function formatWeekday(d) {
|
|
2537
|
+
return locale_weekdays[d.getDay()];
|
|
2538
|
+
}
|
|
2539
|
+
function formatShortMonth(d) {
|
|
2540
|
+
return locale_shortMonths[d.getMonth()];
|
|
2541
|
+
}
|
|
2542
|
+
function formatMonth(d) {
|
|
2543
|
+
return locale_months[d.getMonth()];
|
|
2544
|
+
}
|
|
2545
|
+
function formatPeriod(d) {
|
|
2546
|
+
return locale_periods[+(d.getHours() >= 12)];
|
|
2547
|
+
}
|
|
2548
|
+
function formatQuarter(d) {
|
|
2549
|
+
return 1 + ~~(d.getMonth() / 3);
|
|
2550
|
+
}
|
|
2551
|
+
function formatUTCShortWeekday(d) {
|
|
2552
|
+
return locale_shortWeekdays[d.getUTCDay()];
|
|
2553
|
+
}
|
|
2554
|
+
function formatUTCWeekday(d) {
|
|
2555
|
+
return locale_weekdays[d.getUTCDay()];
|
|
2556
|
+
}
|
|
2557
|
+
function formatUTCShortMonth(d) {
|
|
2558
|
+
return locale_shortMonths[d.getUTCMonth()];
|
|
2559
|
+
}
|
|
2560
|
+
function formatUTCMonth(d) {
|
|
2561
|
+
return locale_months[d.getUTCMonth()];
|
|
2562
|
+
}
|
|
2563
|
+
function formatUTCPeriod(d) {
|
|
2564
|
+
return locale_periods[+(d.getUTCHours() >= 12)];
|
|
2565
|
+
}
|
|
2566
|
+
function formatUTCQuarter(d) {
|
|
2567
|
+
return 1 + ~~(d.getUTCMonth() / 3);
|
|
2568
|
+
}
|
|
2569
|
+
return {
|
|
2570
|
+
format: function(specifier) {
|
|
2571
|
+
var f = newFormat(specifier += "", formats);
|
|
2572
|
+
return f.toString = function() {
|
|
2573
|
+
return specifier;
|
|
2574
|
+
}, f;
|
|
2575
|
+
},
|
|
2576
|
+
parse: function(specifier) {
|
|
2577
|
+
var p = newParse(specifier += "", !1);
|
|
2578
|
+
return p.toString = function() {
|
|
2579
|
+
return specifier;
|
|
2580
|
+
}, p;
|
|
2581
|
+
},
|
|
2582
|
+
utcFormat: function(specifier) {
|
|
2583
|
+
var f = newFormat(specifier += "", utcFormats);
|
|
2584
|
+
return f.toString = function() {
|
|
2585
|
+
return specifier;
|
|
2586
|
+
}, f;
|
|
2587
|
+
},
|
|
2588
|
+
utcParse: function(specifier) {
|
|
2589
|
+
var p = newParse(specifier += "", !0);
|
|
2590
|
+
return p.toString = function() {
|
|
2591
|
+
return specifier;
|
|
2592
|
+
}, p;
|
|
2593
|
+
}
|
|
2594
|
+
};
|
|
2595
|
+
}
|
|
2596
|
+
var pads = { "-": "", _: " ", 0: "0" }, numberRe = /^\s*\d+/, percentRe = /^%/, requoteRe = /[\\^$*+?|[\]().{}]/g;
|
|
2597
|
+
function pad(value, fill, width) {
|
|
2598
|
+
var sign = value < 0 ? "-" : "", string = (sign ? -value : value) + "", length = string.length;
|
|
2599
|
+
return sign + (length < width ? new Array(width - length + 1).join(fill) + string : string);
|
|
2600
|
+
}
|
|
2601
|
+
function requote(s) {
|
|
2602
|
+
return s.replace(requoteRe, "\\$&");
|
|
2603
|
+
}
|
|
2604
|
+
function formatRe(names) {
|
|
2605
|
+
return new RegExp("^(?:" + names.map(requote).join("|") + ")", "i");
|
|
2606
|
+
}
|
|
2607
|
+
function formatLookup(names) {
|
|
2608
|
+
for (var map2 = {}, i = -1, n = names.length; ++i < n; ) map2[names[i].toLowerCase()] = i;
|
|
2609
|
+
return map2;
|
|
2610
|
+
}
|
|
2611
|
+
function parseWeekdayNumberSunday(d, string, i) {
|
|
2612
|
+
var n = numberRe.exec(string.slice(i, i + 1));
|
|
2613
|
+
return n ? (d.w = +n[0], i + n[0].length) : -1;
|
|
2614
|
+
}
|
|
2615
|
+
function parseWeekdayNumberMonday(d, string, i) {
|
|
2616
|
+
var n = numberRe.exec(string.slice(i, i + 1));
|
|
2617
|
+
return n ? (d.u = +n[0], i + n[0].length) : -1;
|
|
2618
|
+
}
|
|
2619
|
+
function parseWeekNumberSunday(d, string, i) {
|
|
2620
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2621
|
+
return n ? (d.U = +n[0], i + n[0].length) : -1;
|
|
2622
|
+
}
|
|
2623
|
+
function parseWeekNumberISO(d, string, i) {
|
|
2624
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2625
|
+
return n ? (d.V = +n[0], i + n[0].length) : -1;
|
|
2626
|
+
}
|
|
2627
|
+
function parseWeekNumberMonday(d, string, i) {
|
|
2628
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2629
|
+
return n ? (d.W = +n[0], i + n[0].length) : -1;
|
|
2630
|
+
}
|
|
2631
|
+
function parseFullYear(d, string, i) {
|
|
2632
|
+
var n = numberRe.exec(string.slice(i, i + 4));
|
|
2633
|
+
return n ? (d.y = +n[0], i + n[0].length) : -1;
|
|
2634
|
+
}
|
|
2635
|
+
function parseYear(d, string, i) {
|
|
2636
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2637
|
+
return n ? (d.y = +n[0] + (+n[0] > 68 ? 1900 : 2e3), i + n[0].length) : -1;
|
|
2638
|
+
}
|
|
2639
|
+
function parseZone(d, string, i) {
|
|
2640
|
+
var n = /^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(string.slice(i, i + 6));
|
|
2641
|
+
return n ? (d.Z = n[1] ? 0 : -(n[2] + (n[3] || "00")), i + n[0].length) : -1;
|
|
2642
|
+
}
|
|
2643
|
+
function parseQuarter(d, string, i) {
|
|
2644
|
+
var n = numberRe.exec(string.slice(i, i + 1));
|
|
2645
|
+
return n ? (d.q = n[0] * 3 - 3, i + n[0].length) : -1;
|
|
2646
|
+
}
|
|
2647
|
+
function parseMonthNumber(d, string, i) {
|
|
2648
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2649
|
+
return n ? (d.m = n[0] - 1, i + n[0].length) : -1;
|
|
2650
|
+
}
|
|
2651
|
+
function parseDayOfMonth(d, string, i) {
|
|
2652
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2653
|
+
return n ? (d.d = +n[0], i + n[0].length) : -1;
|
|
2654
|
+
}
|
|
2655
|
+
function parseDayOfYear(d, string, i) {
|
|
2656
|
+
var n = numberRe.exec(string.slice(i, i + 3));
|
|
2657
|
+
return n ? (d.m = 0, d.d = +n[0], i + n[0].length) : -1;
|
|
2658
|
+
}
|
|
2659
|
+
function parseHour24(d, string, i) {
|
|
2660
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2661
|
+
return n ? (d.H = +n[0], i + n[0].length) : -1;
|
|
2662
|
+
}
|
|
2663
|
+
function parseMinutes(d, string, i) {
|
|
2664
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2665
|
+
return n ? (d.M = +n[0], i + n[0].length) : -1;
|
|
2666
|
+
}
|
|
2667
|
+
function parseSeconds(d, string, i) {
|
|
2668
|
+
var n = numberRe.exec(string.slice(i, i + 2));
|
|
2669
|
+
return n ? (d.S = +n[0], i + n[0].length) : -1;
|
|
2670
|
+
}
|
|
2671
|
+
function parseMilliseconds(d, string, i) {
|
|
2672
|
+
var n = numberRe.exec(string.slice(i, i + 3));
|
|
2673
|
+
return n ? (d.L = +n[0], i + n[0].length) : -1;
|
|
2674
|
+
}
|
|
2675
|
+
function parseMicroseconds(d, string, i) {
|
|
2676
|
+
var n = numberRe.exec(string.slice(i, i + 6));
|
|
2677
|
+
return n ? (d.L = Math.floor(n[0] / 1e3), i + n[0].length) : -1;
|
|
2678
|
+
}
|
|
2679
|
+
function parseLiteralPercent(d, string, i) {
|
|
2680
|
+
var n = percentRe.exec(string.slice(i, i + 1));
|
|
2681
|
+
return n ? i + n[0].length : -1;
|
|
2682
|
+
}
|
|
2683
|
+
function parseUnixTimestamp(d, string, i) {
|
|
2684
|
+
var n = numberRe.exec(string.slice(i));
|
|
2685
|
+
return n ? (d.Q = +n[0], i + n[0].length) : -1;
|
|
2686
|
+
}
|
|
2687
|
+
function parseUnixTimestampSeconds(d, string, i) {
|
|
2688
|
+
var n = numberRe.exec(string.slice(i));
|
|
2689
|
+
return n ? (d.s = +n[0], i + n[0].length) : -1;
|
|
2690
|
+
}
|
|
2691
|
+
function formatDayOfMonth(d, p) {
|
|
2692
|
+
return pad(d.getDate(), p, 2);
|
|
2693
|
+
}
|
|
2694
|
+
function formatHour24(d, p) {
|
|
2695
|
+
return pad(d.getHours(), p, 2);
|
|
2696
|
+
}
|
|
2697
|
+
function formatHour12(d, p) {
|
|
2698
|
+
return pad(d.getHours() % 12 || 12, p, 2);
|
|
2699
|
+
}
|
|
2700
|
+
function formatDayOfYear(d, p) {
|
|
2701
|
+
return pad(1 + day.count(year(d), d), p, 3);
|
|
2702
|
+
}
|
|
2703
|
+
function formatMilliseconds(d, p) {
|
|
2704
|
+
return pad(d.getMilliseconds(), p, 3);
|
|
2705
|
+
}
|
|
2706
|
+
function formatMicroseconds(d, p) {
|
|
2707
|
+
return formatMilliseconds(d, p) + "000";
|
|
2708
|
+
}
|
|
2709
|
+
function formatMonthNumber(d, p) {
|
|
2710
|
+
return pad(d.getMonth() + 1, p, 2);
|
|
2711
|
+
}
|
|
2712
|
+
function formatMinutes(d, p) {
|
|
2713
|
+
return pad(d.getMinutes(), p, 2);
|
|
2714
|
+
}
|
|
2715
|
+
function formatSeconds(d, p) {
|
|
2716
|
+
return pad(d.getSeconds(), p, 2);
|
|
2717
|
+
}
|
|
2718
|
+
function formatWeekdayNumberMonday(d) {
|
|
2719
|
+
var day2 = d.getDay();
|
|
2720
|
+
return day2 === 0 ? 7 : day2;
|
|
2721
|
+
}
|
|
2722
|
+
function formatWeekNumberSunday(d, p) {
|
|
2723
|
+
return pad(sunday.count(year(d) - 1, d), p, 2);
|
|
2724
|
+
}
|
|
2725
|
+
function dISO(d) {
|
|
2726
|
+
var day2 = d.getDay();
|
|
2727
|
+
return day2 >= 4 || day2 === 0 ? thursday(d) : thursday.ceil(d);
|
|
2728
|
+
}
|
|
2729
|
+
function formatWeekNumberISO(d, p) {
|
|
2730
|
+
return d = dISO(d), pad(thursday.count(year(d), d) + (year(d).getDay() === 4), p, 2);
|
|
2731
|
+
}
|
|
2732
|
+
function formatWeekdayNumberSunday(d) {
|
|
2733
|
+
return d.getDay();
|
|
2734
|
+
}
|
|
2735
|
+
function formatWeekNumberMonday(d, p) {
|
|
2736
|
+
return pad(monday.count(year(d) - 1, d), p, 2);
|
|
2737
|
+
}
|
|
2738
|
+
function formatYear(d, p) {
|
|
2739
|
+
return pad(d.getFullYear() % 100, p, 2);
|
|
2740
|
+
}
|
|
2741
|
+
function formatYearISO(d, p) {
|
|
2742
|
+
return d = dISO(d), pad(d.getFullYear() % 100, p, 2);
|
|
2743
|
+
}
|
|
2744
|
+
function formatFullYear(d, p) {
|
|
2745
|
+
return pad(d.getFullYear() % 1e4, p, 4);
|
|
2746
|
+
}
|
|
2747
|
+
function formatFullYearISO(d, p) {
|
|
2748
|
+
var day2 = d.getDay();
|
|
2749
|
+
return d = day2 >= 4 || day2 === 0 ? thursday(d) : thursday.ceil(d), pad(d.getFullYear() % 1e4, p, 4);
|
|
2750
|
+
}
|
|
2751
|
+
function formatZone(d) {
|
|
2752
|
+
var z = d.getTimezoneOffset();
|
|
2753
|
+
return (z > 0 ? "-" : (z *= -1, "+")) + pad(z / 60 | 0, "0", 2) + pad(z % 60, "0", 2);
|
|
2754
|
+
}
|
|
2755
|
+
function formatUTCDayOfMonth(d, p) {
|
|
2756
|
+
return pad(d.getUTCDate(), p, 2);
|
|
2757
|
+
}
|
|
2758
|
+
function formatUTCHour24(d, p) {
|
|
2759
|
+
return pad(d.getUTCHours(), p, 2);
|
|
2760
|
+
}
|
|
2761
|
+
function formatUTCHour12(d, p) {
|
|
2762
|
+
return pad(d.getUTCHours() % 12 || 12, p, 2);
|
|
2763
|
+
}
|
|
2764
|
+
function formatUTCDayOfYear(d, p) {
|
|
2765
|
+
return pad(1 + utcDay.count(utcYear(d), d), p, 3);
|
|
2766
|
+
}
|
|
2767
|
+
function formatUTCMilliseconds(d, p) {
|
|
2768
|
+
return pad(d.getUTCMilliseconds(), p, 3);
|
|
2769
|
+
}
|
|
2770
|
+
function formatUTCMicroseconds(d, p) {
|
|
2771
|
+
return formatUTCMilliseconds(d, p) + "000";
|
|
2772
|
+
}
|
|
2773
|
+
function formatUTCMonthNumber(d, p) {
|
|
2774
|
+
return pad(d.getUTCMonth() + 1, p, 2);
|
|
2775
|
+
}
|
|
2776
|
+
function formatUTCMinutes(d, p) {
|
|
2777
|
+
return pad(d.getUTCMinutes(), p, 2);
|
|
2778
|
+
}
|
|
2779
|
+
function formatUTCSeconds(d, p) {
|
|
2780
|
+
return pad(d.getUTCSeconds(), p, 2);
|
|
2781
|
+
}
|
|
2782
|
+
function formatUTCWeekdayNumberMonday(d) {
|
|
2783
|
+
var dow = d.getUTCDay();
|
|
2784
|
+
return dow === 0 ? 7 : dow;
|
|
2785
|
+
}
|
|
2786
|
+
function formatUTCWeekNumberSunday(d, p) {
|
|
2787
|
+
return pad(utcSunday.count(utcYear(d) - 1, d), p, 2);
|
|
2788
|
+
}
|
|
2789
|
+
function UTCdISO(d) {
|
|
2790
|
+
var day2 = d.getUTCDay();
|
|
2791
|
+
return day2 >= 4 || day2 === 0 ? utcThursday(d) : utcThursday.ceil(d);
|
|
2792
|
+
}
|
|
2793
|
+
function formatUTCWeekNumberISO(d, p) {
|
|
2794
|
+
return d = UTCdISO(d), pad(utcThursday.count(utcYear(d), d) + (utcYear(d).getUTCDay() === 4), p, 2);
|
|
2795
|
+
}
|
|
2796
|
+
function formatUTCWeekdayNumberSunday(d) {
|
|
2797
|
+
return d.getUTCDay();
|
|
2798
|
+
}
|
|
2799
|
+
function formatUTCWeekNumberMonday(d, p) {
|
|
2800
|
+
return pad(utcMonday.count(utcYear(d) - 1, d), p, 2);
|
|
2801
|
+
}
|
|
2802
|
+
function formatUTCYear(d, p) {
|
|
2803
|
+
return pad(d.getUTCFullYear() % 100, p, 2);
|
|
2804
|
+
}
|
|
2805
|
+
function formatUTCYearISO(d, p) {
|
|
2806
|
+
return d = UTCdISO(d), pad(d.getUTCFullYear() % 100, p, 2);
|
|
2807
|
+
}
|
|
2808
|
+
function formatUTCFullYear(d, p) {
|
|
2809
|
+
return pad(d.getUTCFullYear() % 1e4, p, 4);
|
|
2810
|
+
}
|
|
2811
|
+
function formatUTCFullYearISO(d, p) {
|
|
2812
|
+
var day2 = d.getUTCDay();
|
|
2813
|
+
return d = day2 >= 4 || day2 === 0 ? utcThursday(d) : utcThursday.ceil(d), pad(d.getUTCFullYear() % 1e4, p, 4);
|
|
2814
|
+
}
|
|
2815
|
+
function formatUTCZone() {
|
|
2816
|
+
return "+0000";
|
|
2817
|
+
}
|
|
2818
|
+
function formatLiteralPercent() {
|
|
2819
|
+
return "%";
|
|
2820
|
+
}
|
|
2821
|
+
function formatUnixTimestamp(d) {
|
|
2822
|
+
return +d;
|
|
2823
|
+
}
|
|
2824
|
+
function formatUnixTimestampSeconds(d) {
|
|
2825
|
+
return Math.floor(+d / 1e3);
|
|
2826
|
+
}
|
|
2827
|
+
var locale, utcFormat, utcParse;
|
|
2828
|
+
defaultLocale({
|
|
2829
|
+
dateTime: "%x, %X",
|
|
2830
|
+
date: "%-m/%-d/%Y",
|
|
2831
|
+
time: "%-I:%M:%S %p",
|
|
2832
|
+
periods: ["AM", "PM"],
|
|
2833
|
+
days: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],
|
|
2834
|
+
shortDays: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
|
|
2835
|
+
months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
|
|
2836
|
+
shortMonths: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
|
|
2837
|
+
});
|
|
2838
|
+
function defaultLocale(definition) {
|
|
2839
|
+
return locale = formatLocale(definition), locale.format, locale.parse, utcFormat = locale.utcFormat, utcParse = locale.utcParse, locale;
|
|
2840
|
+
}
|
|
1976
2841
|
class ECLGraph extends StateObject {
|
|
1977
2842
|
constructor(wu, eclGraph, eclTimers) {
|
|
1978
2843
|
super();
|
|
@@ -2735,7 +3600,7 @@ function formatValues(item, key, dedup) {
|
|
|
2735
3600
|
const keyParts = splitMetric(key);
|
|
2736
3601
|
if (!dedup[keyParts.measure]) {
|
|
2737
3602
|
dedup[keyParts.label] = !0;
|
|
2738
|
-
const avg = safeParseFloat(item[`${keyParts.measure}Avg${keyParts.label}`]), min = safeParseFloat(item[`${keyParts.measure}Min${keyParts.label}`]),
|
|
3603
|
+
const avg = safeParseFloat(item[`${keyParts.measure}Avg${keyParts.label}`]), min = safeParseFloat(item[`${keyParts.measure}Min${keyParts.label}`]), max = safeParseFloat(item[`${keyParts.measure}Max${keyParts.label}`]), stdDev = safeParseFloat(item[`${keyParts.measure}StdDev${keyParts.label}`]), StdDevs = Math.max((avg - min) / stdDev, (max - avg) / stdDev);
|
|
2739
3604
|
return {
|
|
2740
3605
|
Key: `${keyParts.measure}${keyParts.label}`,
|
|
2741
3606
|
Value: formatValue(item, `${keyParts.measure}${keyParts.label}`),
|
|
@@ -4006,6 +4871,9 @@ class LogicalFile extends StateObject {
|
|
|
4006
4871
|
fetchDefFile(format2) {
|
|
4007
4872
|
return this.connection.DFUFile({ Name: this.Name, Format: format2 });
|
|
4008
4873
|
}
|
|
4874
|
+
fetchAllLogicalFiles() {
|
|
4875
|
+
return this.connection.recursiveFetchLogicalFiles([this]);
|
|
4876
|
+
}
|
|
4009
4877
|
fetchListHistory() {
|
|
4010
4878
|
return this.connection.ListHistory({ Name: this.Name }).then((response) => {
|
|
4011
4879
|
var _a;
|