@maptiler/geocoding-control 1.2.3 → 1.2.4
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/leaflet.js +1 -1
- package/leaflet.umd.js +1 -1
- package/maplibregl-controller.js +761 -759
- package/maplibregl-controller.js.map +1 -1
- package/maplibregl-controller.umd.js +3 -3
- package/maplibregl-controller.umd.js.map +1 -1
- package/maplibregl.js +357 -355
- package/maplibregl.js.map +1 -1
- package/maplibregl.umd.js +4 -4
- package/maplibregl.umd.js.map +1 -1
- package/maptilersdk.js +357 -355
- package/maptilersdk.js.map +1 -1
- package/maptilersdk.umd.js +4 -4
- package/maptilersdk.umd.js.map +1 -1
- package/openlayers.js +1 -1
- package/openlayers.umd.js +1 -1
- package/package.json +1 -1
- package/react.js +1 -1
- package/react.umd.js +1 -1
- package/svelte/GeocodingControl.svelte +1 -1
- package/svelte/maplibregl-controller.js +15 -6
- package/vanilla.js +1 -1
- package/vanilla.umd.js +1 -1
package/maplibregl-controller.js
CHANGED
|
@@ -524,10 +524,10 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
524
524
|
var s = {
|
|
525
525
|
x: r.x - t.x,
|
|
526
526
|
y: r.y - t.y
|
|
527
|
-
}, a = li(s, e) / o, u = li(s, i) / o, l = t.x + u * e.x, c = r.x + a * i.x, f = t.y + u * e.y, h = r.y + a * i.y,
|
|
527
|
+
}, a = li(s, e) / o, u = li(s, i) / o, l = t.x + u * e.x, c = r.x + a * i.x, f = t.y + u * e.y, h = r.y + a * i.y, p = (l + c) / 2, g = (f + h) / 2;
|
|
528
528
|
return {
|
|
529
|
-
x:
|
|
530
|
-
y:
|
|
529
|
+
x: p,
|
|
530
|
+
y: g
|
|
531
531
|
};
|
|
532
532
|
}, vr = /* @__PURE__ */ function() {
|
|
533
533
|
ae(n, null, [{
|
|
@@ -604,8 +604,8 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
604
604
|
};
|
|
605
605
|
return function(s, a) {
|
|
606
606
|
i.has(s) || o(s), i.has(a) || o(a);
|
|
607
|
-
var u = i.get(s), l = u.sine, c = u.cosine, f = i.get(a), h = f.sine,
|
|
608
|
-
return l >= 0 && h >= 0 ? c <
|
|
607
|
+
var u = i.get(s), l = u.sine, c = u.cosine, f = i.get(a), h = f.sine, p = f.cosine;
|
|
608
|
+
return l >= 0 && h >= 0 ? c < p ? 1 : c > p ? -1 : 0 : l < 0 && h < 0 ? c < p ? -1 : c > p ? 1 : 0 : h < l ? -1 : h > l ? 1 : 0;
|
|
609
609
|
};
|
|
610
610
|
}
|
|
611
611
|
}]), n;
|
|
@@ -642,28 +642,28 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
642
642
|
return 1;
|
|
643
643
|
if (h > 0)
|
|
644
644
|
return -1;
|
|
645
|
-
var
|
|
646
|
-
return
|
|
645
|
+
var p = r.comparePoint(e.rightSE.point);
|
|
646
|
+
return p !== 0 ? p : -1;
|
|
647
647
|
}
|
|
648
648
|
if (i > o) {
|
|
649
649
|
if (u < l && u < f)
|
|
650
650
|
return -1;
|
|
651
651
|
if (u > l && u > f)
|
|
652
652
|
return 1;
|
|
653
|
-
var
|
|
654
|
-
if (
|
|
655
|
-
return
|
|
656
|
-
var
|
|
657
|
-
return
|
|
653
|
+
var g = r.comparePoint(e.leftSE.point);
|
|
654
|
+
if (g !== 0)
|
|
655
|
+
return g;
|
|
656
|
+
var m = e.comparePoint(r.rightSE.point);
|
|
657
|
+
return m < 0 ? 1 : m > 0 ? -1 : 1;
|
|
658
658
|
}
|
|
659
659
|
if (u < l)
|
|
660
660
|
return -1;
|
|
661
661
|
if (u > l)
|
|
662
662
|
return 1;
|
|
663
663
|
if (s < a) {
|
|
664
|
-
var
|
|
665
|
-
if (
|
|
666
|
-
return
|
|
664
|
+
var d = r.comparePoint(e.rightSE.point);
|
|
665
|
+
if (d !== 0)
|
|
666
|
+
return d;
|
|
667
667
|
}
|
|
668
668
|
if (s > a) {
|
|
669
669
|
var E = e.comparePoint(r.rightSE.point);
|
|
@@ -673,10 +673,10 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
673
673
|
return -1;
|
|
674
674
|
}
|
|
675
675
|
if (s !== a) {
|
|
676
|
-
var I = c - u, C = s - i,
|
|
677
|
-
if (I > C &&
|
|
676
|
+
var I = c - u, C = s - i, x = f - l, R = a - o;
|
|
677
|
+
if (I > C && x < R)
|
|
678
678
|
return 1;
|
|
679
|
-
if (I < C &&
|
|
679
|
+
if (I < C && x > R)
|
|
680
680
|
return -1;
|
|
681
681
|
}
|
|
682
682
|
return s > a ? 1 : s < a || c < f ? -1 : c > f ? 1 : e.id < r.id ? -1 : e.id > r.id ? 1 : 0;
|
|
@@ -770,21 +770,21 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
770
770
|
var r = this.bbox(), i = e.bbox(), o = wo(r, i);
|
|
771
771
|
if (o === null)
|
|
772
772
|
return null;
|
|
773
|
-
var s = this.leftSE.point, a = this.rightSE.point, u = e.leftSE.point, l = e.rightSE.point, c = oi(r, u) && this.comparePoint(u) === 0, f = oi(i, s) && e.comparePoint(s) === 0, h = oi(r, l) && this.comparePoint(l) === 0,
|
|
773
|
+
var s = this.leftSE.point, a = this.rightSE.point, u = e.leftSE.point, l = e.rightSE.point, c = oi(r, u) && this.comparePoint(u) === 0, f = oi(i, s) && e.comparePoint(s) === 0, h = oi(r, l) && this.comparePoint(l) === 0, p = oi(i, a) && e.comparePoint(a) === 0;
|
|
774
774
|
if (f && c)
|
|
775
|
-
return
|
|
775
|
+
return p && !h ? a : !p && h ? l : null;
|
|
776
776
|
if (f)
|
|
777
777
|
return h && s.x === l.x && s.y === l.y ? null : s;
|
|
778
778
|
if (c)
|
|
779
|
-
return
|
|
780
|
-
if (
|
|
779
|
+
return p && a.x === u.x && a.y === u.y ? null : u;
|
|
780
|
+
if (p && h)
|
|
781
781
|
return null;
|
|
782
|
-
if (
|
|
782
|
+
if (p)
|
|
783
783
|
return a;
|
|
784
784
|
if (h)
|
|
785
785
|
return l;
|
|
786
|
-
var
|
|
787
|
-
return
|
|
786
|
+
var g = $a(s, this.vector(), u, e.vector());
|
|
787
|
+
return g === null || !oi(o, g) ? null : fi.round(g.x, g.y);
|
|
788
788
|
}
|
|
789
789
|
/**
|
|
790
790
|
* Split the given segment into multiple segments on the given points.
|
|
@@ -879,21 +879,21 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
879
879
|
var u = this.rings[s], l = this.windings[s], c = r.indexOf(u);
|
|
880
880
|
c === -1 ? (r.push(u), i.push(l)) : i[c] += l;
|
|
881
881
|
}
|
|
882
|
-
for (var f = [], h = [],
|
|
883
|
-
if (i[
|
|
884
|
-
var
|
|
885
|
-
if (h.indexOf(
|
|
886
|
-
if (
|
|
887
|
-
f.push(
|
|
882
|
+
for (var f = [], h = [], p = 0, g = r.length; p < g; p++)
|
|
883
|
+
if (i[p] !== 0) {
|
|
884
|
+
var m = r[p], d = m.poly;
|
|
885
|
+
if (h.indexOf(d) === -1)
|
|
886
|
+
if (m.isExterior)
|
|
887
|
+
f.push(d);
|
|
888
888
|
else {
|
|
889
|
-
h.indexOf(
|
|
890
|
-
var E = f.indexOf(
|
|
889
|
+
h.indexOf(d) === -1 && h.push(d);
|
|
890
|
+
var E = f.indexOf(m.poly);
|
|
891
891
|
E !== -1 && f.splice(E, 1);
|
|
892
892
|
}
|
|
893
893
|
}
|
|
894
894
|
for (var I = 0, C = f.length; I < C; I++) {
|
|
895
|
-
var
|
|
896
|
-
o.indexOf(
|
|
895
|
+
var x = f[I].multiPoly;
|
|
896
|
+
o.indexOf(x) === -1 && o.push(x);
|
|
897
897
|
}
|
|
898
898
|
return this._afterState;
|
|
899
899
|
}
|
|
@@ -1056,31 +1056,31 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
1056
1056
|
if (!(!s.isInResult() || s.ringOut)) {
|
|
1057
1057
|
for (var a = null, u = s.leftSE, l = s.rightSE, c = [u], f = u.point, h = []; a = u, u = l, c.push(u), u.point !== f; )
|
|
1058
1058
|
for (; ; ) {
|
|
1059
|
-
var
|
|
1060
|
-
if (
|
|
1061
|
-
var
|
|
1062
|
-
throw new Error("Unable to complete output ring starting at [".concat(
|
|
1059
|
+
var p = u.getAvailableLinkedEvents();
|
|
1060
|
+
if (p.length === 0) {
|
|
1061
|
+
var g = c[0].point, m = c[c.length - 1].point;
|
|
1062
|
+
throw new Error("Unable to complete output ring starting at [".concat(g.x, ",") + " ".concat(g.y, "]. Last matching segment found ends at") + " [".concat(m.x, ", ").concat(m.y, "]."));
|
|
1063
1063
|
}
|
|
1064
|
-
if (
|
|
1065
|
-
l =
|
|
1064
|
+
if (p.length === 1) {
|
|
1065
|
+
l = p[0].otherSE;
|
|
1066
1066
|
break;
|
|
1067
1067
|
}
|
|
1068
|
-
for (var
|
|
1068
|
+
for (var d = null, E = 0, I = h.length; E < I; E++)
|
|
1069
1069
|
if (h[E].point === u.point) {
|
|
1070
|
-
|
|
1070
|
+
d = E;
|
|
1071
1071
|
break;
|
|
1072
1072
|
}
|
|
1073
|
-
if (
|
|
1074
|
-
var C = h.splice(
|
|
1075
|
-
|
|
1073
|
+
if (d !== null) {
|
|
1074
|
+
var C = h.splice(d)[0], x = c.splice(C.index);
|
|
1075
|
+
x.unshift(x[0].otherSE), r.push(new n(x.reverse()));
|
|
1076
1076
|
continue;
|
|
1077
1077
|
}
|
|
1078
1078
|
h.push({
|
|
1079
1079
|
index: c.length,
|
|
1080
1080
|
point: u.point
|
|
1081
1081
|
});
|
|
1082
|
-
var
|
|
1083
|
-
l =
|
|
1082
|
+
var R = u.getLeftmostComparator(a);
|
|
1083
|
+
l = p.sort(R)[0].otherSE;
|
|
1084
1084
|
break;
|
|
1085
1085
|
}
|
|
1086
1086
|
r.push(new n(c));
|
|
@@ -1106,9 +1106,9 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
1106
1106
|
return null;
|
|
1107
1107
|
var u = r[0], l = r[1];
|
|
1108
1108
|
ss(u, e, l) === 0 && r.shift(), r.push(r[0]);
|
|
1109
|
-
for (var c = this.isExteriorRing() ? 1 : -1, f = this.isExteriorRing() ? 0 : r.length - 1, h = this.isExteriorRing() ? r.length : -1,
|
|
1110
|
-
|
|
1111
|
-
return
|
|
1109
|
+
for (var c = this.isExteriorRing() ? 1 : -1, f = this.isExteriorRing() ? 0 : r.length - 1, h = this.isExteriorRing() ? r.length : -1, p = [], g = f; g != h; g += c)
|
|
1110
|
+
p.push([r[g].x, r[g].y]);
|
|
1111
|
+
return p;
|
|
1112
1112
|
}
|
|
1113
1113
|
}, {
|
|
1114
1114
|
key: "isExteriorRing",
|
|
@@ -1217,29 +1217,29 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
1217
1217
|
if (u) {
|
|
1218
1218
|
var f = u.getIntersection(r);
|
|
1219
1219
|
if (f !== null && (r.isAnEndpoint(f) || (c = f), !u.isAnEndpoint(f)))
|
|
1220
|
-
for (var h = this._splitSafely(u, f),
|
|
1221
|
-
i.push(h[
|
|
1220
|
+
for (var h = this._splitSafely(u, f), p = 0, g = h.length; p < g; p++)
|
|
1221
|
+
i.push(h[p]);
|
|
1222
1222
|
}
|
|
1223
|
-
var
|
|
1223
|
+
var m = null;
|
|
1224
1224
|
if (l) {
|
|
1225
|
-
var
|
|
1226
|
-
if (
|
|
1227
|
-
for (var E = this._splitSafely(l,
|
|
1225
|
+
var d = l.getIntersection(r);
|
|
1226
|
+
if (d !== null && (r.isAnEndpoint(d) || (m = d), !l.isAnEndpoint(d)))
|
|
1227
|
+
for (var E = this._splitSafely(l, d), I = 0, C = E.length; I < C; I++)
|
|
1228
1228
|
i.push(E[I]);
|
|
1229
1229
|
}
|
|
1230
|
-
if (c !== null ||
|
|
1231
|
-
var
|
|
1230
|
+
if (c !== null || m !== null) {
|
|
1231
|
+
var x = null;
|
|
1232
1232
|
if (c === null)
|
|
1233
|
-
|
|
1234
|
-
else if (
|
|
1235
|
-
|
|
1233
|
+
x = m;
|
|
1234
|
+
else if (m === null)
|
|
1235
|
+
x = c;
|
|
1236
1236
|
else {
|
|
1237
|
-
var
|
|
1238
|
-
|
|
1237
|
+
var R = vr.comparePoints(c, m);
|
|
1238
|
+
x = R <= 0 ? c : m;
|
|
1239
1239
|
}
|
|
1240
1240
|
this.queue.remove(r.rightSE), i.push(r.rightSE);
|
|
1241
|
-
for (var
|
|
1242
|
-
i.push(
|
|
1241
|
+
for (var O = r.split(x), F = 0, G = O.length; F < G; F++)
|
|
1242
|
+
i.push(O[F]);
|
|
1243
1243
|
}
|
|
1244
1244
|
i.length > 0 ? (this.tree.remove(r), i.push(e)) : (this.segments.push(r), r.prev = u);
|
|
1245
1245
|
} else {
|
|
@@ -1285,32 +1285,32 @@ var Ka = Hr * Hr, Po = function(t, e) {
|
|
|
1285
1285
|
wo(o[l].bbox, u.bbox) !== null ? l++ : o.splice(l, 1);
|
|
1286
1286
|
if (tr.type === "intersection") {
|
|
1287
1287
|
for (var c = 0, f = o.length; c < f; c++)
|
|
1288
|
-
for (var h = o[c],
|
|
1289
|
-
if (wo(h.bbox, o[
|
|
1288
|
+
for (var h = o[c], p = c + 1, g = o.length; p < g; p++)
|
|
1289
|
+
if (wo(h.bbox, o[p].bbox) === null)
|
|
1290
1290
|
return [];
|
|
1291
1291
|
}
|
|
1292
|
-
for (var
|
|
1293
|
-
for (var I = o[
|
|
1294
|
-
if (
|
|
1292
|
+
for (var m = new Vo(vr.compare), d = 0, E = o.length; d < E; d++)
|
|
1293
|
+
for (var I = o[d].getSweepEvents(), C = 0, x = I.length; C < x; C++)
|
|
1294
|
+
if (m.insert(I[C]), m.size > hs)
|
|
1295
1295
|
throw new Error("Infinite loop when putting segment endpoints in a priority queue (queue size too big). Please file a bug report.");
|
|
1296
|
-
for (var
|
|
1296
|
+
for (var R = new iu(m), O = m.size, F = m.pop(); F; ) {
|
|
1297
1297
|
var G = F.key;
|
|
1298
|
-
if (
|
|
1298
|
+
if (m.size === O) {
|
|
1299
1299
|
var M = G.segment;
|
|
1300
1300
|
throw new Error("Unable to pop() ".concat(G.isLeft ? "left" : "right", " SweepEvent ") + "[".concat(G.point.x, ", ").concat(G.point.y, "] from segment #").concat(M.id, " ") + "[".concat(M.leftSE.point.x, ", ").concat(M.leftSE.point.y, "] -> ") + "[".concat(M.rightSE.point.x, ", ").concat(M.rightSE.point.y, "] from queue. ") + "Please file a bug report.");
|
|
1301
1301
|
}
|
|
1302
|
-
if (
|
|
1302
|
+
if (m.size > hs)
|
|
1303
1303
|
throw new Error("Infinite loop when passing sweep line over endpoints (queue size too big). Please file a bug report.");
|
|
1304
|
-
if (
|
|
1304
|
+
if (R.segments.length > ou)
|
|
1305
1305
|
throw new Error("Infinite loop when passing sweep line over endpoints (too many sweep line segments). Please file a bug report.");
|
|
1306
|
-
for (var et =
|
|
1306
|
+
for (var et = R.process(G), K = 0, nt = et.length; K < nt; K++) {
|
|
1307
1307
|
var ct = et[K];
|
|
1308
|
-
ct.consumedBy === void 0 &&
|
|
1308
|
+
ct.consumedBy === void 0 && m.insert(ct);
|
|
1309
1309
|
}
|
|
1310
|
-
|
|
1310
|
+
O = m.size, F = m.pop();
|
|
1311
1311
|
}
|
|
1312
1312
|
fi.reset();
|
|
1313
|
-
var w = ru.factory(
|
|
1313
|
+
var w = ru.factory(R.segments), X = new nu(w);
|
|
1314
1314
|
return X.getGeom();
|
|
1315
1315
|
}
|
|
1316
1316
|
}]), n;
|
|
@@ -1560,9 +1560,9 @@ function bu(n, t, e, r, i, o, s = null, a = [-1]) {
|
|
|
1560
1560
|
};
|
|
1561
1561
|
s && s(l.root);
|
|
1562
1562
|
let c = !1;
|
|
1563
|
-
if (l.ctx = e ? e(n, t.props || {}, (f, h, ...
|
|
1564
|
-
const
|
|
1565
|
-
return l.ctx && i(l.ctx[f], l.ctx[f] =
|
|
1563
|
+
if (l.ctx = e ? e(n, t.props || {}, (f, h, ...p) => {
|
|
1564
|
+
const g = p.length ? p[0] : h;
|
|
1565
|
+
return l.ctx && i(l.ctx[f], l.ctx[f] = g) && (!l.skip_bound && l.bound[f] && l.bound[f](g), c && Pu(n, f)), h;
|
|
1566
1566
|
}) : [], l.update(), c = !0, no(l.before_update), l.fragment = r ? r(l.ctx) : !1, t.target) {
|
|
1567
1567
|
if (t.hydrate) {
|
|
1568
1568
|
const f = _u(t.target);
|
|
@@ -1678,14 +1678,14 @@ class Mu extends Ru {
|
|
|
1678
1678
|
}
|
|
1679
1679
|
function Js(n, t, e) {
|
|
1680
1680
|
if (n !== null)
|
|
1681
|
-
for (var r, i, o, s, a, u, l, c = 0, f = 0, h,
|
|
1682
|
-
l =
|
|
1681
|
+
for (var r, i, o, s, a, u, l, c = 0, f = 0, h, p = n.type, g = p === "FeatureCollection", m = p === "Feature", d = g ? n.features.length : 1, E = 0; E < d; E++) {
|
|
1682
|
+
l = g ? n.features[E].geometry : m ? n.geometry : n, h = l ? l.type === "GeometryCollection" : !1, a = h ? l.geometries.length : 1;
|
|
1683
1683
|
for (var I = 0; I < a; I++) {
|
|
1684
|
-
var C = 0,
|
|
1684
|
+
var C = 0, x = 0;
|
|
1685
1685
|
if (s = h ? l.geometries[I] : l, s !== null) {
|
|
1686
1686
|
u = s.coordinates;
|
|
1687
|
-
var
|
|
1688
|
-
switch (c = 0,
|
|
1687
|
+
var R = s.type;
|
|
1688
|
+
switch (c = 0, R) {
|
|
1689
1689
|
case null:
|
|
1690
1690
|
break;
|
|
1691
1691
|
case "Point":
|
|
@@ -1694,7 +1694,7 @@ function Js(n, t, e) {
|
|
|
1694
1694
|
f,
|
|
1695
1695
|
E,
|
|
1696
1696
|
C,
|
|
1697
|
-
|
|
1697
|
+
x
|
|
1698
1698
|
) === !1)
|
|
1699
1699
|
return !1;
|
|
1700
1700
|
f++, C++;
|
|
@@ -1707,12 +1707,12 @@ function Js(n, t, e) {
|
|
|
1707
1707
|
f,
|
|
1708
1708
|
E,
|
|
1709
1709
|
C,
|
|
1710
|
-
|
|
1710
|
+
x
|
|
1711
1711
|
) === !1)
|
|
1712
1712
|
return !1;
|
|
1713
|
-
f++,
|
|
1713
|
+
f++, R === "MultiPoint" && C++;
|
|
1714
1714
|
}
|
|
1715
|
-
|
|
1715
|
+
R === "LineString" && C++;
|
|
1716
1716
|
break;
|
|
1717
1717
|
case "Polygon":
|
|
1718
1718
|
case "MultiLineString":
|
|
@@ -1723,30 +1723,30 @@ function Js(n, t, e) {
|
|
|
1723
1723
|
f,
|
|
1724
1724
|
E,
|
|
1725
1725
|
C,
|
|
1726
|
-
|
|
1726
|
+
x
|
|
1727
1727
|
) === !1)
|
|
1728
1728
|
return !1;
|
|
1729
1729
|
f++;
|
|
1730
1730
|
}
|
|
1731
|
-
|
|
1731
|
+
R === "MultiLineString" && C++, R === "Polygon" && x++;
|
|
1732
1732
|
}
|
|
1733
|
-
|
|
1733
|
+
R === "Polygon" && C++;
|
|
1734
1734
|
break;
|
|
1735
1735
|
case "MultiPolygon":
|
|
1736
1736
|
for (r = 0; r < u.length; r++) {
|
|
1737
|
-
for (
|
|
1737
|
+
for (x = 0, i = 0; i < u[r].length; i++) {
|
|
1738
1738
|
for (o = 0; o < u[r][i].length - c; o++) {
|
|
1739
1739
|
if (t(
|
|
1740
1740
|
u[r][i][o],
|
|
1741
1741
|
f,
|
|
1742
1742
|
E,
|
|
1743
1743
|
C,
|
|
1744
|
-
|
|
1744
|
+
x
|
|
1745
1745
|
) === !1)
|
|
1746
1746
|
return !1;
|
|
1747
1747
|
f++;
|
|
1748
1748
|
}
|
|
1749
|
-
|
|
1749
|
+
x++;
|
|
1750
1750
|
}
|
|
1751
1751
|
C++;
|
|
1752
1752
|
}
|
|
@@ -1771,9 +1771,9 @@ function ms(n, t) {
|
|
|
1771
1771
|
;
|
|
1772
1772
|
}
|
|
1773
1773
|
function Zs(n, t) {
|
|
1774
|
-
var e, r, i, o, s, a, u, l, c, f, h = 0,
|
|
1775
|
-
for (e = 0; e <
|
|
1776
|
-
for (a =
|
|
1774
|
+
var e, r, i, o, s, a, u, l, c, f, h = 0, p = n.type === "FeatureCollection", g = n.type === "Feature", m = p ? n.features.length : 1;
|
|
1775
|
+
for (e = 0; e < m; e++) {
|
|
1776
|
+
for (a = p ? n.features[e].geometry : g ? n.geometry : n, l = p ? n.features[e].properties : g ? n.properties : {}, c = p ? n.features[e].bbox : g ? n.bbox : void 0, f = p ? n.features[e].id : g ? n.id : void 0, u = a ? a.type === "GeometryCollection" : !1, s = u ? a.geometries.length : 1, i = 0; i < s; i++) {
|
|
1777
1777
|
if (o = u ? a.geometries[i] : a, o === null) {
|
|
1778
1778
|
if (t(
|
|
1779
1779
|
null,
|
|
@@ -1900,7 +1900,7 @@ var Ee = function() {
|
|
|
1900
1900
|
};
|
|
1901
1901
|
function Ie() {
|
|
1902
1902
|
}
|
|
1903
|
-
var
|
|
1903
|
+
var v = function n() {
|
|
1904
1904
|
if (this.x = null, this.y = null, this.z = null, arguments.length === 0)
|
|
1905
1905
|
this.x = 0, this.y = 0, this.z = n.NULL_ORDINATE;
|
|
1906
1906
|
else if (arguments.length === 1) {
|
|
@@ -1909,22 +1909,22 @@ var d = function n() {
|
|
|
1909
1909
|
} else
|
|
1910
1910
|
arguments.length === 2 ? (this.x = arguments[0], this.y = arguments[1], this.z = n.NULL_ORDINATE) : arguments.length === 3 && (this.x = arguments[0], this.y = arguments[1], this.z = arguments[2]);
|
|
1911
1911
|
}, Cn = { DimensionalComparator: { configurable: !0 }, serialVersionUID: { configurable: !0 }, NULL_ORDINATE: { configurable: !0 }, X: { configurable: !0 }, Y: { configurable: !0 }, Z: { configurable: !0 } };
|
|
1912
|
-
|
|
1912
|
+
v.prototype.setOrdinate = function(t, e) {
|
|
1913
1913
|
switch (t) {
|
|
1914
|
-
case
|
|
1914
|
+
case v.X:
|
|
1915
1915
|
this.x = e;
|
|
1916
1916
|
break;
|
|
1917
|
-
case
|
|
1917
|
+
case v.Y:
|
|
1918
1918
|
this.y = e;
|
|
1919
1919
|
break;
|
|
1920
|
-
case
|
|
1920
|
+
case v.Z:
|
|
1921
1921
|
this.z = e;
|
|
1922
1922
|
break;
|
|
1923
1923
|
default:
|
|
1924
1924
|
throw new it("Invalid ordinate index: " + t);
|
|
1925
1925
|
}
|
|
1926
1926
|
};
|
|
1927
|
-
|
|
1927
|
+
v.prototype.equals2D = function() {
|
|
1928
1928
|
if (arguments.length === 1) {
|
|
1929
1929
|
var t = arguments[0];
|
|
1930
1930
|
return !(this.x !== t.x || this.y !== t.y);
|
|
@@ -1933,60 +1933,60 @@ d.prototype.equals2D = function() {
|
|
|
1933
1933
|
return !(!ln.equalsWithTolerance(this.x, e.x, r) || !ln.equalsWithTolerance(this.y, e.y, r));
|
|
1934
1934
|
}
|
|
1935
1935
|
};
|
|
1936
|
-
|
|
1936
|
+
v.prototype.getOrdinate = function(t) {
|
|
1937
1937
|
switch (t) {
|
|
1938
|
-
case
|
|
1938
|
+
case v.X:
|
|
1939
1939
|
return this.x;
|
|
1940
|
-
case
|
|
1940
|
+
case v.Y:
|
|
1941
1941
|
return this.y;
|
|
1942
|
-
case
|
|
1942
|
+
case v.Z:
|
|
1943
1943
|
return this.z;
|
|
1944
1944
|
}
|
|
1945
1945
|
throw new it("Invalid ordinate index: " + t);
|
|
1946
1946
|
};
|
|
1947
|
-
|
|
1947
|
+
v.prototype.equals3D = function(t) {
|
|
1948
1948
|
return this.x === t.x && this.y === t.y && (this.z === t.z || A.isNaN(this.z)) && A.isNaN(t.z);
|
|
1949
1949
|
};
|
|
1950
|
-
|
|
1951
|
-
return t instanceof
|
|
1950
|
+
v.prototype.equals = function(t) {
|
|
1951
|
+
return t instanceof v ? this.equals2D(t) : !1;
|
|
1952
1952
|
};
|
|
1953
|
-
|
|
1953
|
+
v.prototype.equalInZ = function(t, e) {
|
|
1954
1954
|
return ln.equalsWithTolerance(this.z, t.z, e);
|
|
1955
1955
|
};
|
|
1956
|
-
|
|
1956
|
+
v.prototype.compareTo = function(t) {
|
|
1957
1957
|
var e = t;
|
|
1958
1958
|
return this.x < e.x ? -1 : this.x > e.x ? 1 : this.y < e.y ? -1 : this.y > e.y ? 1 : 0;
|
|
1959
1959
|
};
|
|
1960
|
-
|
|
1960
|
+
v.prototype.clone = function() {
|
|
1961
1961
|
};
|
|
1962
|
-
|
|
1963
|
-
return new
|
|
1962
|
+
v.prototype.copy = function() {
|
|
1963
|
+
return new v(this);
|
|
1964
1964
|
};
|
|
1965
|
-
|
|
1965
|
+
v.prototype.toString = function() {
|
|
1966
1966
|
return "(" + this.x + ", " + this.y + ", " + this.z + ")";
|
|
1967
1967
|
};
|
|
1968
|
-
|
|
1968
|
+
v.prototype.distance3D = function(t) {
|
|
1969
1969
|
var e = this.x - t.x, r = this.y - t.y, i = this.z - t.z;
|
|
1970
1970
|
return Math.sqrt(e * e + r * r + i * i);
|
|
1971
1971
|
};
|
|
1972
|
-
|
|
1972
|
+
v.prototype.distance = function(t) {
|
|
1973
1973
|
var e = this.x - t.x, r = this.y - t.y;
|
|
1974
1974
|
return Math.sqrt(e * e + r * r);
|
|
1975
1975
|
};
|
|
1976
|
-
|
|
1976
|
+
v.prototype.hashCode = function() {
|
|
1977
1977
|
var t = 17;
|
|
1978
|
-
return t = 37 * t +
|
|
1978
|
+
return t = 37 * t + v.hashCode(this.x), t = 37 * t + v.hashCode(this.y), t;
|
|
1979
1979
|
};
|
|
1980
|
-
|
|
1980
|
+
v.prototype.setCoordinate = function(t) {
|
|
1981
1981
|
this.x = t.x, this.y = t.y, this.z = t.z;
|
|
1982
1982
|
};
|
|
1983
|
-
|
|
1983
|
+
v.prototype.interfaces_ = function() {
|
|
1984
1984
|
return [Ee, io, Ie];
|
|
1985
1985
|
};
|
|
1986
|
-
|
|
1987
|
-
return
|
|
1986
|
+
v.prototype.getClass = function() {
|
|
1987
|
+
return v;
|
|
1988
1988
|
};
|
|
1989
|
-
|
|
1989
|
+
v.hashCode = function() {
|
|
1990
1990
|
if (arguments.length === 1) {
|
|
1991
1991
|
var t = arguments[0], e = A.doubleToLongBits(t);
|
|
1992
1992
|
return Math.trunc((e ^ e) >>> 32);
|
|
@@ -2010,7 +2010,7 @@ Cn.Y.get = function() {
|
|
|
2010
2010
|
Cn.Z.get = function() {
|
|
2011
2011
|
return 2;
|
|
2012
2012
|
};
|
|
2013
|
-
Object.defineProperties(
|
|
2013
|
+
Object.defineProperties(v, Cn);
|
|
2014
2014
|
var Rr = function(t) {
|
|
2015
2015
|
if (this._dimensionsToTest = 2, arguments.length !== 0) {
|
|
2016
2016
|
if (arguments.length === 1) {
|
|
@@ -2196,8 +2196,8 @@ _.prototype.extractSignificantDigits = function(t, e) {
|
|
|
2196
2196
|
break;
|
|
2197
2197
|
var f = !1, h = 0;
|
|
2198
2198
|
c > 9 ? (f = !0, h = "9") : h = "0" + c, a.append(h), r = r.subtract(_.valueOf(c)).multiply(_.TEN), f && r.selfAdd(_.TEN);
|
|
2199
|
-
var
|
|
2200
|
-
if (
|
|
2199
|
+
var p = !0, g = _.magnitude(r._hi);
|
|
2200
|
+
if (g < 0 && Math.abs(g) >= u - l && (p = !1), !p)
|
|
2201
2201
|
break;
|
|
2202
2202
|
}
|
|
2203
2203
|
return e[0] = i, a.toString();
|
|
@@ -2329,10 +2329,10 @@ _.prototype.selfAdd = function() {
|
|
|
2329
2329
|
return o = this._hi + e, a = o - this._hi, s = o - a, s = e - a + (this._hi - s), u = s + this._lo, r = o + u, i = u + (o - r), this._hi = r + i, this._lo = i + (r - this._hi), this;
|
|
2330
2330
|
}
|
|
2331
2331
|
} else if (arguments.length === 2) {
|
|
2332
|
-
var l = arguments[0], c = arguments[1], f = null, h = null,
|
|
2333
|
-
|
|
2334
|
-
var C = f + E,
|
|
2335
|
-
return this._hi = C, this._lo =
|
|
2332
|
+
var l = arguments[0], c = arguments[1], f = null, h = null, p = null, g = null, m = null, d = null, E = null, I = null;
|
|
2333
|
+
m = this._hi + l, p = this._lo + c, E = m - this._hi, I = p - this._lo, d = m - E, g = p - I, d = l - E + (this._hi - d), g = c - I + (this._lo - g), E = d + p, f = m + E, h = E + (m - f), E = g + h;
|
|
2334
|
+
var C = f + E, x = E + (f - C);
|
|
2335
|
+
return this._hi = C, this._lo = x, this;
|
|
2336
2336
|
}
|
|
2337
2337
|
};
|
|
2338
2338
|
_.prototype.selfMultiply = function() {
|
|
@@ -2517,17 +2517,17 @@ _.parse = function(t) {
|
|
|
2517
2517
|
}
|
|
2518
2518
|
throw new Error("Unexpected character '" + c + "' at position " + e + " in string " + t);
|
|
2519
2519
|
}
|
|
2520
|
-
var
|
|
2521
|
-
if (
|
|
2522
|
-
|
|
2523
|
-
else if (
|
|
2524
|
-
var
|
|
2525
|
-
|
|
2526
|
-
} else if (
|
|
2527
|
-
var
|
|
2528
|
-
|
|
2520
|
+
var p = s, g = a - u - l;
|
|
2521
|
+
if (g === 0)
|
|
2522
|
+
p = s;
|
|
2523
|
+
else if (g > 0) {
|
|
2524
|
+
var m = _.TEN.pow(g);
|
|
2525
|
+
p = s.divide(m);
|
|
2526
|
+
} else if (g < 0) {
|
|
2527
|
+
var d = _.TEN.pow(-g);
|
|
2528
|
+
p = s.multiply(d);
|
|
2529
2529
|
}
|
|
2530
|
-
return i ?
|
|
2530
|
+
return i ? p.negate() : p;
|
|
2531
2531
|
};
|
|
2532
2532
|
_.createNaN = function() {
|
|
2533
2533
|
return new _(A.NaN, A.NaN);
|
|
@@ -2601,8 +2601,8 @@ Kt.signOfDet2x2 = function(t, e, r, i) {
|
|
|
2601
2601
|
return o.signum();
|
|
2602
2602
|
};
|
|
2603
2603
|
Kt.intersection = function(t, e, r, i) {
|
|
2604
|
-
var o = _.valueOf(i.y).selfSubtract(r.y).selfMultiply(_.valueOf(e.x).selfSubtract(t.x)), s = _.valueOf(i.x).selfSubtract(r.x).selfMultiply(_.valueOf(e.y).selfSubtract(t.y)), a = o.subtract(s), u = _.valueOf(i.x).selfSubtract(r.x).selfMultiply(_.valueOf(t.y).selfSubtract(r.y)), l = _.valueOf(i.y).selfSubtract(r.y).selfMultiply(_.valueOf(t.x).selfSubtract(r.x)), c = u.subtract(l), f = c.selfDivide(a).doubleValue(), h = _.valueOf(t.x).selfAdd(_.valueOf(e.x).selfSubtract(t.x).selfMultiply(f)).doubleValue(),
|
|
2605
|
-
return new
|
|
2604
|
+
var o = _.valueOf(i.y).selfSubtract(r.y).selfMultiply(_.valueOf(e.x).selfSubtract(t.x)), s = _.valueOf(i.x).selfSubtract(r.x).selfMultiply(_.valueOf(e.y).selfSubtract(t.y)), a = o.subtract(s), u = _.valueOf(i.x).selfSubtract(r.x).selfMultiply(_.valueOf(t.y).selfSubtract(r.y)), l = _.valueOf(i.y).selfSubtract(r.y).selfMultiply(_.valueOf(t.x).selfSubtract(r.x)), c = u.subtract(l), f = c.selfDivide(a).doubleValue(), h = _.valueOf(t.x).selfAdd(_.valueOf(e.x).selfSubtract(t.x).selfMultiply(f)).doubleValue(), p = _.valueOf(e.x).selfSubtract(t.x).selfMultiply(_.valueOf(t.y).selfSubtract(r.y)), g = _.valueOf(e.y).selfSubtract(t.y).selfMultiply(_.valueOf(t.x).selfSubtract(r.x)), m = p.subtract(g), d = m.selfDivide(a).doubleValue(), E = _.valueOf(r.y).selfAdd(_.valueOf(i.y).selfSubtract(r.y).selfMultiply(d)).doubleValue();
|
|
2605
|
+
return new v(h, E);
|
|
2606
2606
|
};
|
|
2607
2607
|
Kt.orientationIndexFilter = function(t, e, r) {
|
|
2608
2608
|
var i = null, o = (t.x - r.x) * (e.y - r.y), s = (t.y - r.y) * (e.x - r.x), a = o - s;
|
|
@@ -2706,7 +2706,7 @@ var Ce = function n() {
|
|
|
2706
2706
|
} else if (arguments[0] instanceof n && arguments[1] instanceof n) {
|
|
2707
2707
|
var i = arguments[0], o = arguments[1];
|
|
2708
2708
|
this.x = i.y * o.w - o.y * i.w, this.y = o.x * i.w - i.x * o.w, this.w = i.x * o.y - o.x * i.y;
|
|
2709
|
-
} else if (arguments[0] instanceof
|
|
2709
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof v) {
|
|
2710
2710
|
var s = arguments[0], a = arguments[1];
|
|
2711
2711
|
this.x = s.y - a.y, this.y = a.x - s.x, this.w = s.x * a.y - a.x * s.y;
|
|
2712
2712
|
}
|
|
@@ -2714,8 +2714,8 @@ var Ce = function n() {
|
|
|
2714
2714
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
2715
2715
|
this.x = u, this.y = l, this.w = c;
|
|
2716
2716
|
} else if (arguments.length === 4) {
|
|
2717
|
-
var f = arguments[0], h = arguments[1],
|
|
2718
|
-
this.x =
|
|
2717
|
+
var f = arguments[0], h = arguments[1], p = arguments[2], g = arguments[3], m = f.y - h.y, d = h.x - f.x, E = f.x * h.y - h.x * f.y, I = p.y - g.y, C = g.x - p.x, x = p.x * g.y - g.x * p.y;
|
|
2718
|
+
this.x = d * x - C * E, this.y = I * E - m * x, this.w = m * C - I * d;
|
|
2719
2719
|
}
|
|
2720
2720
|
};
|
|
2721
2721
|
Ce.prototype.getY = function() {
|
|
@@ -2731,7 +2731,7 @@ Ce.prototype.getX = function() {
|
|
|
2731
2731
|
return t;
|
|
2732
2732
|
};
|
|
2733
2733
|
Ce.prototype.getCoordinate = function() {
|
|
2734
|
-
var t = new
|
|
2734
|
+
var t = new v();
|
|
2735
2735
|
return t.x = this.getX(), t.y = this.getY(), t;
|
|
2736
2736
|
};
|
|
2737
2737
|
Ce.prototype.interfaces_ = function() {
|
|
@@ -2741,16 +2741,16 @@ Ce.prototype.getClass = function() {
|
|
|
2741
2741
|
return Ce;
|
|
2742
2742
|
};
|
|
2743
2743
|
Ce.intersection = function(t, e, r, i) {
|
|
2744
|
-
var o = t.y - e.y, s = e.x - t.x, a = t.x * e.y - e.x * t.y, u = r.y - i.y, l = i.x - r.x, c = r.x * i.y - i.x * r.y, f = s * c - l * a, h = u * a - o * c,
|
|
2745
|
-
if (A.isNaN(
|
|
2744
|
+
var o = t.y - e.y, s = e.x - t.x, a = t.x * e.y - e.x * t.y, u = r.y - i.y, l = i.x - r.x, c = r.x * i.y - i.x * r.y, f = s * c - l * a, h = u * a - o * c, p = o * l - u * s, g = f / p, m = h / p;
|
|
2745
|
+
if (A.isNaN(g) || A.isInfinite(g) || A.isNaN(m) || A.isInfinite(m))
|
|
2746
2746
|
throw new $n();
|
|
2747
|
-
return new
|
|
2747
|
+
return new v(g, m);
|
|
2748
2748
|
};
|
|
2749
2749
|
var P = function n() {
|
|
2750
2750
|
if (this._minx = null, this._maxx = null, this._miny = null, this._maxy = null, arguments.length === 0)
|
|
2751
2751
|
this.init();
|
|
2752
2752
|
else if (arguments.length === 1) {
|
|
2753
|
-
if (arguments[0] instanceof
|
|
2753
|
+
if (arguments[0] instanceof v) {
|
|
2754
2754
|
var t = arguments[0];
|
|
2755
2755
|
this.init(t.x, t.x, t.y, t.y);
|
|
2756
2756
|
} else if (arguments[0] instanceof n) {
|
|
@@ -2788,7 +2788,7 @@ P.prototype.getMaxX = function() {
|
|
|
2788
2788
|
};
|
|
2789
2789
|
P.prototype.covers = function() {
|
|
2790
2790
|
if (arguments.length === 1) {
|
|
2791
|
-
if (arguments[0] instanceof
|
|
2791
|
+
if (arguments[0] instanceof v) {
|
|
2792
2792
|
var t = arguments[0];
|
|
2793
2793
|
return this.covers(t.x, t.y);
|
|
2794
2794
|
} else if (arguments[0] instanceof P) {
|
|
@@ -2805,7 +2805,7 @@ P.prototype.intersects = function() {
|
|
|
2805
2805
|
if (arguments[0] instanceof P) {
|
|
2806
2806
|
var t = arguments[0];
|
|
2807
2807
|
return this.isNull() || t.isNull() ? !1 : !(t._minx > this._maxx || t._maxx < this._minx || t._miny > this._maxy || t._maxy < this._miny);
|
|
2808
|
-
} else if (arguments[0] instanceof
|
|
2808
|
+
} else if (arguments[0] instanceof v) {
|
|
2809
2809
|
var e = arguments[0];
|
|
2810
2810
|
return this.intersects(e.x, e.y);
|
|
2811
2811
|
}
|
|
@@ -2822,7 +2822,7 @@ P.prototype.getMinX = function() {
|
|
|
2822
2822
|
};
|
|
2823
2823
|
P.prototype.expandToInclude = function() {
|
|
2824
2824
|
if (arguments.length === 1) {
|
|
2825
|
-
if (arguments[0] instanceof
|
|
2825
|
+
if (arguments[0] instanceof v) {
|
|
2826
2826
|
var t = arguments[0];
|
|
2827
2827
|
this.expandToInclude(t.x, t.y);
|
|
2828
2828
|
} else if (arguments[0] instanceof P) {
|
|
@@ -2885,7 +2885,7 @@ P.prototype.contains = function() {
|
|
|
2885
2885
|
if (arguments[0] instanceof P) {
|
|
2886
2886
|
var t = arguments[0];
|
|
2887
2887
|
return this.covers(t);
|
|
2888
|
-
} else if (arguments[0] instanceof
|
|
2888
|
+
} else if (arguments[0] instanceof v) {
|
|
2889
2889
|
var e = arguments[0];
|
|
2890
2890
|
return this.covers(e);
|
|
2891
2891
|
}
|
|
@@ -2895,13 +2895,13 @@ P.prototype.contains = function() {
|
|
|
2895
2895
|
}
|
|
2896
2896
|
};
|
|
2897
2897
|
P.prototype.centre = function() {
|
|
2898
|
-
return this.isNull() ? null : new
|
|
2898
|
+
return this.isNull() ? null : new v((this.getMinX() + this.getMaxX()) / 2, (this.getMinY() + this.getMaxY()) / 2);
|
|
2899
2899
|
};
|
|
2900
2900
|
P.prototype.init = function() {
|
|
2901
2901
|
if (arguments.length === 0)
|
|
2902
2902
|
this.setToNull();
|
|
2903
2903
|
else if (arguments.length === 1) {
|
|
2904
|
-
if (arguments[0] instanceof
|
|
2904
|
+
if (arguments[0] instanceof v) {
|
|
2905
2905
|
var t = arguments[0];
|
|
2906
2906
|
this.init(t.x, t.x, t.y, t.y);
|
|
2907
2907
|
} else if (arguments[0] instanceof P) {
|
|
@@ -2929,7 +2929,7 @@ P.prototype.distance = function(t) {
|
|
|
2929
2929
|
};
|
|
2930
2930
|
P.prototype.hashCode = function() {
|
|
2931
2931
|
var t = 17;
|
|
2932
|
-
return t = 37 * t +
|
|
2932
|
+
return t = 37 * t + v.hashCode(this._minx), t = 37 * t + v.hashCode(this._maxx), t = 37 * t + v.hashCode(this._miny), t = 37 * t + v.hashCode(this._maxy), t;
|
|
2933
2933
|
};
|
|
2934
2934
|
P.prototype.interfaces_ = function() {
|
|
2935
2935
|
return [Ee, Ie];
|
|
@@ -3082,7 +3082,7 @@ var gr = {
|
|
|
3082
3082
|
if (t === void 0)
|
|
3083
3083
|
return this.geometryFactory.createPoint();
|
|
3084
3084
|
var e = t.trim().split(Me.spaces);
|
|
3085
|
-
return this.geometryFactory.createPoint(new
|
|
3085
|
+
return this.geometryFactory.createPoint(new v(
|
|
3086
3086
|
Number.parseFloat(e[0]),
|
|
3087
3087
|
Number.parseFloat(e[1])
|
|
3088
3088
|
));
|
|
@@ -3113,7 +3113,7 @@ var gr = {
|
|
|
3113
3113
|
if (t === void 0)
|
|
3114
3114
|
return this.geometryFactory.createLineString();
|
|
3115
3115
|
for (var e = t.trim().split(","), r = [], i, o = 0, s = e.length; o < s; ++o)
|
|
3116
|
-
i = e[o].trim().split(Me.spaces), r.push(new
|
|
3116
|
+
i = e[o].trim().split(Me.spaces), r.push(new v(Number.parseFloat(i[0]), Number.parseFloat(i[1])));
|
|
3117
3117
|
return this.geometryFactory.createLineString(r);
|
|
3118
3118
|
},
|
|
3119
3119
|
/**
|
|
@@ -3127,7 +3127,7 @@ var gr = {
|
|
|
3127
3127
|
if (t === void 0)
|
|
3128
3128
|
return this.geometryFactory.createLinearRing();
|
|
3129
3129
|
for (var e = t.trim().split(","), r = [], i, o = 0, s = e.length; o < s; ++o)
|
|
3130
|
-
i = e[o].trim().split(Me.spaces), r.push(new
|
|
3130
|
+
i = e[o].trim().split(Me.spaces), r.push(new v(Number.parseFloat(i[0]), Number.parseFloat(i[1])));
|
|
3131
3131
|
return this.geometryFactory.createLinearRing(r);
|
|
3132
3132
|
},
|
|
3133
3133
|
/**
|
|
@@ -3254,7 +3254,7 @@ V.equals = function() {
|
|
|
3254
3254
|
var ot = function() {
|
|
3255
3255
|
this._result = null, this._inputLines = Array(2).fill().map(function() {
|
|
3256
3256
|
return Array(2);
|
|
3257
|
-
}), this._intPt = new Array(2).fill(null), this._intLineIndex = null, this._isProper = null, this._pa = null, this._pb = null, this._precisionModel = null, this._intPt[0] = new
|
|
3257
|
+
}), this._intPt = new Array(2).fill(null), this._intLineIndex = null, this._isProper = null, this._pa = null, this._pb = null, this._precisionModel = null, this._intPt[0] = new v(), this._intPt[1] = new v(), this._pa = this._intPt[0], this._pb = this._intPt[1], this._result = 0;
|
|
3258
3258
|
}, Nn = { DONT_INTERSECT: { configurable: !0 }, DO_INTERSECT: { configurable: !0 }, COLLINEAR: { configurable: !0 }, NO_INTERSECTION: { configurable: !0 }, POINT_INTERSECTION: { configurable: !0 }, COLLINEAR_INTERSECTION: { configurable: !0 } };
|
|
3259
3259
|
ot.prototype.getIndexAlongSegment = function(t, e) {
|
|
3260
3260
|
return this.computeIntLineIndex(), this._intLineIndex[t][e];
|
|
@@ -3399,7 +3399,7 @@ var sn = function(n) {
|
|
|
3399
3399
|
return a;
|
|
3400
3400
|
}, t.prototype.intersection = function(r, i, o, s) {
|
|
3401
3401
|
var a = this.intersectionWithNormalization(r, i, o, s);
|
|
3402
|
-
return this.isInSegmentEnvelopes(a) || (a = new
|
|
3402
|
+
return this.isInSegmentEnvelopes(a) || (a = new v(t.nearestEndpoint(r, i, o, s))), this._precisionModel !== null && this._precisionModel.makePrecise(a), a;
|
|
3403
3403
|
}, t.prototype.smallestInAbsValue = function(r, i, o, s) {
|
|
3404
3404
|
var a = r, u = Math.abs(a);
|
|
3405
3405
|
return Math.abs(i) < u && (a = i, u = Math.abs(i)), Math.abs(o) < u && (a = o, u = Math.abs(o)), Math.abs(s) < u && (a = s), a;
|
|
@@ -3407,7 +3407,7 @@ var sn = function(n) {
|
|
|
3407
3407
|
var u = Kt.intersection(r, i, o, s), l = this.isInSegmentEnvelopes(u);
|
|
3408
3408
|
Rt.out.println("DD in env = " + l + " --------------------- " + u), a.distance(u) > 1e-4 && Rt.out.println("Distance = " + a.distance(u));
|
|
3409
3409
|
}, t.prototype.intersectionWithNormalization = function(r, i, o, s) {
|
|
3410
|
-
var a = new
|
|
3410
|
+
var a = new v(r), u = new v(i), l = new v(o), c = new v(s), f = new v();
|
|
3411
3411
|
this.normalizeToEnvCentre(a, u, l, c, f);
|
|
3412
3412
|
var h = this.safeHCoordinateIntersection(a, u, l, c);
|
|
3413
3413
|
return h.x += f.x, h.y += f.y, h;
|
|
@@ -3415,8 +3415,8 @@ var sn = function(n) {
|
|
|
3415
3415
|
var a = P.intersects(r, i, o), u = P.intersects(r, i, s), l = P.intersects(o, s, r), c = P.intersects(o, s, i);
|
|
3416
3416
|
return a && u ? (this._intPt[0] = o, this._intPt[1] = s, n.COLLINEAR_INTERSECTION) : l && c ? (this._intPt[0] = r, this._intPt[1] = i, n.COLLINEAR_INTERSECTION) : a && l ? (this._intPt[0] = o, this._intPt[1] = r, o.equals(r) && !u && !c ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : a && c ? (this._intPt[0] = o, this._intPt[1] = i, o.equals(i) && !u && !l ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : u && l ? (this._intPt[0] = s, this._intPt[1] = r, s.equals(r) && !a && !c ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : u && c ? (this._intPt[0] = s, this._intPt[1] = i, s.equals(i) && !a && !l ? n.POINT_INTERSECTION : n.COLLINEAR_INTERSECTION) : n.NO_INTERSECTION;
|
|
3417
3417
|
}, t.prototype.normalizeToEnvCentre = function(r, i, o, s, a) {
|
|
3418
|
-
var u = r.x < i.x ? r.x : i.x, l = r.y < i.y ? r.y : i.y, c = r.x > i.x ? r.x : i.x, f = r.y > i.y ? r.y : i.y, h = o.x < s.x ? o.x : s.x,
|
|
3419
|
-
a.x =
|
|
3418
|
+
var u = r.x < i.x ? r.x : i.x, l = r.y < i.y ? r.y : i.y, c = r.x > i.x ? r.x : i.x, f = r.y > i.y ? r.y : i.y, h = o.x < s.x ? o.x : s.x, p = o.y < s.y ? o.y : s.y, g = o.x > s.x ? o.x : s.x, m = o.y > s.y ? o.y : s.y, d = u > h ? u : h, E = c < g ? c : g, I = l > p ? l : p, C = f < m ? f : m, x = (d + E) / 2, R = (I + C) / 2;
|
|
3419
|
+
a.x = x, a.y = R, r.x -= a.x, r.y -= a.y, i.x -= a.x, i.y -= a.y, o.x -= a.x, o.y -= a.y, s.x -= a.x, s.y -= a.y;
|
|
3420
3420
|
}, t.prototype.computeIntersect = function(r, i, o, s) {
|
|
3421
3421
|
if (this._isProper = !1, !P.intersects(r, i, o, s))
|
|
3422
3422
|
return n.NO_INTERSECTION;
|
|
@@ -3427,7 +3427,7 @@ var sn = function(n) {
|
|
|
3427
3427
|
if (l > 0 && c > 0 || l < 0 && c < 0)
|
|
3428
3428
|
return n.NO_INTERSECTION;
|
|
3429
3429
|
var f = a === 0 && u === 0 && l === 0 && c === 0;
|
|
3430
|
-
return f ? this.computeCollinearIntersection(r, i, o, s) : (a === 0 || u === 0 || l === 0 || c === 0 ? (this._isProper = !1, r.equals2D(o) || r.equals2D(s) ? this._intPt[0] = r : i.equals2D(o) || i.equals2D(s) ? this._intPt[0] = i : a === 0 ? this._intPt[0] = new
|
|
3430
|
+
return f ? this.computeCollinearIntersection(r, i, o, s) : (a === 0 || u === 0 || l === 0 || c === 0 ? (this._isProper = !1, r.equals2D(o) || r.equals2D(s) ? this._intPt[0] = r : i.equals2D(o) || i.equals2D(s) ? this._intPt[0] = i : a === 0 ? this._intPt[0] = new v(o) : u === 0 ? this._intPt[0] = new v(s) : l === 0 ? this._intPt[0] = new v(r) : c === 0 && (this._intPt[0] = new v(i))) : (this._isProper = !0, this._intPt[0] = this.intersection(r, i, o, s)), n.POINT_INTERSECTION);
|
|
3431
3431
|
}, t.prototype.interfaces_ = function() {
|
|
3432
3432
|
return [];
|
|
3433
3433
|
}, t.prototype.getClass = function() {
|
|
@@ -3538,12 +3538,12 @@ Ge.prototype.getClass = function() {
|
|
|
3538
3538
|
return Ge;
|
|
3539
3539
|
};
|
|
3540
3540
|
Ge.locatePointInRing = function() {
|
|
3541
|
-
if (arguments[0] instanceof
|
|
3542
|
-
for (var t = arguments[0], e = arguments[1], r = new Ge(t), i = new
|
|
3541
|
+
if (arguments[0] instanceof v && T(arguments[1], q)) {
|
|
3542
|
+
for (var t = arguments[0], e = arguments[1], r = new Ge(t), i = new v(), o = new v(), s = 1; s < e.size(); s++)
|
|
3543
3543
|
if (e.getCoordinate(s, i), e.getCoordinate(s - 1, o), r.countSegment(i, o), r.isOnSegment())
|
|
3544
3544
|
return r.getLocation();
|
|
3545
3545
|
return r.getLocation();
|
|
3546
|
-
} else if (arguments[0] instanceof
|
|
3546
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof Array) {
|
|
3547
3547
|
for (var a = arguments[0], u = arguments[1], l = new Ge(a), c = 1; c < u.length; c++) {
|
|
3548
3548
|
var f = u[c], h = u[c - 1];
|
|
3549
3549
|
if (l.countSegment(f, h), l.isOnSegment())
|
|
@@ -3577,13 +3577,13 @@ L.signedArea = function() {
|
|
|
3577
3577
|
var u = arguments[0], l = u.size();
|
|
3578
3578
|
if (l < 3)
|
|
3579
3579
|
return 0;
|
|
3580
|
-
var c = new
|
|
3580
|
+
var c = new v(), f = new v(), h = new v();
|
|
3581
3581
|
u.getCoordinate(0, f), u.getCoordinate(1, h);
|
|
3582
|
-
var
|
|
3583
|
-
h.x -=
|
|
3584
|
-
for (var
|
|
3585
|
-
c.y = f.y, f.x = h.x, f.y = h.y, u.getCoordinate(
|
|
3586
|
-
return
|
|
3582
|
+
var p = f.x;
|
|
3583
|
+
h.x -= p;
|
|
3584
|
+
for (var g = 0, m = 1; m < l - 1; m++)
|
|
3585
|
+
c.y = f.y, f.x = h.x, f.y = h.y, u.getCoordinate(m + 1, h), h.x -= p, g += f.x * (c.y - h.y);
|
|
3586
|
+
return g / 2;
|
|
3587
3587
|
}
|
|
3588
3588
|
};
|
|
3589
3589
|
L.distanceLineLine = function(t, e, r, i) {
|
|
@@ -3612,7 +3612,7 @@ L.computeLength = function(t) {
|
|
|
3612
3612
|
var e = t.size();
|
|
3613
3613
|
if (e <= 1)
|
|
3614
3614
|
return 0;
|
|
3615
|
-
var r = 0, i = new
|
|
3615
|
+
var r = 0, i = new v();
|
|
3616
3616
|
t.getCoordinate(0, i);
|
|
3617
3617
|
for (var o = i.x, s = i.y, a = 1; a < e; a++) {
|
|
3618
3618
|
t.getCoordinate(a, i);
|
|
@@ -3713,56 +3713,56 @@ Ir.prototype.interfaces_ = function() {
|
|
|
3713
3713
|
Ir.prototype.getClass = function() {
|
|
3714
3714
|
return Ir;
|
|
3715
3715
|
};
|
|
3716
|
-
var
|
|
3716
|
+
var D = function() {
|
|
3717
3717
|
var t = arguments[0];
|
|
3718
3718
|
this._envelope = null, this._factory = null, this._SRID = null, this._userData = null, this._factory = t, this._SRID = t.getSRID();
|
|
3719
3719
|
}, hr = { serialVersionUID: { configurable: !0 }, SORTINDEX_POINT: { configurable: !0 }, SORTINDEX_MULTIPOINT: { configurable: !0 }, SORTINDEX_LINESTRING: { configurable: !0 }, SORTINDEX_LINEARRING: { configurable: !0 }, SORTINDEX_MULTILINESTRING: { configurable: !0 }, SORTINDEX_POLYGON: { configurable: !0 }, SORTINDEX_MULTIPOLYGON: { configurable: !0 }, SORTINDEX_GEOMETRYCOLLECTION: { configurable: !0 }, geometryChangedFilter: { configurable: !0 } };
|
|
3720
|
-
|
|
3721
|
-
return this.getSortIndex() ===
|
|
3720
|
+
D.prototype.isGeometryCollection = function() {
|
|
3721
|
+
return this.getSortIndex() === D.SORTINDEX_GEOMETRYCOLLECTION;
|
|
3722
3722
|
};
|
|
3723
|
-
|
|
3723
|
+
D.prototype.getFactory = function() {
|
|
3724
3724
|
return this._factory;
|
|
3725
3725
|
};
|
|
3726
|
-
|
|
3726
|
+
D.prototype.getGeometryN = function(t) {
|
|
3727
3727
|
return this;
|
|
3728
3728
|
};
|
|
3729
|
-
|
|
3729
|
+
D.prototype.getArea = function() {
|
|
3730
3730
|
return 0;
|
|
3731
3731
|
};
|
|
3732
|
-
|
|
3732
|
+
D.prototype.isRectangle = function() {
|
|
3733
3733
|
return !1;
|
|
3734
3734
|
};
|
|
3735
|
-
|
|
3736
|
-
if (arguments[0] instanceof
|
|
3735
|
+
D.prototype.equals = function() {
|
|
3736
|
+
if (arguments[0] instanceof D) {
|
|
3737
3737
|
var t = arguments[0];
|
|
3738
3738
|
return t === null ? !1 : this.equalsTopo(t);
|
|
3739
3739
|
} else if (arguments[0] instanceof Object) {
|
|
3740
3740
|
var e = arguments[0];
|
|
3741
|
-
if (!(e instanceof
|
|
3741
|
+
if (!(e instanceof D))
|
|
3742
3742
|
return !1;
|
|
3743
3743
|
var r = e;
|
|
3744
3744
|
return this.equalsExact(r);
|
|
3745
3745
|
}
|
|
3746
3746
|
};
|
|
3747
|
-
|
|
3747
|
+
D.prototype.equalsExact = function(t) {
|
|
3748
3748
|
return this === t || this.equalsExact(t, 0);
|
|
3749
3749
|
};
|
|
3750
|
-
|
|
3751
|
-
this.apply(
|
|
3750
|
+
D.prototype.geometryChanged = function() {
|
|
3751
|
+
this.apply(D.geometryChangedFilter);
|
|
3752
3752
|
};
|
|
3753
|
-
|
|
3753
|
+
D.prototype.geometryChangedAction = function() {
|
|
3754
3754
|
this._envelope = null;
|
|
3755
3755
|
};
|
|
3756
|
-
|
|
3756
|
+
D.prototype.equalsNorm = function(t) {
|
|
3757
3757
|
return t === null ? !1 : this.norm().equalsExact(t.norm());
|
|
3758
3758
|
};
|
|
3759
|
-
|
|
3759
|
+
D.prototype.getLength = function() {
|
|
3760
3760
|
return 0;
|
|
3761
3761
|
};
|
|
3762
|
-
|
|
3762
|
+
D.prototype.getNumGeometries = function() {
|
|
3763
3763
|
return 1;
|
|
3764
3764
|
};
|
|
3765
|
-
|
|
3765
|
+
D.prototype.compareTo = function() {
|
|
3766
3766
|
if (arguments.length === 1) {
|
|
3767
3767
|
var t = arguments[0], e = t;
|
|
3768
3768
|
return this.getSortIndex() !== e.getSortIndex() ? this.getSortIndex() - e.getSortIndex() : this.isEmpty() && e.isEmpty() ? 0 : this.isEmpty() ? -1 : e.isEmpty() ? 1 : this.compareToSameClass(t);
|
|
@@ -3771,39 +3771,39 @@ O.prototype.compareTo = function() {
|
|
|
3771
3771
|
return this.getSortIndex() !== r.getSortIndex() ? this.getSortIndex() - r.getSortIndex() : this.isEmpty() && r.isEmpty() ? 0 : this.isEmpty() ? -1 : r.isEmpty() ? 1 : this.compareToSameClass(r, i);
|
|
3772
3772
|
}
|
|
3773
3773
|
};
|
|
3774
|
-
|
|
3774
|
+
D.prototype.getUserData = function() {
|
|
3775
3775
|
return this._userData;
|
|
3776
3776
|
};
|
|
3777
|
-
|
|
3777
|
+
D.prototype.getSRID = function() {
|
|
3778
3778
|
return this._SRID;
|
|
3779
3779
|
};
|
|
3780
|
-
|
|
3780
|
+
D.prototype.getEnvelope = function() {
|
|
3781
3781
|
return this.getFactory().toGeometry(this.getEnvelopeInternal());
|
|
3782
3782
|
};
|
|
3783
|
-
|
|
3784
|
-
if (t.getSortIndex() ===
|
|
3783
|
+
D.prototype.checkNotGeometryCollection = function(t) {
|
|
3784
|
+
if (t.getSortIndex() === D.SORTINDEX_GEOMETRYCOLLECTION)
|
|
3785
3785
|
throw new it("This method does not support GeometryCollection arguments");
|
|
3786
3786
|
};
|
|
3787
|
-
|
|
3787
|
+
D.prototype.equal = function(t, e, r) {
|
|
3788
3788
|
return r === 0 ? t.equals(e) : t.distance(e) <= r;
|
|
3789
3789
|
};
|
|
3790
|
-
|
|
3790
|
+
D.prototype.norm = function() {
|
|
3791
3791
|
var t = this.copy();
|
|
3792
3792
|
return t.normalize(), t;
|
|
3793
3793
|
};
|
|
3794
|
-
|
|
3794
|
+
D.prototype.getPrecisionModel = function() {
|
|
3795
3795
|
return this._factory.getPrecisionModel();
|
|
3796
3796
|
};
|
|
3797
|
-
|
|
3797
|
+
D.prototype.getEnvelopeInternal = function() {
|
|
3798
3798
|
return this._envelope === null && (this._envelope = this.computeEnvelopeInternal()), new P(this._envelope);
|
|
3799
3799
|
};
|
|
3800
|
-
|
|
3800
|
+
D.prototype.setSRID = function(t) {
|
|
3801
3801
|
this._SRID = t;
|
|
3802
3802
|
};
|
|
3803
|
-
|
|
3803
|
+
D.prototype.setUserData = function(t) {
|
|
3804
3804
|
this._userData = t;
|
|
3805
3805
|
};
|
|
3806
|
-
|
|
3806
|
+
D.prototype.compare = function(t, e) {
|
|
3807
3807
|
for (var r = t.iterator(), i = e.iterator(); r.hasNext() && i.hasNext(); ) {
|
|
3808
3808
|
var o = r.next(), s = i.next(), a = o.compareTo(s);
|
|
3809
3809
|
if (a !== 0)
|
|
@@ -3811,25 +3811,25 @@ O.prototype.compare = function(t, e) {
|
|
|
3811
3811
|
}
|
|
3812
3812
|
return r.hasNext() ? 1 : i.hasNext() ? -1 : 0;
|
|
3813
3813
|
};
|
|
3814
|
-
|
|
3814
|
+
D.prototype.hashCode = function() {
|
|
3815
3815
|
return this.getEnvelopeInternal().hashCode();
|
|
3816
3816
|
};
|
|
3817
|
-
|
|
3818
|
-
return this.getSortIndex() ===
|
|
3817
|
+
D.prototype.isGeometryCollectionOrDerived = function() {
|
|
3818
|
+
return this.getSortIndex() === D.SORTINDEX_GEOMETRYCOLLECTION || this.getSortIndex() === D.SORTINDEX_MULTIPOINT || this.getSortIndex() === D.SORTINDEX_MULTILINESTRING || this.getSortIndex() === D.SORTINDEX_MULTIPOLYGON;
|
|
3819
3819
|
};
|
|
3820
|
-
|
|
3820
|
+
D.prototype.interfaces_ = function() {
|
|
3821
3821
|
return [io, Ee, Ie];
|
|
3822
3822
|
};
|
|
3823
|
-
|
|
3824
|
-
return
|
|
3823
|
+
D.prototype.getClass = function() {
|
|
3824
|
+
return D;
|
|
3825
3825
|
};
|
|
3826
|
-
|
|
3826
|
+
D.hasNonEmptyElements = function(t) {
|
|
3827
3827
|
for (var e = 0; e < t.length; e++)
|
|
3828
3828
|
if (!t[e].isEmpty())
|
|
3829
3829
|
return !0;
|
|
3830
3830
|
return !1;
|
|
3831
3831
|
};
|
|
3832
|
-
|
|
3832
|
+
D.hasNullElements = function(t) {
|
|
3833
3833
|
for (var e = 0; e < t.length; e++)
|
|
3834
3834
|
if (t[e] === null)
|
|
3835
3835
|
return !0;
|
|
@@ -3865,7 +3865,7 @@ hr.SORTINDEX_GEOMETRYCOLLECTION.get = function() {
|
|
|
3865
3865
|
hr.geometryChangedFilter.get = function() {
|
|
3866
3866
|
return zo;
|
|
3867
3867
|
};
|
|
3868
|
-
Object.defineProperties(
|
|
3868
|
+
Object.defineProperties(D, hr);
|
|
3869
3869
|
var zo = function() {
|
|
3870
3870
|
};
|
|
3871
3871
|
zo.interfaces_ = function() {
|
|
@@ -4009,7 +4009,7 @@ function ei(n) {
|
|
|
4009
4009
|
}
|
|
4010
4010
|
ei.prototype = new Error();
|
|
4011
4011
|
ei.prototype.name = "NoSuchElementException";
|
|
4012
|
-
var
|
|
4012
|
+
var S = function(n) {
|
|
4013
4013
|
function t() {
|
|
4014
4014
|
n.call(this), this.array_ = [], arguments[0] instanceof _t && this.addAll(arguments[0]);
|
|
4015
4015
|
}
|
|
@@ -4105,7 +4105,7 @@ var x = function(n) {
|
|
|
4105
4105
|
if (arguments[0] instanceof Array && typeof arguments[1] == "boolean") {
|
|
4106
4106
|
var s = arguments[0], a = arguments[1];
|
|
4107
4107
|
return this.add(s, a, !0), !0;
|
|
4108
|
-
} else if (arguments[0] instanceof
|
|
4108
|
+
} else if (arguments[0] instanceof v && typeof arguments[1] == "boolean") {
|
|
4109
4109
|
var u = arguments[0], l = arguments[1];
|
|
4110
4110
|
if (!l && this.size() >= 1) {
|
|
4111
4111
|
var c = this.get(this.size() - 1);
|
|
@@ -4119,25 +4119,25 @@ var x = function(n) {
|
|
|
4119
4119
|
}
|
|
4120
4120
|
} else if (arguments.length === 3) {
|
|
4121
4121
|
if (typeof arguments[2] == "boolean" && arguments[0] instanceof Array && typeof arguments[1] == "boolean") {
|
|
4122
|
-
var
|
|
4123
|
-
if (
|
|
4124
|
-
for (var
|
|
4125
|
-
i.add(
|
|
4122
|
+
var p = arguments[0], g = arguments[1], m = arguments[2];
|
|
4123
|
+
if (m)
|
|
4124
|
+
for (var d = 0; d < p.length; d++)
|
|
4125
|
+
i.add(p[d], g);
|
|
4126
4126
|
else
|
|
4127
|
-
for (var E =
|
|
4128
|
-
i.add(
|
|
4127
|
+
for (var E = p.length - 1; E >= 0; E--)
|
|
4128
|
+
i.add(p[E], g);
|
|
4129
4129
|
return !0;
|
|
4130
|
-
} else if (typeof arguments[2] == "boolean" && Number.isInteger(arguments[0]) && arguments[1] instanceof
|
|
4131
|
-
var I = arguments[0], C = arguments[1],
|
|
4132
|
-
if (!
|
|
4133
|
-
var
|
|
4134
|
-
if (
|
|
4130
|
+
} else if (typeof arguments[2] == "boolean" && Number.isInteger(arguments[0]) && arguments[1] instanceof v) {
|
|
4131
|
+
var I = arguments[0], C = arguments[1], x = arguments[2];
|
|
4132
|
+
if (!x) {
|
|
4133
|
+
var R = this.size();
|
|
4134
|
+
if (R > 0) {
|
|
4135
4135
|
if (I > 0) {
|
|
4136
|
-
var
|
|
4137
|
-
if (
|
|
4136
|
+
var O = this.get(I - 1);
|
|
4137
|
+
if (O.equals2D(C))
|
|
4138
4138
|
return null;
|
|
4139
4139
|
}
|
|
4140
|
-
if (I <
|
|
4140
|
+
if (I < R) {
|
|
4141
4141
|
var F = this.get(I);
|
|
4142
4142
|
if (F.equals2D(C))
|
|
4143
4143
|
return null;
|
|
@@ -4154,13 +4154,13 @@ var x = function(n) {
|
|
|
4154
4154
|
return !0;
|
|
4155
4155
|
}
|
|
4156
4156
|
}, t.prototype.closeRing = function() {
|
|
4157
|
-
this.size() > 0 && this.add(new
|
|
4157
|
+
this.size() > 0 && this.add(new v(this.get(0)), !1);
|
|
4158
4158
|
}, t.prototype.interfaces_ = function() {
|
|
4159
4159
|
return [];
|
|
4160
4160
|
}, t.prototype.getClass = function() {
|
|
4161
4161
|
return t;
|
|
4162
4162
|
}, Object.defineProperties(t, e), t;
|
|
4163
|
-
}(
|
|
4163
|
+
}(S), z = function() {
|
|
4164
4164
|
}, so = { ForwardComparator: { configurable: !0 }, BidirectionalComparator: { configurable: !0 }, coordArrayType: { configurable: !0 } };
|
|
4165
4165
|
so.ForwardComparator.get = function() {
|
|
4166
4166
|
return gi;
|
|
@@ -4254,11 +4254,11 @@ z.removeNull = function(t) {
|
|
|
4254
4254
|
z.copyDeep = function() {
|
|
4255
4255
|
if (arguments.length === 1) {
|
|
4256
4256
|
for (var t = arguments[0], e = new Array(t.length).fill(null), r = 0; r < t.length; r++)
|
|
4257
|
-
e[r] = new
|
|
4257
|
+
e[r] = new v(t[r]);
|
|
4258
4258
|
return e;
|
|
4259
4259
|
} else if (arguments.length === 5)
|
|
4260
4260
|
for (var i = arguments[0], o = arguments[1], s = arguments[2], a = arguments[3], u = arguments[4], l = 0; l < u; l++)
|
|
4261
|
-
s[a + l] = new
|
|
4261
|
+
s[a + l] = new v(i[o + l]);
|
|
4262
4262
|
};
|
|
4263
4263
|
z.isEqualReversed = function(t, e) {
|
|
4264
4264
|
for (var r = 0; r < t.length; r++) {
|
|
@@ -4525,7 +4525,7 @@ At.prototype.fixAfterInsertion = function(n) {
|
|
|
4525
4525
|
this.root_.color = yr;
|
|
4526
4526
|
};
|
|
4527
4527
|
At.prototype.values = function() {
|
|
4528
|
-
var n = new
|
|
4528
|
+
var n = new S(), t = this.getFirstEntry();
|
|
4529
4529
|
if (t !== null)
|
|
4530
4530
|
for (n.add(t.value); (t = At.successor(t)) !== null; )
|
|
4531
4531
|
n.add(t.value);
|
|
@@ -4667,7 +4667,7 @@ Wr.sort = function() {
|
|
|
4667
4667
|
t.push(s[e]);
|
|
4668
4668
|
};
|
|
4669
4669
|
Wr.asList = function(t) {
|
|
4670
|
-
for (var e = new
|
|
4670
|
+
for (var e = new S(), r = 0, i = t.length; r < i; r++)
|
|
4671
4671
|
e.add(t[r]);
|
|
4672
4672
|
return e;
|
|
4673
4673
|
};
|
|
@@ -4847,13 +4847,13 @@ var Xt = function(n) {
|
|
|
4847
4847
|
var o = arguments[0], s = new ze(Wr.asList(this._geometries)), a = new ze(Wr.asList(o._geometries));
|
|
4848
4848
|
return this.compare(s, a);
|
|
4849
4849
|
} else if (arguments.length === 2) {
|
|
4850
|
-
for (var u = arguments[0], l = arguments[1], c = u, f = this.getNumGeometries(), h = c.getNumGeometries(),
|
|
4851
|
-
var
|
|
4852
|
-
if (
|
|
4853
|
-
return
|
|
4854
|
-
|
|
4850
|
+
for (var u = arguments[0], l = arguments[1], c = u, f = this.getNumGeometries(), h = c.getNumGeometries(), p = 0; p < f && p < h; ) {
|
|
4851
|
+
var g = i.getGeometryN(p), m = c.getGeometryN(p), d = g.compareToSameClass(m, l);
|
|
4852
|
+
if (d !== 0)
|
|
4853
|
+
return d;
|
|
4854
|
+
p++;
|
|
4855
4855
|
}
|
|
4856
|
-
return
|
|
4856
|
+
return p < f ? 1 : p < h ? -1 : 0;
|
|
4857
4857
|
}
|
|
4858
4858
|
}, t.prototype.apply = function() {
|
|
4859
4859
|
var i = this;
|
|
@@ -4904,14 +4904,14 @@ var Xt = function(n) {
|
|
|
4904
4904
|
}, e.serialVersionUID.get = function() {
|
|
4905
4905
|
return -5694727726395021e3;
|
|
4906
4906
|
}, Object.defineProperties(t, e), t;
|
|
4907
|
-
}(
|
|
4907
|
+
}(D), Qr = function(n) {
|
|
4908
4908
|
function t() {
|
|
4909
4909
|
n.apply(this, arguments);
|
|
4910
4910
|
}
|
|
4911
4911
|
n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t;
|
|
4912
4912
|
var e = { serialVersionUID: { configurable: !0 } };
|
|
4913
4913
|
return t.prototype.getSortIndex = function() {
|
|
4914
|
-
return
|
|
4914
|
+
return D.SORTINDEX_MULTILINESTRING;
|
|
4915
4915
|
}, t.prototype.equalsExact = function() {
|
|
4916
4916
|
if (arguments.length === 2) {
|
|
4917
4917
|
var i = arguments[0], o = arguments[1];
|
|
@@ -4980,7 +4980,7 @@ ge.prototype.getEmptyMultiPoint = function() {
|
|
|
4980
4980
|
return this._geomFact.createMultiPoint();
|
|
4981
4981
|
};
|
|
4982
4982
|
ge.prototype.computeBoundaryCoordinates = function(t) {
|
|
4983
|
-
var e = this, r = new
|
|
4983
|
+
var e = this, r = new S();
|
|
4984
4984
|
this._endpointMap = new At();
|
|
4985
4985
|
for (var i = 0; i < t.getNumGeometries(); i++) {
|
|
4986
4986
|
var o = t.getGeometryN(i);
|
|
@@ -5066,7 +5066,7 @@ de.getStackTrace = function() {
|
|
|
5066
5066
|
}
|
|
5067
5067
|
};
|
|
5068
5068
|
de.split = function(t, e) {
|
|
5069
|
-
for (var r = e.length, i = new
|
|
5069
|
+
for (var r = e.length, i = new S(), o = "" + t, s = o.indexOf(e); s >= 0; ) {
|
|
5070
5070
|
var a = o.substring(0, s);
|
|
5071
5071
|
i.add(a), o = o.substring(s + r), s = o.indexOf(e);
|
|
5072
5072
|
}
|
|
@@ -5297,7 +5297,7 @@ var ut = function(n) {
|
|
|
5297
5297
|
}, e.serialVersionUID.get = function() {
|
|
5298
5298
|
return 3110669828065365500;
|
|
5299
5299
|
}, Object.defineProperties(t, e), t;
|
|
5300
|
-
}(
|
|
5300
|
+
}(D), vi = function() {
|
|
5301
5301
|
};
|
|
5302
5302
|
vi.prototype.interfaces_ = function() {
|
|
5303
5303
|
return [];
|
|
@@ -5395,7 +5395,7 @@ var te = function(n) {
|
|
|
5395
5395
|
}, e.serialVersionUID.get = function() {
|
|
5396
5396
|
return 4902022702746615e3;
|
|
5397
5397
|
}, Object.defineProperties(t, e), t;
|
|
5398
|
-
}(
|
|
5398
|
+
}(D), Tr = function() {
|
|
5399
5399
|
};
|
|
5400
5400
|
Tr.prototype.interfaces_ = function() {
|
|
5401
5401
|
return [];
|
|
@@ -5445,10 +5445,10 @@ var Nt = function(n) {
|
|
|
5445
5445
|
return !1;
|
|
5446
5446
|
}
|
|
5447
5447
|
for (var l = i.getX(0), c = i.getY(0), f = 1; f <= 4; f++) {
|
|
5448
|
-
var h = i.getX(f),
|
|
5449
|
-
if (
|
|
5448
|
+
var h = i.getX(f), p = i.getY(f), g = h !== l, m = p !== c;
|
|
5449
|
+
if (g === m)
|
|
5450
5450
|
return !1;
|
|
5451
|
-
l = h, c =
|
|
5451
|
+
l = h, c = p;
|
|
5452
5452
|
}
|
|
5453
5453
|
return !0;
|
|
5454
5454
|
}, t.prototype.equalsExact = function() {
|
|
@@ -5514,16 +5514,16 @@ var Nt = function(n) {
|
|
|
5514
5514
|
var o = arguments[0], s = this._shell, a = o._shell;
|
|
5515
5515
|
return s.compareToSameClass(a);
|
|
5516
5516
|
} else if (arguments.length === 2) {
|
|
5517
|
-
var u = arguments[0], l = arguments[1], c = u, f = this._shell, h = c._shell,
|
|
5518
|
-
if (
|
|
5519
|
-
return
|
|
5520
|
-
for (var
|
|
5521
|
-
var E = i.getInteriorRingN(
|
|
5517
|
+
var u = arguments[0], l = arguments[1], c = u, f = this._shell, h = c._shell, p = f.compareToSameClass(h, l);
|
|
5518
|
+
if (p !== 0)
|
|
5519
|
+
return p;
|
|
5520
|
+
for (var g = this.getNumInteriorRing(), m = c.getNumInteriorRing(), d = 0; d < g && d < m; ) {
|
|
5521
|
+
var E = i.getInteriorRingN(d), I = c.getInteriorRingN(d), C = E.compareToSameClass(I, l);
|
|
5522
5522
|
if (C !== 0)
|
|
5523
5523
|
return C;
|
|
5524
|
-
|
|
5524
|
+
d++;
|
|
5525
5525
|
}
|
|
5526
|
-
return
|
|
5526
|
+
return d < g ? 1 : d < m ? -1 : 0;
|
|
5527
5527
|
}
|
|
5528
5528
|
}, t.prototype.apply = function(i) {
|
|
5529
5529
|
var o = this;
|
|
@@ -5577,14 +5577,14 @@ var Nt = function(n) {
|
|
|
5577
5577
|
}, e.serialVersionUID.get = function() {
|
|
5578
5578
|
return -3494792200821764600;
|
|
5579
5579
|
}, Object.defineProperties(t, e), t;
|
|
5580
|
-
}(
|
|
5580
|
+
}(D), Vn = function(n) {
|
|
5581
5581
|
function t() {
|
|
5582
5582
|
n.apply(this, arguments);
|
|
5583
5583
|
}
|
|
5584
5584
|
n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t;
|
|
5585
5585
|
var e = { serialVersionUID: { configurable: !0 } };
|
|
5586
5586
|
return t.prototype.getSortIndex = function() {
|
|
5587
|
-
return
|
|
5587
|
+
return D.SORTINDEX_MULTIPOINT;
|
|
5588
5588
|
}, t.prototype.isValid = function() {
|
|
5589
5589
|
return !0;
|
|
5590
5590
|
}, t.prototype.equalsExact = function() {
|
|
@@ -5620,12 +5620,12 @@ var Nt = function(n) {
|
|
|
5620
5620
|
}, Object.defineProperties(t, e), t;
|
|
5621
5621
|
}(Xt), ir = function(n) {
|
|
5622
5622
|
function t(r, i) {
|
|
5623
|
-
r instanceof
|
|
5623
|
+
r instanceof v && i instanceof k && (r = i.getCoordinateSequenceFactory().create(r)), n.call(this, r, i), this.validateConstruction();
|
|
5624
5624
|
}
|
|
5625
5625
|
n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t;
|
|
5626
5626
|
var e = { MINIMUM_VALID_SIZE: { configurable: !0 }, serialVersionUID: { configurable: !0 } };
|
|
5627
5627
|
return t.prototype.getSortIndex = function() {
|
|
5628
|
-
return
|
|
5628
|
+
return D.SORTINDEX_LINEARRING;
|
|
5629
5629
|
}, t.prototype.getBoundaryDimension = function() {
|
|
5630
5630
|
return Y.FALSE;
|
|
5631
5631
|
}, t.prototype.isClosed = function() {
|
|
@@ -5660,7 +5660,7 @@ var Nt = function(n) {
|
|
|
5660
5660
|
n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t;
|
|
5661
5661
|
var e = { serialVersionUID: { configurable: !0 } };
|
|
5662
5662
|
return t.prototype.getSortIndex = function() {
|
|
5663
|
-
return
|
|
5663
|
+
return D.SORTINDEX_MULTIPOLYGON;
|
|
5664
5664
|
}, t.prototype.equalsExact = function() {
|
|
5665
5665
|
if (arguments.length === 2) {
|
|
5666
5666
|
var i = arguments[0], o = arguments[1];
|
|
@@ -5679,7 +5679,7 @@ var Nt = function(n) {
|
|
|
5679
5679
|
var i = this;
|
|
5680
5680
|
if (this.isEmpty())
|
|
5681
5681
|
return this.getFactory().createMultiLineString();
|
|
5682
|
-
for (var o = new
|
|
5682
|
+
for (var o = new S(), s = 0; s < this._geometries.length; s++)
|
|
5683
5683
|
for (var a = i._geometries[s], u = a.getBoundary(), l = 0; l < u.getNumGeometries(); l++)
|
|
5684
5684
|
o.add(u.getGeometryN(l));
|
|
5685
5685
|
var c = new Array(o.size()).fill(null);
|
|
@@ -5713,7 +5713,7 @@ me.prototype.editInternal = function(t, e) {
|
|
|
5713
5713
|
return this._factory === null && (this._factory = t.getFactory()), t instanceof Xt ? this.editGeometryCollection(t, e) : t instanceof Nt ? this.editPolygon(t, e) : t instanceof te ? e.edit(t, this._factory) : t instanceof ut ? e.edit(t, this._factory) : (V.shouldNeverReachHere("Unsupported Geometry class: " + t.getClass().getName()), null);
|
|
5714
5714
|
};
|
|
5715
5715
|
me.prototype.editGeometryCollection = function(t, e) {
|
|
5716
|
-
for (var r = this, i = e.edit(t, this._factory), o = new
|
|
5716
|
+
for (var r = this, i = e.edit(t, this._factory), o = new S(), s = 0; s < i.getNumGeometries(); s++) {
|
|
5717
5717
|
var a = r.edit(i.getGeometryN(s), e);
|
|
5718
5718
|
a === null || a.isEmpty() || o.add(a);
|
|
5719
5719
|
}
|
|
@@ -5726,7 +5726,7 @@ me.prototype.editPolygon = function(t, e) {
|
|
|
5726
5726
|
var o = this.edit(i.getExteriorRing(), e);
|
|
5727
5727
|
if (o === null || o.isEmpty())
|
|
5728
5728
|
return this._factory.createPolygon();
|
|
5729
|
-
for (var s = new
|
|
5729
|
+
for (var s = new S(), a = 0; a < i.getNumInteriorRing(); a++) {
|
|
5730
5730
|
var u = r.edit(i.getInteriorRingN(a), e);
|
|
5731
5731
|
u === null || u.isEmpty() || s.add(u);
|
|
5732
5732
|
}
|
|
@@ -5793,7 +5793,7 @@ var ht = function() {
|
|
|
5793
5793
|
var e = arguments[0];
|
|
5794
5794
|
this._coordinates = new Array(e).fill(null);
|
|
5795
5795
|
for (var r = 0; r < e; r++)
|
|
5796
|
-
t._coordinates[r] = new
|
|
5796
|
+
t._coordinates[r] = new v();
|
|
5797
5797
|
} else if (T(arguments[0], q)) {
|
|
5798
5798
|
var i = arguments[0];
|
|
5799
5799
|
if (i === null)
|
|
@@ -5810,7 +5810,7 @@ var ht = function() {
|
|
|
5810
5810
|
var u = arguments[0], l = arguments[1];
|
|
5811
5811
|
this._coordinates = new Array(u).fill(null), this._dimension = l;
|
|
5812
5812
|
for (var c = 0; c < u; c++)
|
|
5813
|
-
t._coordinates[c] = new
|
|
5813
|
+
t._coordinates[c] = new v();
|
|
5814
5814
|
}
|
|
5815
5815
|
}
|
|
5816
5816
|
}, oa = { serialVersionUID: { configurable: !0 } };
|
|
@@ -5853,7 +5853,7 @@ ht.prototype.getCoordinate = function() {
|
|
|
5853
5853
|
}
|
|
5854
5854
|
};
|
|
5855
5855
|
ht.prototype.getCoordinateCopy = function(t) {
|
|
5856
|
-
return new
|
|
5856
|
+
return new v(this._coordinates[t]);
|
|
5857
5857
|
};
|
|
5858
5858
|
ht.prototype.getDimension = function() {
|
|
5859
5859
|
return this._dimension;
|
|
@@ -5947,7 +5947,7 @@ var sa = function(n) {
|
|
|
5947
5947
|
}, t.prototype.put = function(r, i) {
|
|
5948
5948
|
return this.map_.set(r, i), i;
|
|
5949
5949
|
}, t.prototype.values = function() {
|
|
5950
|
-
for (var r = new
|
|
5950
|
+
for (var r = new S(), i = this.map_.values(), o = i.next(); !o.done; )
|
|
5951
5951
|
r.add(o.value), o = i.next();
|
|
5952
5952
|
return r;
|
|
5953
5953
|
}, t.prototype.entrySet = function() {
|
|
@@ -6007,7 +6007,7 @@ W.prototype.makePrecise = function() {
|
|
|
6007
6007
|
return e;
|
|
6008
6008
|
}
|
|
6009
6009
|
return this._modelType === W.FIXED ? Math.round(t * this._scale) / this._scale : t;
|
|
6010
|
-
} else if (arguments[0] instanceof
|
|
6010
|
+
} else if (arguments[0] instanceof v) {
|
|
6011
6011
|
var r = arguments[0];
|
|
6012
6012
|
if (this._modelType === W.FLOATING)
|
|
6013
6013
|
return null;
|
|
@@ -6067,7 +6067,7 @@ var k = function n() {
|
|
|
6067
6067
|
this._precisionModel = new W(), this._SRID = 0, this._coordinateSequenceFactory = n.getDefaultCoordinateSequenceFactory(), arguments.length === 0 || (arguments.length === 1 ? T(arguments[0], Tn) ? this._coordinateSequenceFactory = arguments[0] : arguments[0] instanceof W && (this._precisionModel = arguments[0]) : arguments.length === 2 ? (this._precisionModel = arguments[0], this._SRID = arguments[1]) : arguments.length === 3 && (this._precisionModel = arguments[0], this._SRID = arguments[1], this._coordinateSequenceFactory = arguments[2]));
|
|
6068
6068
|
}, aa = { serialVersionUID: { configurable: !0 } };
|
|
6069
6069
|
k.prototype.toGeometry = function(t) {
|
|
6070
|
-
return t.isNull() ? this.createPoint(null) : t.getMinX() === t.getMaxX() && t.getMinY() === t.getMaxY() ? this.createPoint(new
|
|
6070
|
+
return t.isNull() ? this.createPoint(null) : t.getMinX() === t.getMaxX() && t.getMinY() === t.getMaxY() ? this.createPoint(new v(t.getMinX(), t.getMinY())) : t.getMinX() === t.getMaxX() || t.getMinY() === t.getMaxY() ? this.createLineString([new v(t.getMinX(), t.getMinY()), new v(t.getMaxX(), t.getMaxY())]) : this.createPolygon(this.createLinearRing([new v(t.getMinX(), t.getMinY()), new v(t.getMinX(), t.getMaxY()), new v(t.getMaxX(), t.getMaxY()), new v(t.getMaxX(), t.getMinY()), new v(t.getMinX(), t.getMinY())]), null);
|
|
6071
6071
|
};
|
|
6072
6072
|
k.prototype.createLineString = function(t) {
|
|
6073
6073
|
if (t) {
|
|
@@ -6114,7 +6114,7 @@ k.prototype.createPoint = function() {
|
|
|
6114
6114
|
if (arguments.length === 0)
|
|
6115
6115
|
return this.createPoint(this.getCoordinateSequenceFactory().create([]));
|
|
6116
6116
|
if (arguments.length === 1) {
|
|
6117
|
-
if (arguments[0] instanceof
|
|
6117
|
+
if (arguments[0] instanceof v) {
|
|
6118
6118
|
var t = arguments[0];
|
|
6119
6119
|
return this.createPoint(t !== null ? this.getCoordinateSequenceFactory().create([t]) : null);
|
|
6120
6120
|
} else if (T(arguments[0], q)) {
|
|
@@ -6330,7 +6330,7 @@ var Fe = {
|
|
|
6330
6330
|
coordinates: function(n) {
|
|
6331
6331
|
for (var t = [], e = 0; e < n.length; ++e) {
|
|
6332
6332
|
var r = n[e];
|
|
6333
|
-
t.push(new
|
|
6333
|
+
t.push(new v(r[0], r[1]));
|
|
6334
6334
|
}
|
|
6335
6335
|
return t;
|
|
6336
6336
|
},
|
|
@@ -6344,11 +6344,11 @@ var Fe = {
|
|
|
6344
6344
|
*/
|
|
6345
6345
|
bbox: function(n) {
|
|
6346
6346
|
return this.geometryFactory.createLinearRing([
|
|
6347
|
-
new
|
|
6348
|
-
new
|
|
6349
|
-
new
|
|
6350
|
-
new
|
|
6351
|
-
new
|
|
6347
|
+
new v(n[0], n[1]),
|
|
6348
|
+
new v(n[2], n[1]),
|
|
6349
|
+
new v(n[2], n[3]),
|
|
6350
|
+
new v(n[0], n[3]),
|
|
6351
|
+
new v(n[0], n[1])
|
|
6352
6352
|
]);
|
|
6353
6353
|
},
|
|
6354
6354
|
/**
|
|
@@ -6360,7 +6360,7 @@ var Fe = {
|
|
|
6360
6360
|
* @return {Point} Point.
|
|
6361
6361
|
*/
|
|
6362
6362
|
Point: function(n) {
|
|
6363
|
-
var t = new
|
|
6363
|
+
var t = new v(n[0], n[1]);
|
|
6364
6364
|
return this.geometryFactory.createPoint(t);
|
|
6365
6365
|
},
|
|
6366
6366
|
/**
|
|
@@ -6726,7 +6726,7 @@ Xe.prototype.getClass = function() {
|
|
|
6726
6726
|
};
|
|
6727
6727
|
var Cr = function(n) {
|
|
6728
6728
|
function t(e, r) {
|
|
6729
|
-
n.call(this, t.msgWithCoord(e, r)), this.pt = r ? new
|
|
6729
|
+
n.call(this, t.msgWithCoord(e, r)), this.pt = r ? new v(r) : null, this.name = "TopologyException";
|
|
6730
6730
|
}
|
|
6731
6731
|
return n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t, t.prototype.getCoordinate = function() {
|
|
6732
6732
|
return this.pt;
|
|
@@ -6750,7 +6750,7 @@ po.prototype.isEmpty = function() {
|
|
|
6750
6750
|
return this.array_.length === 0;
|
|
6751
6751
|
};
|
|
6752
6752
|
var Yt = function() {
|
|
6753
|
-
this._finder = null, this._dirEdgeList = new
|
|
6753
|
+
this._finder = null, this._dirEdgeList = new S(), this._nodes = new S(), this._rightMostCoord = null, this._env = null, this._finder = new Xe();
|
|
6754
6754
|
};
|
|
6755
6755
|
Yt.prototype.clearVisitedEdges = function() {
|
|
6756
6756
|
for (var t = this._dirEdgeList.iterator(); t.hasNext(); ) {
|
|
@@ -7055,7 +7055,7 @@ Q.toLineLabel = function(t) {
|
|
|
7055
7055
|
return e;
|
|
7056
7056
|
};
|
|
7057
7057
|
var mt = function() {
|
|
7058
|
-
this._startDe = null, this._maxNodeDegree = -1, this._edges = new
|
|
7058
|
+
this._startDe = null, this._maxNodeDegree = -1, this._edges = new S(), this._pts = new S(), this._label = new Q(y.NONE), this._ring = null, this._isHole = null, this._shell = null, this._holes = new S(), this._geometryFactory = null;
|
|
7059
7059
|
var t = arguments[0], e = arguments[1];
|
|
7060
7060
|
this._geometryFactory = e, this.computePoints(t), this.computeRing();
|
|
7061
7061
|
};
|
|
@@ -7199,7 +7199,7 @@ var Hu = function(n) {
|
|
|
7199
7199
|
n.call(this, e, r);
|
|
7200
7200
|
}
|
|
7201
7201
|
return n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t, t.prototype.buildMinimalRings = function() {
|
|
7202
|
-
var r = this, i = new
|
|
7202
|
+
var r = this, i = new S(), o = this._startDe;
|
|
7203
7203
|
do {
|
|
7204
7204
|
if (o.getMinEdgeRing() === null) {
|
|
7205
7205
|
var s = new Hu(o, r._geometryFactory);
|
|
@@ -7346,7 +7346,7 @@ Ye.prototype.find = function(t) {
|
|
|
7346
7346
|
return this.nodeMap.get(t);
|
|
7347
7347
|
};
|
|
7348
7348
|
Ye.prototype.addNode = function() {
|
|
7349
|
-
if (arguments[0] instanceof
|
|
7349
|
+
if (arguments[0] instanceof v) {
|
|
7350
7350
|
var t = arguments[0], e = this.nodeMap.get(t);
|
|
7351
7351
|
return e === null && (e = this.nodeFact.createNode(t), this.nodeMap.put(t, e)), e;
|
|
7352
7352
|
} else if (arguments[0] instanceof go) {
|
|
@@ -7367,7 +7367,7 @@ Ye.prototype.values = function() {
|
|
|
7367
7367
|
return this.nodeMap.values();
|
|
7368
7368
|
};
|
|
7369
7369
|
Ye.prototype.getBoundaryNodes = function(t) {
|
|
7370
|
-
for (var e = new
|
|
7370
|
+
for (var e = new S(), r = this.iterator(); r.hasNext(); ) {
|
|
7371
7371
|
var i = r.next();
|
|
7372
7372
|
i.getLabel().getLocation(t) === y.BOUNDARY && e.add(i);
|
|
7373
7373
|
}
|
|
@@ -7418,7 +7418,7 @@ J.quadrant = function() {
|
|
|
7418
7418
|
if (t === 0 && e === 0)
|
|
7419
7419
|
throw new it("Cannot compute the quadrant for point ( " + t + ", " + e + " )");
|
|
7420
7420
|
return t >= 0 ? e >= 0 ? J.NE : J.SE : e >= 0 ? J.NW : J.SW;
|
|
7421
|
-
} else if (arguments[0] instanceof
|
|
7421
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof v) {
|
|
7422
7422
|
var r = arguments[0], i = arguments[1];
|
|
7423
7423
|
if (i.x === r.x && i.y === r.y)
|
|
7424
7424
|
throw new it("Cannot compute the quadrant for two identical points " + r);
|
|
@@ -7596,7 +7596,7 @@ kn.prototype.getClass = function() {
|
|
|
7596
7596
|
return kn;
|
|
7597
7597
|
};
|
|
7598
7598
|
var st = function() {
|
|
7599
|
-
if (this._edges = new
|
|
7599
|
+
if (this._edges = new S(), this._nodes = null, this._edgeEndList = new S(), arguments.length === 0)
|
|
7600
7600
|
this._nodes = new Ye(new kn());
|
|
7601
7601
|
else if (arguments.length === 1) {
|
|
7602
7602
|
var t = arguments[0];
|
|
@@ -7619,7 +7619,7 @@ st.prototype.addNode = function() {
|
|
|
7619
7619
|
if (arguments[0] instanceof go) {
|
|
7620
7620
|
var t = arguments[0];
|
|
7621
7621
|
return this._nodes.addNode(t);
|
|
7622
|
-
} else if (arguments[0] instanceof
|
|
7622
|
+
} else if (arguments[0] instanceof v) {
|
|
7623
7623
|
var e = arguments[0];
|
|
7624
7624
|
return this._nodes.addNode(e);
|
|
7625
7625
|
}
|
|
@@ -7715,7 +7715,7 @@ st.linkResultDirectedEdges = function(t) {
|
|
|
7715
7715
|
}
|
|
7716
7716
|
};
|
|
7717
7717
|
var ee = function() {
|
|
7718
|
-
this._geometryFactory = null, this._shellList = new
|
|
7718
|
+
this._geometryFactory = null, this._shellList = new S();
|
|
7719
7719
|
var t = arguments[0];
|
|
7720
7720
|
this._geometryFactory = t;
|
|
7721
7721
|
};
|
|
@@ -7726,7 +7726,7 @@ ee.prototype.sortShellsAndHoles = function(t, e, r) {
|
|
|
7726
7726
|
}
|
|
7727
7727
|
};
|
|
7728
7728
|
ee.prototype.computePolygons = function(t) {
|
|
7729
|
-
for (var e = this, r = new
|
|
7729
|
+
for (var e = this, r = new S(), i = t.iterator(); i.hasNext(); ) {
|
|
7730
7730
|
var o = i.next(), s = o.toPolygon(e._geometryFactory);
|
|
7731
7731
|
r.add(s);
|
|
7732
7732
|
}
|
|
@@ -7744,7 +7744,7 @@ ee.prototype.placeFreeHoles = function(t, e) {
|
|
|
7744
7744
|
}
|
|
7745
7745
|
};
|
|
7746
7746
|
ee.prototype.buildMinimalEdgeRings = function(t, e, r) {
|
|
7747
|
-
for (var i = this, o = new
|
|
7747
|
+
for (var i = this, o = new S(), s = t.iterator(); s.hasNext(); ) {
|
|
7748
7748
|
var a = s.next();
|
|
7749
7749
|
if (a.getMaxNodeDegree() > 2) {
|
|
7750
7750
|
a.linkDirectedEdgesForMinimalEdgeRings();
|
|
@@ -7764,7 +7764,7 @@ ee.prototype.containsPoint = function(t) {
|
|
|
7764
7764
|
return !1;
|
|
7765
7765
|
};
|
|
7766
7766
|
ee.prototype.buildMaximalEdgeRings = function(t) {
|
|
7767
|
-
for (var e = this, r = new
|
|
7767
|
+
for (var e = this, r = new S(), i = t.iterator(); i.hasNext(); ) {
|
|
7768
7768
|
var o = i.next();
|
|
7769
7769
|
if (o.isInResult() && o.getLabel().isArea() && o.getEdgeRing() === null) {
|
|
7770
7770
|
var s = new Wu(o, e._geometryFactory);
|
|
@@ -7806,7 +7806,7 @@ ee.prototype.add = function() {
|
|
|
7806
7806
|
} else if (arguments.length === 2) {
|
|
7807
7807
|
var e = arguments[0], r = arguments[1];
|
|
7808
7808
|
st.linkResultDirectedEdges(r);
|
|
7809
|
-
var i = this.buildMaximalEdgeRings(e), o = new
|
|
7809
|
+
var i = this.buildMaximalEdgeRings(e), o = new S(), s = this.buildMinimalEdgeRings(i, this._shellList, o);
|
|
7810
7810
|
this.sortShellsAndHoles(s, this._shellList, o), this.placeFreeHoles(this._shellList, o);
|
|
7811
7811
|
}
|
|
7812
7812
|
};
|
|
@@ -7844,7 +7844,7 @@ Le.prototype.getClass = function() {
|
|
|
7844
7844
|
return Le;
|
|
7845
7845
|
};
|
|
7846
7846
|
var Nr = function() {
|
|
7847
|
-
this._size = null, this._items = null, this._size = 0, this._items = new
|
|
7847
|
+
this._size = null, this._items = null, this._size = 0, this._items = new S(), this._items.add(null);
|
|
7848
7848
|
};
|
|
7849
7849
|
Nr.prototype.poll = function() {
|
|
7850
7850
|
if (this.isEmpty())
|
|
@@ -7905,7 +7905,7 @@ fn.prototype.getClass = function() {
|
|
|
7905
7905
|
return fn;
|
|
7906
7906
|
};
|
|
7907
7907
|
var Ct = function() {
|
|
7908
|
-
if (this._childBoundables = new
|
|
7908
|
+
if (this._childBoundables = new S(), this._bounds = null, this._level = null, arguments.length !== 0) {
|
|
7909
7909
|
if (arguments.length === 1) {
|
|
7910
7910
|
var t = arguments[0];
|
|
7911
7911
|
this._level = t;
|
|
@@ -7959,7 +7959,7 @@ we.sort = function(t, e) {
|
|
|
7959
7959
|
i.next(), i.set(r[o]);
|
|
7960
7960
|
};
|
|
7961
7961
|
we.singletonList = function(t) {
|
|
7962
|
-
var e = new
|
|
7962
|
+
var e = new S();
|
|
7963
7963
|
return e.add(t), e;
|
|
7964
7964
|
};
|
|
7965
7965
|
var vt = function() {
|
|
@@ -8012,7 +8012,7 @@ vt.isComposite = function(t) {
|
|
|
8012
8012
|
return t instanceof Ct;
|
|
8013
8013
|
};
|
|
8014
8014
|
var xt = function n() {
|
|
8015
|
-
if (this._root = null, this._built = !1, this._itemBoundables = new
|
|
8015
|
+
if (this._root = null, this._built = !1, this._itemBoundables = new S(), this._nodeCapacity = null, arguments.length === 0) {
|
|
8016
8016
|
var t = n.DEFAULT_NODE_CAPACITY;
|
|
8017
8017
|
this._nodeCapacity = t;
|
|
8018
8018
|
} else if (arguments.length === 1) {
|
|
@@ -8050,9 +8050,9 @@ xt.prototype.itemsTree = function() {
|
|
|
8050
8050
|
if (arguments.length === 0) {
|
|
8051
8051
|
this.build();
|
|
8052
8052
|
var e = this.itemsTree(this._root);
|
|
8053
|
-
return e === null ? new
|
|
8053
|
+
return e === null ? new S() : e;
|
|
8054
8054
|
} else if (arguments.length === 1) {
|
|
8055
|
-
for (var r = arguments[0], i = new
|
|
8055
|
+
for (var r = arguments[0], i = new S(), o = r.getChildBoundables().iterator(); o.hasNext(); ) {
|
|
8056
8056
|
var s = o.next();
|
|
8057
8057
|
if (s instanceof Ct) {
|
|
8058
8058
|
var a = t.itemsTree(s);
|
|
@@ -8069,7 +8069,7 @@ xt.prototype.insert = function(t, e) {
|
|
|
8069
8069
|
xt.prototype.boundablesAtLevel = function() {
|
|
8070
8070
|
var t = this;
|
|
8071
8071
|
if (arguments.length === 1) {
|
|
8072
|
-
var e = arguments[0], r = new
|
|
8072
|
+
var e = arguments[0], r = new S();
|
|
8073
8073
|
return this.boundablesAtLevel(e, this._root, r), r;
|
|
8074
8074
|
} else if (arguments.length === 3) {
|
|
8075
8075
|
var i = arguments[0], o = arguments[1], s = arguments[2];
|
|
@@ -8087,7 +8087,7 @@ xt.prototype.query = function() {
|
|
|
8087
8087
|
if (arguments.length === 1) {
|
|
8088
8088
|
var e = arguments[0];
|
|
8089
8089
|
this.build();
|
|
8090
|
-
var r = new
|
|
8090
|
+
var r = new S();
|
|
8091
8091
|
return this.isEmpty() || this.getIntersectsOp().intersects(this._root.getBounds(), e) && this.query(e, this._root, r), r;
|
|
8092
8092
|
} else if (arguments.length === 2) {
|
|
8093
8093
|
var i = arguments[0], o = arguments[1];
|
|
@@ -8101,9 +8101,9 @@ xt.prototype.query = function() {
|
|
|
8101
8101
|
t.getIntersectsOp().intersects(f.getBounds(), s) && (f instanceof Ct ? t.query(s, f, u) : f instanceof Le ? u.visitItem(f.getItem()) : V.shouldNeverReachHere());
|
|
8102
8102
|
}
|
|
8103
8103
|
else if (T(arguments[2], Ne) && arguments[0] instanceof Object && arguments[1] instanceof Ct)
|
|
8104
|
-
for (var h = arguments[0],
|
|
8105
|
-
var E =
|
|
8106
|
-
t.getIntersectsOp().intersects(E.getBounds(), h) && (E instanceof Ct ? t.query(h, E,
|
|
8104
|
+
for (var h = arguments[0], p = arguments[1], g = arguments[2], m = p.getChildBoundables(), d = 0; d < m.size(); d++) {
|
|
8105
|
+
var E = m.get(d);
|
|
8106
|
+
t.getIntersectsOp().intersects(E.getBounds(), h) && (E instanceof Ct ? t.query(h, E, g) : E instanceof Le ? g.add(E.getItem()) : V.shouldNeverReachHere());
|
|
8107
8107
|
}
|
|
8108
8108
|
}
|
|
8109
8109
|
};
|
|
@@ -8157,9 +8157,9 @@ xt.prototype.depth = function() {
|
|
|
8157
8157
|
xt.prototype.createParentBoundables = function(t, e) {
|
|
8158
8158
|
var r = this;
|
|
8159
8159
|
V.isTrue(!t.isEmpty());
|
|
8160
|
-
var i = new
|
|
8160
|
+
var i = new S();
|
|
8161
8161
|
i.add(this.createNode(e));
|
|
8162
|
-
var o = new
|
|
8162
|
+
var o = new S(t);
|
|
8163
8163
|
we.sort(o, this.getComparator());
|
|
8164
8164
|
for (var s = o.iterator(); s.hasNext(); ) {
|
|
8165
8165
|
var a = s.next();
|
|
@@ -8209,7 +8209,7 @@ var ca = function(n) {
|
|
|
8209
8209
|
return t.prototype.createParentBoundablesFromVerticalSlices = function(i, o) {
|
|
8210
8210
|
var s = this;
|
|
8211
8211
|
V.isTrue(i.length > 0);
|
|
8212
|
-
for (var a = new
|
|
8212
|
+
for (var a = new S(), u = 0; u < i.length; u++)
|
|
8213
8213
|
a.addAll(s.createParentBoundablesFromVerticalSlice(i[u], o));
|
|
8214
8214
|
return a;
|
|
8215
8215
|
}, t.prototype.createNode = function(i) {
|
|
@@ -8228,7 +8228,7 @@ var ca = function(n) {
|
|
|
8228
8228
|
return t.intersectsOp;
|
|
8229
8229
|
}, t.prototype.verticalSlices = function(i, o) {
|
|
8230
8230
|
for (var s = Math.trunc(Math.ceil(i.size() / o)), a = new Array(o).fill(null), u = i.iterator(), l = 0; l < o; l++) {
|
|
8231
|
-
a[l] = new
|
|
8231
|
+
a[l] = new S();
|
|
8232
8232
|
for (var c = 0; u.hasNext() && c < s; ) {
|
|
8233
8233
|
var f = u.next();
|
|
8234
8234
|
a[l].add(f), c++;
|
|
@@ -8265,7 +8265,7 @@ var ca = function(n) {
|
|
|
8265
8265
|
return arguments.length === 0 ? n.prototype.depth.call(this) : n.prototype.depth.apply(this, arguments);
|
|
8266
8266
|
}, t.prototype.createParentBoundables = function(i, o) {
|
|
8267
8267
|
V.isTrue(!i.isEmpty());
|
|
8268
|
-
var s = Math.trunc(Math.ceil(i.size() / this.getNodeCapacity())), a = new
|
|
8268
|
+
var s = Math.trunc(Math.ceil(i.size() / this.getNodeCapacity())), a = new S(i);
|
|
8269
8269
|
we.sort(a, t.xComparator);
|
|
8270
8270
|
var u = this.verticalSlices(a, Math.trunc(Math.ceil(Math.sqrt(s))));
|
|
8271
8271
|
return this.createParentBoundablesFromVerticalSlices(u, o);
|
|
@@ -8283,18 +8283,18 @@ var ca = function(n) {
|
|
|
8283
8283
|
var a = arguments[0], u = arguments[1], l = new vt(this.getRoot(), a.getRoot(), u);
|
|
8284
8284
|
return this.nearestNeighbour(l);
|
|
8285
8285
|
} else if (arguments[0] instanceof vt && typeof arguments[1] == "number") {
|
|
8286
|
-
var c = arguments[0], f = arguments[1], h = f,
|
|
8287
|
-
for (
|
|
8288
|
-
var
|
|
8289
|
-
if (
|
|
8286
|
+
var c = arguments[0], f = arguments[1], h = f, p = null, g = new Nr();
|
|
8287
|
+
for (g.add(c); !g.isEmpty() && h > 0; ) {
|
|
8288
|
+
var m = g.poll(), d = m.getDistance();
|
|
8289
|
+
if (d >= h)
|
|
8290
8290
|
break;
|
|
8291
|
-
|
|
8291
|
+
m.isLeaves() ? (h = d, p = m) : m.expandToQueue(g, h);
|
|
8292
8292
|
}
|
|
8293
|
-
return [
|
|
8293
|
+
return [p.getBoundable(0).getItem(), p.getBoundable(1).getItem()];
|
|
8294
8294
|
}
|
|
8295
8295
|
} else if (arguments.length === 3) {
|
|
8296
|
-
var E = arguments[0], I = arguments[1], C = arguments[2],
|
|
8297
|
-
return this.nearestNeighbour(
|
|
8296
|
+
var E = arguments[0], I = arguments[1], C = arguments[2], x = new Le(E, I), R = new vt(this.getRoot(), x, C);
|
|
8297
|
+
return this.nearestNeighbour(R)[0];
|
|
8298
8298
|
}
|
|
8299
8299
|
}, t.prototype.interfaces_ = function() {
|
|
8300
8300
|
return [fn, Ie];
|
|
@@ -8397,7 +8397,7 @@ jt.compareValue = function(t, e) {
|
|
|
8397
8397
|
var Ar = function() {
|
|
8398
8398
|
this._segString = null, this.coord = null, this.segmentIndex = null, this._segmentOctant = null, this._isInterior = null;
|
|
8399
8399
|
var t = arguments[0], e = arguments[1], r = arguments[2], i = arguments[3];
|
|
8400
|
-
this._segString = t, this.coord = new
|
|
8400
|
+
this._segString = t, this.coord = new v(e), this.segmentIndex = r, this._segmentOctant = i, this._isInterior = !e.equals2D(t.getCoordinate(r));
|
|
8401
8401
|
};
|
|
8402
8402
|
Ar.prototype.getCoordinate = function() {
|
|
8403
8403
|
return this.coord;
|
|
@@ -8436,7 +8436,7 @@ Ht.prototype.getSplitCoordinates = function() {
|
|
|
8436
8436
|
return e.toCoordinateArray();
|
|
8437
8437
|
};
|
|
8438
8438
|
Ht.prototype.addCollapsedNodes = function() {
|
|
8439
|
-
var t = this, e = new
|
|
8439
|
+
var t = this, e = new S();
|
|
8440
8440
|
this.findCollapsesFromInsertedNodes(e), this.findCollapsesFromExistingVertices(e);
|
|
8441
8441
|
for (var r = e.iterator(); r.hasNext(); ) {
|
|
8442
8442
|
var i = r.next().intValue();
|
|
@@ -8458,10 +8458,10 @@ Ht.prototype.findCollapsesFromExistingVertices = function(t) {
|
|
|
8458
8458
|
};
|
|
8459
8459
|
Ht.prototype.addEdgeCoordinates = function(t, e, r) {
|
|
8460
8460
|
var i = this, o = this._edge.getCoordinate(e.segmentIndex), s = e.isInterior() || !e.coord.equals2D(o);
|
|
8461
|
-
r.add(new
|
|
8461
|
+
r.add(new v(t.coord), !1);
|
|
8462
8462
|
for (var a = t.segmentIndex + 1; a <= e.segmentIndex; a++)
|
|
8463
8463
|
r.add(i._edge.getCoordinate(a));
|
|
8464
|
-
s && r.add(new
|
|
8464
|
+
s && r.add(new v(e.coord));
|
|
8465
8465
|
};
|
|
8466
8466
|
Ht.prototype.iterator = function() {
|
|
8467
8467
|
return this._nodeMap.values().iterator();
|
|
@@ -8497,10 +8497,10 @@ Ht.prototype.createSplitEdge = function(t, e) {
|
|
|
8497
8497
|
var r = this, i = e.segmentIndex - t.segmentIndex + 2, o = this._edge.getCoordinate(e.segmentIndex), s = e.isInterior() || !e.coord.equals2D(o);
|
|
8498
8498
|
s || i--;
|
|
8499
8499
|
var a = new Array(i).fill(null), u = 0;
|
|
8500
|
-
a[u++] = new
|
|
8500
|
+
a[u++] = new v(t.coord);
|
|
8501
8501
|
for (var l = t.segmentIndex + 1; l <= e.segmentIndex; l++)
|
|
8502
8502
|
a[u++] = r._edge.getCoordinate(l);
|
|
8503
|
-
return s && (a[u] = new
|
|
8503
|
+
return s && (a[u] = new v(e.coord)), new dt(a, this._edge.getData());
|
|
8504
8504
|
};
|
|
8505
8505
|
Ht.prototype.add = function(t, e) {
|
|
8506
8506
|
var r = new Ar(this._edge, t, e, this._edge.getSegmentOctant(e)), i = this._nodeMap.get(r);
|
|
@@ -8535,7 +8535,7 @@ hn.octant = function() {
|
|
|
8535
8535
|
throw new it("Cannot compute the octant for point ( " + t + ", " + e + " )");
|
|
8536
8536
|
var r = Math.abs(t), i = Math.abs(e);
|
|
8537
8537
|
return t >= 0 ? e >= 0 ? r >= i ? 0 : 1 : r >= i ? 7 : 6 : e >= 0 ? r >= i ? 3 : 2 : r >= i ? 4 : 5;
|
|
8538
|
-
} else if (arguments[0] instanceof
|
|
8538
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof v) {
|
|
8539
8539
|
var o = arguments[0], s = arguments[1], a = s.x - o.x, u = s.y - o.y;
|
|
8540
8540
|
if (a === 0 && u === 0)
|
|
8541
8541
|
throw new it("Cannot compute the octant for two identical points " + o);
|
|
@@ -8606,7 +8606,7 @@ dt.prototype.addIntersection = function() {
|
|
|
8606
8606
|
var t = arguments[0], e = arguments[1];
|
|
8607
8607
|
this.addIntersectionNode(t, e);
|
|
8608
8608
|
} else if (arguments.length === 4) {
|
|
8609
|
-
var r = arguments[0], i = arguments[1], o = arguments[3], s = new
|
|
8609
|
+
var r = arguments[0], i = arguments[1], o = arguments[3], s = new v(r.getIntersection(o));
|
|
8610
8610
|
this.addIntersection(s, i);
|
|
8611
8611
|
}
|
|
8612
8612
|
};
|
|
@@ -8637,7 +8637,7 @@ dt.prototype.getClass = function() {
|
|
|
8637
8637
|
};
|
|
8638
8638
|
dt.getNodedSubstrings = function() {
|
|
8639
8639
|
if (arguments.length === 1) {
|
|
8640
|
-
var t = arguments[0], e = new
|
|
8640
|
+
var t = arguments[0], e = new S();
|
|
8641
8641
|
return dt.getNodedSubstrings(t, e), e;
|
|
8642
8642
|
} else if (arguments.length === 2)
|
|
8643
8643
|
for (var r = arguments[0], i = arguments[1], o = r.iterator(); o.hasNext(); ) {
|
|
@@ -8647,15 +8647,15 @@ dt.getNodedSubstrings = function() {
|
|
|
8647
8647
|
};
|
|
8648
8648
|
var b = function() {
|
|
8649
8649
|
if (this.p0 = null, this.p1 = null, arguments.length === 0)
|
|
8650
|
-
this.p0 = new
|
|
8650
|
+
this.p0 = new v(), this.p1 = new v();
|
|
8651
8651
|
else if (arguments.length === 1) {
|
|
8652
8652
|
var t = arguments[0];
|
|
8653
|
-
this.p0 = new
|
|
8653
|
+
this.p0 = new v(t.p0), this.p1 = new v(t.p1);
|
|
8654
8654
|
} else if (arguments.length === 2)
|
|
8655
8655
|
this.p0 = arguments[0], this.p1 = arguments[1];
|
|
8656
8656
|
else if (arguments.length === 4) {
|
|
8657
8657
|
var e = arguments[0], r = arguments[1], i = arguments[2], o = arguments[3];
|
|
8658
|
-
this.p0 = new
|
|
8658
|
+
this.p0 = new v(e, r), this.p1 = new v(i, o);
|
|
8659
8659
|
}
|
|
8660
8660
|
}, fa = { serialVersionUID: { configurable: !0 } };
|
|
8661
8661
|
b.prototype.minX = function() {
|
|
@@ -8665,7 +8665,7 @@ b.prototype.orientationIndex = function() {
|
|
|
8665
8665
|
if (arguments[0] instanceof b) {
|
|
8666
8666
|
var t = arguments[0], e = L.orientationIndex(this.p0, this.p1, t.p0), r = L.orientationIndex(this.p0, this.p1, t.p1);
|
|
8667
8667
|
return e >= 0 && r >= 0 || e <= 0 && r <= 0 ? Math.max(e, r) : 0;
|
|
8668
|
-
} else if (arguments[0] instanceof
|
|
8668
|
+
} else if (arguments[0] instanceof v) {
|
|
8669
8669
|
var i = arguments[0];
|
|
8670
8670
|
return L.orientationIndex(this.p0, this.p1, i);
|
|
8671
8671
|
}
|
|
@@ -8687,11 +8687,11 @@ b.prototype.intersection = function(t) {
|
|
|
8687
8687
|
return e.computeIntersection(this.p0, this.p1, t.p0, t.p1), e.hasIntersection() ? e.getIntersection(0) : null;
|
|
8688
8688
|
};
|
|
8689
8689
|
b.prototype.project = function() {
|
|
8690
|
-
if (arguments[0] instanceof
|
|
8690
|
+
if (arguments[0] instanceof v) {
|
|
8691
8691
|
var t = arguments[0];
|
|
8692
8692
|
if (t.equals(this.p0) || t.equals(this.p1))
|
|
8693
|
-
return new
|
|
8694
|
-
var e = this.projectionFactor(t), r = new
|
|
8693
|
+
return new v(t);
|
|
8694
|
+
var e = this.projectionFactor(t), r = new v();
|
|
8695
8695
|
return r.x = this.p0.x + e * (this.p1.x - this.p0.x), r.y = this.p0.y + e * (this.p1.y - this.p0.y), r;
|
|
8696
8696
|
} else if (arguments[0] instanceof b) {
|
|
8697
8697
|
var i = arguments[0], o = this.projectionFactor(i.p0), s = this.projectionFactor(i.p1);
|
|
@@ -8790,7 +8790,7 @@ b.prototype.pointAlongOffset = function(t, e) {
|
|
|
8790
8790
|
throw new Error("Cannot compute offset from zero-length line segment");
|
|
8791
8791
|
u = e * o / a, l = e * s / a;
|
|
8792
8792
|
}
|
|
8793
|
-
var c = r - l, f = i + u, h = new
|
|
8793
|
+
var c = r - l, f = i + u, h = new v(c, f);
|
|
8794
8794
|
return h;
|
|
8795
8795
|
};
|
|
8796
8796
|
b.prototype.setCoordinates = function() {
|
|
@@ -8816,13 +8816,13 @@ b.prototype.distance = function() {
|
|
|
8816
8816
|
if (arguments[0] instanceof b) {
|
|
8817
8817
|
var t = arguments[0];
|
|
8818
8818
|
return L.distanceLineLine(this.p0, this.p1, t.p0, t.p1);
|
|
8819
|
-
} else if (arguments[0] instanceof
|
|
8819
|
+
} else if (arguments[0] instanceof v) {
|
|
8820
8820
|
var e = arguments[0];
|
|
8821
8821
|
return L.distancePointLine(e, this.p0, this.p1);
|
|
8822
8822
|
}
|
|
8823
8823
|
};
|
|
8824
8824
|
b.prototype.pointAlong = function(t) {
|
|
8825
|
-
var e = new
|
|
8825
|
+
var e = new v();
|
|
8826
8826
|
return e.x = this.p0.x + t * (this.p1.x - this.p0.x), e.y = this.p0.y + t * (this.p1.y - this.p0.y), e;
|
|
8827
8827
|
};
|
|
8828
8828
|
b.prototype.hashCode = function() {
|
|
@@ -8840,7 +8840,7 @@ b.prototype.getClass = function() {
|
|
|
8840
8840
|
return b;
|
|
8841
8841
|
};
|
|
8842
8842
|
b.midPoint = function(t, e) {
|
|
8843
|
-
return new
|
|
8843
|
+
return new v((t.x + e.x) / 2, (t.y + e.y) / 2);
|
|
8844
8844
|
};
|
|
8845
8845
|
fa.serialVersionUID.get = function() {
|
|
8846
8846
|
return 3252005833466256400;
|
|
@@ -8937,7 +8937,7 @@ Ve.prototype.getClass = function() {
|
|
|
8937
8937
|
return Ve;
|
|
8938
8938
|
};
|
|
8939
8939
|
Ve.getChainStartIndices = function(t) {
|
|
8940
|
-
var e = 0, r = new
|
|
8940
|
+
var e = 0, r = new S();
|
|
8941
8941
|
r.add(new ke(e));
|
|
8942
8942
|
do {
|
|
8943
8943
|
var i = Ve.findChainEnd(t, e);
|
|
@@ -8966,7 +8966,7 @@ Ve.getChains = function() {
|
|
|
8966
8966
|
var t = arguments[0];
|
|
8967
8967
|
return Ve.getChains(t, null);
|
|
8968
8968
|
} else if (arguments.length === 2) {
|
|
8969
|
-
for (var e = arguments[0], r = arguments[1], i = new
|
|
8969
|
+
for (var e = arguments[0], r = arguments[1], i = new S(), o = Ve.getChainStartIndices(e), s = 0; s < o.length - 1; s++) {
|
|
8970
8970
|
var a = new re(e, o[s], o[s + 1], r);
|
|
8971
8971
|
i.add(a);
|
|
8972
8972
|
}
|
|
@@ -9009,7 +9009,7 @@ Ci.prototype.getClass = function() {
|
|
|
9009
9009
|
};
|
|
9010
9010
|
var Ko = function(n) {
|
|
9011
9011
|
function t(r) {
|
|
9012
|
-
r ? n.call(this, r) : n.call(this), this._monoChains = new
|
|
9012
|
+
r ? n.call(this, r) : n.call(this), this._monoChains = new S(), this._index = new ca(), this._idCounter = 0, this._nodedSegStrings = null, this._nOverlaps = 0;
|
|
9013
9013
|
}
|
|
9014
9014
|
n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t;
|
|
9015
9015
|
var e = { SegmentOverlapAction: { configurable: !0 } };
|
|
@@ -9229,7 +9229,7 @@ Di.NUM_PTS_TO_CHECK.get = function() {
|
|
|
9229
9229
|
};
|
|
9230
9230
|
Object.defineProperties(lt, Di);
|
|
9231
9231
|
var ce = function() {
|
|
9232
|
-
this._ptList = null, this._precisionModel = null, this._minimimVertexDistance = 0, this._ptList = new
|
|
9232
|
+
this._ptList = null, this._precisionModel = null, this._minimimVertexDistance = 0, this._ptList = new S();
|
|
9233
9233
|
}, ha = { COORDINATE_ARRAY_TYPE: { configurable: !0 } };
|
|
9234
9234
|
ce.prototype.getCoordinates = function() {
|
|
9235
9235
|
var t = this._ptList.toArray(ce.COORDINATE_ARRAY_TYPE);
|
|
@@ -9239,7 +9239,7 @@ ce.prototype.setPrecisionModel = function(t) {
|
|
|
9239
9239
|
this._precisionModel = t;
|
|
9240
9240
|
};
|
|
9241
9241
|
ce.prototype.addPt = function(t) {
|
|
9242
|
-
var e = new
|
|
9242
|
+
var e = new v(t);
|
|
9243
9243
|
if (this._precisionModel.makePrecise(e), this.isRedundant(e))
|
|
9244
9244
|
return null;
|
|
9245
9245
|
this._ptList.add(e);
|
|
@@ -9268,7 +9268,7 @@ ce.prototype.toString = function() {
|
|
|
9268
9268
|
ce.prototype.closeRing = function() {
|
|
9269
9269
|
if (this._ptList.size() < 1)
|
|
9270
9270
|
return null;
|
|
9271
|
-
var t = new
|
|
9271
|
+
var t = new v(this._ptList.get(0)), e = this._ptList.get(this._ptList.size() - 1);
|
|
9272
9272
|
if (t.equals(e))
|
|
9273
9273
|
return null;
|
|
9274
9274
|
this._ptList.add(t);
|
|
@@ -9400,9 +9400,9 @@ rt.prototype.addLineEndCap = function(t, e) {
|
|
|
9400
9400
|
this._segList.addPt(i.p1), this._segList.addPt(o.p1);
|
|
9401
9401
|
break;
|
|
9402
9402
|
case H.CAP_SQUARE:
|
|
9403
|
-
var l = new
|
|
9403
|
+
var l = new v();
|
|
9404
9404
|
l.x = Math.abs(this._distance) * Math.cos(u), l.y = Math.abs(this._distance) * Math.sin(u);
|
|
9405
|
-
var c = new
|
|
9405
|
+
var c = new v(i.p1.x + l.x, i.p1.y + l.y), f = new v(o.p1.x + l.x, o.p1.y + l.y);
|
|
9406
9406
|
this._segList.addPt(c), this._segList.addPt(f);
|
|
9407
9407
|
break;
|
|
9408
9408
|
}
|
|
@@ -9419,7 +9419,7 @@ rt.prototype.addMitreJoin = function(t, e, r, i) {
|
|
|
9419
9419
|
a > this._bufParams.getMitreLimit() && (o = !1);
|
|
9420
9420
|
} catch (u) {
|
|
9421
9421
|
if (u instanceof $n)
|
|
9422
|
-
s = new
|
|
9422
|
+
s = new v(0, 0), o = !1;
|
|
9423
9423
|
else
|
|
9424
9424
|
throw u;
|
|
9425
9425
|
} finally {
|
|
@@ -9436,7 +9436,7 @@ rt.prototype.addOutsideTurn = function(t, e) {
|
|
|
9436
9436
|
this._bufParams.getJoinStyle() === H.JOIN_MITRE ? this.addMitreJoin(this._s1, this._offset0, this._offset1, this._distance) : this._bufParams.getJoinStyle() === H.JOIN_BEVEL ? this.addBevelJoin(this._offset0, this._offset1) : (e && this._segList.addPt(this._offset0.p1), this.addFilletCorner(this._s1, this._offset0.p1, this._offset1.p0, t, this._distance), this._segList.addPt(this._offset1.p0));
|
|
9437
9437
|
};
|
|
9438
9438
|
rt.prototype.createSquare = function(t) {
|
|
9439
|
-
this._segList.addPt(new
|
|
9439
|
+
this._segList.addPt(new v(t.x + this._distance, t.y + this._distance)), this._segList.addPt(new v(t.x + this._distance, t.y - this._distance)), this._segList.addPt(new v(t.x - this._distance, t.y - this._distance)), this._segList.addPt(new v(t.x - this._distance, t.y + this._distance)), this._segList.closeRing();
|
|
9440
9440
|
};
|
|
9441
9441
|
rt.prototype.addSegments = function(t, e) {
|
|
9442
9442
|
this._segList.addPts(t, e);
|
|
@@ -9451,7 +9451,7 @@ rt.prototype.initSideSegments = function(t, e, r) {
|
|
|
9451
9451
|
this._s1 = t, this._s2 = e, this._side = r, this._seg1.setCoordinates(t, e), this.computeOffsetSegment(this._seg1, r, this._distance, this._offset1);
|
|
9452
9452
|
};
|
|
9453
9453
|
rt.prototype.addLimitedMitreJoin = function(t, e, r, i) {
|
|
9454
|
-
var o = this._seg0.p1, s = U.angle(o, this._seg0.p0), a = U.angleBetweenOriented(this._seg0.p0, o, this._seg1.p1), u = a / 2, l = U.normalize(s + u), c = U.normalize(l + Math.PI), f = i * r, h = f * Math.abs(Math.sin(u)),
|
|
9454
|
+
var o = this._seg0.p1, s = U.angle(o, this._seg0.p0), a = U.angleBetweenOriented(this._seg0.p0, o, this._seg1.p1), u = a / 2, l = U.normalize(s + u), c = U.normalize(l + Math.PI), f = i * r, h = f * Math.abs(Math.sin(u)), p = r - h, g = o.x + f * Math.cos(c), m = o.y + f * Math.sin(c), d = new v(g, m), E = new b(o, d), I = E.pointAlongOffset(1, p), C = E.pointAlongOffset(1, -p);
|
|
9455
9455
|
this._side === N.LEFT ? (this._segList.addPt(I), this._segList.addPt(C)) : (this._segList.addPt(C), this._segList.addPt(I));
|
|
9456
9456
|
};
|
|
9457
9457
|
rt.prototype.computeOffsetSegment = function(t, e, r, i) {
|
|
@@ -9462,9 +9462,9 @@ rt.prototype.addFilletArc = function(t, e, r, i, o) {
|
|
|
9462
9462
|
var s = this, a = i === L.CLOCKWISE ? -1 : 1, u = Math.abs(e - r), l = Math.trunc(u / this._filletAngleQuantum + 0.5);
|
|
9463
9463
|
if (l < 1)
|
|
9464
9464
|
return null;
|
|
9465
|
-
for (var c = 0, f = u / l, h = c,
|
|
9466
|
-
var
|
|
9467
|
-
|
|
9465
|
+
for (var c = 0, f = u / l, h = c, p = new v(); h < u; ) {
|
|
9466
|
+
var g = e + a * h;
|
|
9467
|
+
p.x = t.x + o * Math.cos(g), p.y = t.y + o * Math.sin(g), s._segList.addPt(p), h += f;
|
|
9468
9468
|
}
|
|
9469
9469
|
};
|
|
9470
9470
|
rt.prototype.addInsideTurn = function(t, e) {
|
|
@@ -9474,9 +9474,9 @@ rt.prototype.addInsideTurn = function(t, e) {
|
|
|
9474
9474
|
this._segList.addPt(this._offset0.p1);
|
|
9475
9475
|
else {
|
|
9476
9476
|
if (this._segList.addPt(this._offset0.p1), this._closingSegLengthFactor > 0) {
|
|
9477
|
-
var r = new
|
|
9477
|
+
var r = new v((this._closingSegLengthFactor * this._offset0.p1.x + this._s1.x) / (this._closingSegLengthFactor + 1), (this._closingSegLengthFactor * this._offset0.p1.y + this._s1.y) / (this._closingSegLengthFactor + 1));
|
|
9478
9478
|
this._segList.addPt(r);
|
|
9479
|
-
var i = new
|
|
9479
|
+
var i = new v((this._closingSegLengthFactor * this._offset1.p0.x + this._s1.x) / (this._closingSegLengthFactor + 1), (this._closingSegLengthFactor * this._offset1.p0.y + this._s1.y) / (this._closingSegLengthFactor + 1));
|
|
9480
9480
|
this._segList.addPt(i);
|
|
9481
9481
|
} else
|
|
9482
9482
|
this._segList.addPt(this._s1);
|
|
@@ -9484,7 +9484,7 @@ rt.prototype.addInsideTurn = function(t, e) {
|
|
|
9484
9484
|
}
|
|
9485
9485
|
};
|
|
9486
9486
|
rt.prototype.createCircle = function(t) {
|
|
9487
|
-
var e = new
|
|
9487
|
+
var e = new v(t.x + this._distance, t.y);
|
|
9488
9488
|
this._segList.addPt(e), this.addFilletArc(t, 0, 2 * Math.PI, -1, this._distance), this._segList.closeRing();
|
|
9489
9489
|
};
|
|
9490
9490
|
rt.prototype.addBevelJoin = function(t, e) {
|
|
@@ -9640,7 +9640,7 @@ Qt.prototype.getClass = function() {
|
|
|
9640
9640
|
};
|
|
9641
9641
|
Qt.copyCoordinates = function(t) {
|
|
9642
9642
|
for (var e = new Array(t.length).fill(null), r = 0; r < e.length; r++)
|
|
9643
|
-
e[r] = new
|
|
9643
|
+
e[r] = new v(t[r]);
|
|
9644
9644
|
return e;
|
|
9645
9645
|
};
|
|
9646
9646
|
var pn = function() {
|
|
@@ -9651,27 +9651,27 @@ var pn = function() {
|
|
|
9651
9651
|
pn.prototype.findStabbedSegments = function() {
|
|
9652
9652
|
var t = this;
|
|
9653
9653
|
if (arguments.length === 1) {
|
|
9654
|
-
for (var e = arguments[0], r = new
|
|
9654
|
+
for (var e = arguments[0], r = new S(), i = this._subgraphs.iterator(); i.hasNext(); ) {
|
|
9655
9655
|
var o = i.next(), s = o.getEnvelope();
|
|
9656
9656
|
e.y < s.getMinY() || e.y > s.getMaxY() || t.findStabbedSegments(e, o.getDirectedEdges(), r);
|
|
9657
9657
|
}
|
|
9658
9658
|
return r;
|
|
9659
9659
|
} else if (arguments.length === 3) {
|
|
9660
|
-
if (T(arguments[2], Ne) && arguments[0] instanceof
|
|
9660
|
+
if (T(arguments[2], Ne) && arguments[0] instanceof v && arguments[1] instanceof To)
|
|
9661
9661
|
for (var a = arguments[0], u = arguments[1], l = arguments[2], c = u.getEdge().getCoordinates(), f = 0; f < c.length - 1; f++) {
|
|
9662
9662
|
t._seg.p0 = c[f], t._seg.p1 = c[f + 1], t._seg.p0.y > t._seg.p1.y && t._seg.reverse();
|
|
9663
9663
|
var h = Math.max(t._seg.p0.x, t._seg.p1.x);
|
|
9664
9664
|
if (!(h < a.x) && !t._seg.isHorizontal() && !(a.y < t._seg.p0.y || a.y > t._seg.p1.y) && L.computeOrientation(t._seg.p0, t._seg.p1, a) !== L.RIGHT) {
|
|
9665
|
-
var
|
|
9666
|
-
t._seg.p0.equals(c[f]) || (
|
|
9667
|
-
var
|
|
9668
|
-
l.add(
|
|
9665
|
+
var p = u.getDepth(N.LEFT);
|
|
9666
|
+
t._seg.p0.equals(c[f]) || (p = u.getDepth(N.RIGHT));
|
|
9667
|
+
var g = new Zr(t._seg, p);
|
|
9668
|
+
l.add(g);
|
|
9669
9669
|
}
|
|
9670
9670
|
}
|
|
9671
|
-
else if (T(arguments[2], Ne) && arguments[0] instanceof
|
|
9672
|
-
for (var
|
|
9671
|
+
else if (T(arguments[2], Ne) && arguments[0] instanceof v && T(arguments[1], Ne))
|
|
9672
|
+
for (var m = arguments[0], d = arguments[1], E = arguments[2], I = d.iterator(); I.hasNext(); ) {
|
|
9673
9673
|
var C = I.next();
|
|
9674
|
-
C.isForward() && t.findStabbedSegments(
|
|
9674
|
+
C.isForward() && t.findStabbedSegments(m, C, E);
|
|
9675
9675
|
}
|
|
9676
9676
|
}
|
|
9677
9677
|
};
|
|
@@ -9767,8 +9767,8 @@ j.det = function(t, e, r, i) {
|
|
|
9767
9767
|
return t * i - e * r;
|
|
9768
9768
|
};
|
|
9769
9769
|
j.interpolateZ = function(t, e, r, i) {
|
|
9770
|
-
var o = e.x, s = e.y, a = r.x - o, u = i.x - o, l = r.y - s, c = i.y - s, f = a * c - u * l, h = t.x - o,
|
|
9771
|
-
return
|
|
9770
|
+
var o = e.x, s = e.y, a = r.x - o, u = i.x - o, l = r.y - s, c = i.y - s, f = a * c - u * l, h = t.x - o, p = t.y - s, g = (c * h - u * p) / f, m = (-l * h + a * p) / f, d = e.z + g * (r.z - e.z) + m * (i.z - e.z);
|
|
9771
|
+
return d;
|
|
9772
9772
|
};
|
|
9773
9773
|
j.longestSideLength = function(t, e, r) {
|
|
9774
9774
|
var i = t.distance(e), o = e.distance(r), s = r.distance(t), a = i;
|
|
@@ -9778,31 +9778,31 @@ j.isAcute = function(t, e, r) {
|
|
|
9778
9778
|
return !(!U.isAcute(t, e, r) || !U.isAcute(e, r, t) || !U.isAcute(r, t, e));
|
|
9779
9779
|
};
|
|
9780
9780
|
j.circumcentre = function(t, e, r) {
|
|
9781
|
-
var i = r.x, o = r.y, s = t.x - i, a = t.y - o, u = e.x - i, l = e.y - o, c = 2 * j.det(s, a, u, l), f = j.det(a, s * s + a * a, l, u * u + l * l), h = j.det(s, s * s + a * a, u, u * u + l * l),
|
|
9782
|
-
return new
|
|
9781
|
+
var i = r.x, o = r.y, s = t.x - i, a = t.y - o, u = e.x - i, l = e.y - o, c = 2 * j.det(s, a, u, l), f = j.det(a, s * s + a * a, l, u * u + l * l), h = j.det(s, s * s + a * a, u, u * u + l * l), p = i - f / c, g = o + h / c;
|
|
9782
|
+
return new v(p, g);
|
|
9783
9783
|
};
|
|
9784
9784
|
j.perpendicularBisector = function(t, e) {
|
|
9785
9785
|
var r = e.x - t.x, i = e.y - t.y, o = new Ce(t.x + r / 2, t.y + i / 2, 1), s = new Ce(t.x - i + r / 2, t.y + r + i / 2, 1);
|
|
9786
9786
|
return new Ce(o, s);
|
|
9787
9787
|
};
|
|
9788
9788
|
j.angleBisector = function(t, e, r) {
|
|
9789
|
-
var i = e.distance(t), o = e.distance(r), s = i / (i + o), a = r.x - t.x, u = r.y - t.y, l = new
|
|
9789
|
+
var i = e.distance(t), o = e.distance(r), s = i / (i + o), a = r.x - t.x, u = r.y - t.y, l = new v(t.x + s * a, t.y + s * u);
|
|
9790
9790
|
return l;
|
|
9791
9791
|
};
|
|
9792
9792
|
j.area3D = function(t, e, r) {
|
|
9793
|
-
var i = e.x - t.x, o = e.y - t.y, s = e.z - t.z, a = r.x - t.x, u = r.y - t.y, l = r.z - t.z, c = o * l - s * u, f = s * a - i * l, h = i * u - o * a,
|
|
9794
|
-
return
|
|
9793
|
+
var i = e.x - t.x, o = e.y - t.y, s = e.z - t.z, a = r.x - t.x, u = r.y - t.y, l = r.z - t.z, c = o * l - s * u, f = s * a - i * l, h = i * u - o * a, p = c * c + f * f + h * h, g = Math.sqrt(p) / 2;
|
|
9794
|
+
return g;
|
|
9795
9795
|
};
|
|
9796
9796
|
j.centroid = function(t, e, r) {
|
|
9797
9797
|
var i = (t.x + e.x + r.x) / 3, o = (t.y + e.y + r.y) / 3;
|
|
9798
|
-
return new
|
|
9798
|
+
return new v(i, o);
|
|
9799
9799
|
};
|
|
9800
9800
|
j.inCentre = function(t, e, r) {
|
|
9801
9801
|
var i = e.distance(r), o = t.distance(r), s = t.distance(e), a = i + o + s, u = (i * t.x + o * e.x + s * r.x) / a, l = (i * t.y + o * e.y + s * r.y) / a;
|
|
9802
|
-
return new
|
|
9802
|
+
return new v(u, l);
|
|
9803
9803
|
};
|
|
9804
9804
|
var _e = function() {
|
|
9805
|
-
this._inputGeom = null, this._distance = null, this._curveBuilder = null, this._curveList = new
|
|
9805
|
+
this._inputGeom = null, this._distance = null, this._curveBuilder = null, this._curveList = new S();
|
|
9806
9806
|
var t = arguments[0], e = arguments[1], r = arguments[2];
|
|
9807
9807
|
this._inputGeom = t, this._distance = e, this._curveBuilder = r;
|
|
9808
9808
|
};
|
|
@@ -10046,7 +10046,7 @@ Bt.prototype.iterator = function() {
|
|
|
10046
10046
|
return this.getEdges().iterator();
|
|
10047
10047
|
};
|
|
10048
10048
|
Bt.prototype.getEdges = function() {
|
|
10049
|
-
return this._edgeList === null && (this._edgeList = new
|
|
10049
|
+
return this._edgeList === null && (this._edgeList = new S(this._edgeMap.values())), this._edgeList;
|
|
10050
10050
|
};
|
|
10051
10051
|
Bt.prototype.getLocation = function(t, e, r) {
|
|
10052
10052
|
return this._ptInAreaLocation[t] === y.NONE && (this._ptInAreaLocation[t] = se.locate(e, r[t].getGeometry())), this._ptInAreaLocation[t];
|
|
@@ -10081,8 +10081,8 @@ Bt.prototype.computeLabelling = function(t) {
|
|
|
10081
10081
|
if (r[f])
|
|
10082
10082
|
h = y.EXTERIOR;
|
|
10083
10083
|
else {
|
|
10084
|
-
var
|
|
10085
|
-
h = e.getLocation(f,
|
|
10084
|
+
var p = l.getCoordinate();
|
|
10085
|
+
h = e.getLocation(f, p, t);
|
|
10086
10086
|
}
|
|
10087
10087
|
c.setAllLocationsIfNull(f, h);
|
|
10088
10088
|
}
|
|
@@ -10149,7 +10149,7 @@ var Ku = function(n) {
|
|
|
10149
10149
|
var r = this;
|
|
10150
10150
|
if (this._resultAreaEdgeList !== null)
|
|
10151
10151
|
return this._resultAreaEdgeList;
|
|
10152
|
-
this._resultAreaEdgeList = new
|
|
10152
|
+
this._resultAreaEdgeList = new S();
|
|
10153
10153
|
for (var i = this.iterator(); i.hasNext(); ) {
|
|
10154
10154
|
var o = i.next();
|
|
10155
10155
|
(o.isInResult() || o.getSym().isInResult()) && r._resultAreaEdgeList.add(o);
|
|
@@ -10175,11 +10175,11 @@ var Ku = function(n) {
|
|
|
10175
10175
|
if (l !== a)
|
|
10176
10176
|
throw new Cr("depth mismatch at " + i.getCoordinate());
|
|
10177
10177
|
} else if (arguments.length === 3) {
|
|
10178
|
-
for (var c = arguments[0], f = arguments[1], h = arguments[2],
|
|
10179
|
-
var
|
|
10180
|
-
|
|
10178
|
+
for (var c = arguments[0], f = arguments[1], h = arguments[2], p = h, g = c; g < f; g++) {
|
|
10179
|
+
var m = r._edgeList.get(g);
|
|
10180
|
+
m.setEdgeDepths(N.RIGHT, p), p = m.getDepth(N.LEFT);
|
|
10181
10181
|
}
|
|
10182
|
-
return
|
|
10182
|
+
return p;
|
|
10183
10183
|
}
|
|
10184
10184
|
}, t.prototype.mergeSymLabels = function() {
|
|
10185
10185
|
for (var r = this.iterator(); r.hasNext(); ) {
|
|
@@ -10287,17 +10287,17 @@ Fr.compareOriented = function(t, e, r, i) {
|
|
|
10287
10287
|
if (f !== 0)
|
|
10288
10288
|
return f;
|
|
10289
10289
|
l += o, c += s;
|
|
10290
|
-
var h = l === a,
|
|
10291
|
-
if (h && !
|
|
10290
|
+
var h = l === a, p = c === u;
|
|
10291
|
+
if (h && !p)
|
|
10292
10292
|
return -1;
|
|
10293
|
-
if (!h &&
|
|
10293
|
+
if (!h && p)
|
|
10294
10294
|
return 1;
|
|
10295
|
-
if (h &&
|
|
10295
|
+
if (h && p)
|
|
10296
10296
|
return 0;
|
|
10297
10297
|
}
|
|
10298
10298
|
};
|
|
10299
10299
|
var Pe = function() {
|
|
10300
|
-
this._edges = new
|
|
10300
|
+
this._edges = new S(), this._ocaMap = new At();
|
|
10301
10301
|
};
|
|
10302
10302
|
Pe.prototype.print = function(t) {
|
|
10303
10303
|
var e = this;
|
|
@@ -10414,7 +10414,7 @@ fe.isAdjacentSegments = function(t, e) {
|
|
|
10414
10414
|
var He = function() {
|
|
10415
10415
|
this.coord = null, this.segmentIndex = null, this.dist = null;
|
|
10416
10416
|
var t = arguments[0], e = arguments[1], r = arguments[2];
|
|
10417
|
-
this.coord = new
|
|
10417
|
+
this.coord = new v(t), this.segmentIndex = e, this.dist = r;
|
|
10418
10418
|
};
|
|
10419
10419
|
He.prototype.getSegmentIndex = function() {
|
|
10420
10420
|
return this.segmentIndex;
|
|
@@ -10478,7 +10478,7 @@ ar.prototype.createSplitEdge = function(t, e) {
|
|
|
10478
10478
|
var r = this, i = e.segmentIndex - t.segmentIndex + 2, o = this.edge.pts[e.segmentIndex], s = e.dist > 0 || !e.coord.equals2D(o);
|
|
10479
10479
|
s || i--;
|
|
10480
10480
|
var a = new Array(i).fill(null), u = 0;
|
|
10481
|
-
a[u++] = new
|
|
10481
|
+
a[u++] = new v(t.coord);
|
|
10482
10482
|
for (var l = t.segmentIndex + 1; l <= e.segmentIndex; l++)
|
|
10483
10483
|
a[u++] = r.edge.pts[l];
|
|
10484
10484
|
return s && (a[u] = e.coord), new ji(a, new Q(this.edge._label));
|
|
@@ -10504,7 +10504,7 @@ ar.prototype.getClass = function() {
|
|
|
10504
10504
|
var tn = function() {
|
|
10505
10505
|
};
|
|
10506
10506
|
tn.prototype.getChainStartIndices = function(t) {
|
|
10507
|
-
var e = this, r = 0, i = new
|
|
10507
|
+
var e = this, r = 0, i = new S();
|
|
10508
10508
|
i.add(new ke(r));
|
|
10509
10509
|
do {
|
|
10510
10510
|
var o = e.findChainEnd(t, r);
|
|
@@ -10556,13 +10556,13 @@ xr.prototype.computeIntersectsForChain = function() {
|
|
|
10556
10556
|
var t = arguments[0], e = arguments[1], r = arguments[2], i = arguments[3];
|
|
10557
10557
|
this.computeIntersectsForChain(this.startIndex[t], this.startIndex[t + 1], e, e.startIndex[r], e.startIndex[r + 1], i);
|
|
10558
10558
|
} else if (arguments.length === 6) {
|
|
10559
|
-
var o = arguments[0], s = arguments[1], a = arguments[2], u = arguments[3], l = arguments[4], c = arguments[5], f = this.pts[o], h = this.pts[s],
|
|
10559
|
+
var o = arguments[0], s = arguments[1], a = arguments[2], u = arguments[3], l = arguments[4], c = arguments[5], f = this.pts[o], h = this.pts[s], p = a.pts[u], g = a.pts[l];
|
|
10560
10560
|
if (s - o === 1 && l - u === 1)
|
|
10561
10561
|
return c.addIntersections(this.e, o, a.e, u), null;
|
|
10562
|
-
if (this.env1.init(f, h), this.env2.init(
|
|
10562
|
+
if (this.env1.init(f, h), this.env2.init(p, g), !this.env1.intersects(this.env2))
|
|
10563
10563
|
return null;
|
|
10564
|
-
var
|
|
10565
|
-
o <
|
|
10564
|
+
var m = Math.trunc((o + s) / 2), d = Math.trunc((u + l) / 2);
|
|
10565
|
+
o < m && (u < d && this.computeIntersectsForChain(o, m, a, u, d, c), d < l && this.computeIntersectsForChain(o, m, a, d, l, c)), m < s && (u < d && this.computeIntersectsForChain(m, s, a, u, d, c), d < l && this.computeIntersectsForChain(m, s, a, d, l, c));
|
|
10566
10566
|
}
|
|
10567
10567
|
};
|
|
10568
10568
|
xr.prototype.getStartIndexes = function() {
|
|
@@ -10734,7 +10734,7 @@ var ji = function(n) {
|
|
|
10734
10734
|
}
|
|
10735
10735
|
return this._env;
|
|
10736
10736
|
}, t.prototype.addIntersection = function(r, i, o, s) {
|
|
10737
|
-
var a = new
|
|
10737
|
+
var a = new v(r.getIntersection(s)), u = i, l = r.getEdgeDistance(o, s), c = u + 1;
|
|
10738
10738
|
if (c < this.pts.length) {
|
|
10739
10739
|
var f = this.pts[c];
|
|
10740
10740
|
a.equals2D(f) && (u = c, l = 0);
|
|
@@ -10789,13 +10789,13 @@ qt.prototype.insertUniqueEdge = function(t) {
|
|
|
10789
10789
|
this._edgeList.add(t), t.setDepthDelta(qt.depthDelta(t.getLabel()));
|
|
10790
10790
|
};
|
|
10791
10791
|
qt.prototype.buildSubgraphs = function(t, e) {
|
|
10792
|
-
for (var r = new
|
|
10792
|
+
for (var r = new S(), i = t.iterator(); i.hasNext(); ) {
|
|
10793
10793
|
var o = i.next(), s = o.getRightmostCoordinate(), a = new pn(r), u = a.getDepth(s);
|
|
10794
10794
|
o.computeDepth(u), o.findResultEdges(), r.add(o), e.add(o.getDirectedEdges(), o.getNodes());
|
|
10795
10795
|
}
|
|
10796
10796
|
};
|
|
10797
10797
|
qt.prototype.createSubgraphs = function(t) {
|
|
10798
|
-
for (var e = new
|
|
10798
|
+
for (var e = new S(), r = t.getNodes().iterator(); r.hasNext(); ) {
|
|
10799
10799
|
var i = r.next();
|
|
10800
10800
|
if (!i.isVisited()) {
|
|
10801
10801
|
var o = new Yt();
|
|
@@ -10854,7 +10854,7 @@ qt.depthDelta = function(t) {
|
|
|
10854
10854
|
return e === y.INTERIOR && r === y.EXTERIOR ? 1 : e === y.EXTERIOR && r === y.INTERIOR ? -1 : 0;
|
|
10855
10855
|
};
|
|
10856
10856
|
qt.convertSegStrings = function(t) {
|
|
10857
|
-
for (var e = new k(), r = new
|
|
10857
|
+
for (var e = new k(), r = new S(); t.hasNext(); ) {
|
|
10858
10858
|
var i = t.next(), o = e.createLineString(i.getCoordinates());
|
|
10859
10859
|
r.add(o);
|
|
10860
10860
|
}
|
|
@@ -10885,14 +10885,14 @@ Br.prototype.rescale = function() {
|
|
|
10885
10885
|
Br.prototype.scale = function() {
|
|
10886
10886
|
var t = this;
|
|
10887
10887
|
if (T(arguments[0], _t)) {
|
|
10888
|
-
for (var e = arguments[0], r = new
|
|
10888
|
+
for (var e = arguments[0], r = new S(), i = e.iterator(); i.hasNext(); ) {
|
|
10889
10889
|
var o = i.next();
|
|
10890
10890
|
r.add(new dt(t.scale(o.getCoordinates()), o.getData()));
|
|
10891
10891
|
}
|
|
10892
10892
|
return r;
|
|
10893
10893
|
} else if (arguments[0] instanceof Array) {
|
|
10894
10894
|
for (var s = arguments[0], a = new Array(s.length).fill(null), u = 0; u < s.length; u++)
|
|
10895
|
-
a[u] = new
|
|
10895
|
+
a[u] = new v(Math.round((s[u].x - t._offsetX) * t._scaleFactor), Math.round((s[u].y - t._offsetY) * t._scaleFactor), s[u].z);
|
|
10896
10896
|
var l = z.removeRepeatedPoints(a);
|
|
10897
10897
|
return l;
|
|
10898
10898
|
}
|
|
@@ -10946,12 +10946,12 @@ We.prototype.checkInteriorIntersections = function() {
|
|
|
10946
10946
|
for (var f = 0; f < l.length - 1; f++)
|
|
10947
10947
|
t.checkInteriorIntersections(s, c, a, f);
|
|
10948
10948
|
else if (arguments.length === 4) {
|
|
10949
|
-
var h = arguments[0],
|
|
10950
|
-
if (h ===
|
|
10949
|
+
var h = arguments[0], p = arguments[1], g = arguments[2], m = arguments[3];
|
|
10950
|
+
if (h === g && p === m)
|
|
10951
10951
|
return null;
|
|
10952
|
-
var
|
|
10953
|
-
if (this._li.computeIntersection(
|
|
10954
|
-
throw new Er("found non-noded intersection at " +
|
|
10952
|
+
var d = h.getCoordinates()[p], E = h.getCoordinates()[p + 1], I = g.getCoordinates()[m], C = g.getCoordinates()[m + 1];
|
|
10953
|
+
if (this._li.computeIntersection(d, E, I, C), this._li.hasIntersection() && (this._li.isProper() || this.hasInteriorIntersection(this._li, d, E) || this.hasInteriorIntersection(this._li, I, C)))
|
|
10954
|
+
throw new Er("found non-noded intersection at " + d + "-" + E + " and " + I + "-" + C);
|
|
10955
10955
|
}
|
|
10956
10956
|
};
|
|
10957
10957
|
We.prototype.checkValid = function() {
|
|
@@ -10995,7 +10995,7 @@ var Jt = function() {
|
|
|
10995
10995
|
var t = arguments[0], e = arguments[1], r = arguments[2];
|
|
10996
10996
|
if (this._originalPt = t, this._pt = t, this._scaleFactor = e, this._li = r, e <= 0)
|
|
10997
10997
|
throw new it("Scale factor must be non-zero");
|
|
10998
|
-
e !== 1 && (this._pt = new
|
|
10998
|
+
e !== 1 && (this._pt = new v(this.scale(t.x), this.scale(t.y)), this._p0Scaled = new v(), this._p1Scaled = new v()), this.initCorners(this._pt);
|
|
10999
10999
|
}, ya = { SAFE_ENV_EXPANSION_FACTOR: { configurable: !0 } };
|
|
11000
11000
|
Jt.prototype.intersectsScaled = function(t, e) {
|
|
11001
11001
|
var r = Math.min(t.x, e.x), i = Math.max(t.x, e.x), o = Math.min(t.y, e.y), s = Math.max(t.y, e.y), a = this._maxx < r || this._minx > i || this._maxy < o || this._miny > s;
|
|
@@ -11006,7 +11006,7 @@ Jt.prototype.intersectsScaled = function(t, e) {
|
|
|
11006
11006
|
};
|
|
11007
11007
|
Jt.prototype.initCorners = function(t) {
|
|
11008
11008
|
var e = 0.5;
|
|
11009
|
-
this._minx = t.x - e, this._maxx = t.x + e, this._miny = t.y - e, this._maxy = t.y + e, this._corner[0] = new
|
|
11009
|
+
this._minx = t.x - e, this._maxx = t.x + e, this._miny = t.y - e, this._maxy = t.y + e, this._corner[0] = new v(this._maxx, this._maxy), this._corner[1] = new v(this._minx, this._maxy), this._corner[2] = new v(this._minx, this._miny), this._corner[3] = new v(this._maxx, this._miny);
|
|
11010
11010
|
};
|
|
11011
11011
|
Jt.prototype.intersects = function(t, e) {
|
|
11012
11012
|
return this._scaleFactor === 1 ? this.intersectsScaled(t, e) : (this.copyScaled(t, this._p0Scaled), this.copyScaled(e, this._p1Scaled), this.intersectsScaled(this._p0Scaled, this._p1Scaled));
|
|
@@ -11121,7 +11121,7 @@ var _a = function(n) {
|
|
|
11121
11121
|
}(Ni), gn = function() {
|
|
11122
11122
|
this._li = null, this._interiorIntersections = null;
|
|
11123
11123
|
var t = arguments[0];
|
|
11124
|
-
this._li = t, this._interiorIntersections = new
|
|
11124
|
+
this._li = t, this._interiorIntersections = new S();
|
|
11125
11125
|
};
|
|
11126
11126
|
gn.prototype.processIntersections = function(t, e, r, i) {
|
|
11127
11127
|
var o = this;
|
|
@@ -11275,20 +11275,20 @@ Pt.bufferOp = function() {
|
|
|
11275
11275
|
var t = arguments[0], e = arguments[1], r = new Pt(t), i = r.getResultGeometry(e);
|
|
11276
11276
|
return i;
|
|
11277
11277
|
} else if (arguments.length === 3) {
|
|
11278
|
-
if (Number.isInteger(arguments[2]) && arguments[0] instanceof
|
|
11278
|
+
if (Number.isInteger(arguments[2]) && arguments[0] instanceof D && typeof arguments[1] == "number") {
|
|
11279
11279
|
var o = arguments[0], s = arguments[1], a = arguments[2], u = new Pt(o);
|
|
11280
11280
|
u.setQuadrantSegments(a);
|
|
11281
11281
|
var l = u.getResultGeometry(s);
|
|
11282
11282
|
return l;
|
|
11283
|
-
} else if (arguments[2] instanceof H && arguments[0] instanceof
|
|
11284
|
-
var c = arguments[0], f = arguments[1], h = arguments[2],
|
|
11285
|
-
return
|
|
11283
|
+
} else if (arguments[2] instanceof H && arguments[0] instanceof D && typeof arguments[1] == "number") {
|
|
11284
|
+
var c = arguments[0], f = arguments[1], h = arguments[2], p = new Pt(c, h), g = p.getResultGeometry(f);
|
|
11285
|
+
return g;
|
|
11286
11286
|
}
|
|
11287
11287
|
} else if (arguments.length === 4) {
|
|
11288
|
-
var
|
|
11288
|
+
var m = arguments[0], d = arguments[1], E = arguments[2], I = arguments[3], C = new Pt(m);
|
|
11289
11289
|
C.setQuadrantSegments(E), C.setEndCapStyle(I);
|
|
11290
|
-
var
|
|
11291
|
-
return
|
|
11290
|
+
var x = C.getResultGeometry(d);
|
|
11291
|
+
return x;
|
|
11292
11292
|
}
|
|
11293
11293
|
};
|
|
11294
11294
|
Pt.precisionScaleFactor = function(t, e, r) {
|
|
@@ -11312,7 +11312,7 @@ ri.MAX_PRECISION_DIGITS.get = function() {
|
|
|
11312
11312
|
};
|
|
11313
11313
|
Object.defineProperties(Pt, ri);
|
|
11314
11314
|
var kt = function() {
|
|
11315
|
-
this._pt = [new
|
|
11315
|
+
this._pt = [new v(), new v()], this._distance = A.NaN, this._isNull = !0;
|
|
11316
11316
|
};
|
|
11317
11317
|
kt.prototype.getCoordinates = function() {
|
|
11318
11318
|
return this._pt;
|
|
@@ -11373,33 +11373,33 @@ $e.prototype.getClass = function() {
|
|
|
11373
11373
|
return $e;
|
|
11374
11374
|
};
|
|
11375
11375
|
$e.computeDistance = function() {
|
|
11376
|
-
if (arguments[2] instanceof kt && arguments[0] instanceof ut && arguments[1] instanceof
|
|
11376
|
+
if (arguments[2] instanceof kt && arguments[0] instanceof ut && arguments[1] instanceof v)
|
|
11377
11377
|
for (var t = arguments[0], e = arguments[1], r = arguments[2], i = t.getCoordinates(), o = new b(), s = 0; s < i.length - 1; s++) {
|
|
11378
11378
|
o.setCoordinates(i[s], i[s + 1]);
|
|
11379
11379
|
var a = o.closestPoint(e);
|
|
11380
11380
|
r.setMinimum(a, e);
|
|
11381
11381
|
}
|
|
11382
|
-
else if (arguments[2] instanceof kt && arguments[0] instanceof Nt && arguments[1] instanceof
|
|
11382
|
+
else if (arguments[2] instanceof kt && arguments[0] instanceof Nt && arguments[1] instanceof v) {
|
|
11383
11383
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
11384
11384
|
$e.computeDistance(u.getExteriorRing(), l, c);
|
|
11385
11385
|
for (var f = 0; f < u.getNumInteriorRing(); f++)
|
|
11386
11386
|
$e.computeDistance(u.getInteriorRingN(f), l, c);
|
|
11387
|
-
} else if (arguments[2] instanceof kt && arguments[0] instanceof
|
|
11388
|
-
var h = arguments[0],
|
|
11387
|
+
} else if (arguments[2] instanceof kt && arguments[0] instanceof D && arguments[1] instanceof v) {
|
|
11388
|
+
var h = arguments[0], p = arguments[1], g = arguments[2];
|
|
11389
11389
|
if (h instanceof ut)
|
|
11390
|
-
$e.computeDistance(h,
|
|
11390
|
+
$e.computeDistance(h, p, g);
|
|
11391
11391
|
else if (h instanceof Nt)
|
|
11392
|
-
$e.computeDistance(h,
|
|
11392
|
+
$e.computeDistance(h, p, g);
|
|
11393
11393
|
else if (h instanceof Xt)
|
|
11394
|
-
for (var
|
|
11395
|
-
var E =
|
|
11396
|
-
$e.computeDistance(E,
|
|
11394
|
+
for (var m = h, d = 0; d < m.getNumGeometries(); d++) {
|
|
11395
|
+
var E = m.getGeometryN(d);
|
|
11396
|
+
$e.computeDistance(E, p, g);
|
|
11397
11397
|
}
|
|
11398
11398
|
else
|
|
11399
|
-
|
|
11400
|
-
} else if (arguments[2] instanceof kt && arguments[0] instanceof b && arguments[1] instanceof
|
|
11401
|
-
var I = arguments[0], C = arguments[1],
|
|
11402
|
-
|
|
11399
|
+
g.setMinimum(h.getCoordinate(), p);
|
|
11400
|
+
} else if (arguments[2] instanceof kt && arguments[0] instanceof b && arguments[1] instanceof v) {
|
|
11401
|
+
var I = arguments[0], C = arguments[1], x = arguments[2], R = I.closestPoint(C);
|
|
11402
|
+
x.setMinimum(R, C);
|
|
11403
11403
|
}
|
|
11404
11404
|
};
|
|
11405
11405
|
var en = function(t) {
|
|
@@ -11453,7 +11453,7 @@ var Gr = function(t) {
|
|
|
11453
11453
|
Gr.prototype.filter = function(t, e) {
|
|
11454
11454
|
if (e === 0)
|
|
11455
11455
|
return null;
|
|
11456
|
-
var r = t.getCoordinate(e - 1), i = t.getCoordinate(e), o = new
|
|
11456
|
+
var r = t.getCoordinate(e - 1), i = t.getCoordinate(e), o = new v((r.x + i.x) / 2, (r.y + i.y) / 2);
|
|
11457
11457
|
this._minPtDist.initialize(), $e.computeDistance(this._geom, o, this._minPtDist), this._maxPtDist.setMaximum(this._minPtDist);
|
|
11458
11458
|
};
|
|
11459
11459
|
Gr.prototype.isDone = function() {
|
|
@@ -11486,7 +11486,7 @@ _r.prototype.getClass = function() {
|
|
|
11486
11486
|
_r.getPolygons = function() {
|
|
11487
11487
|
if (arguments.length === 1) {
|
|
11488
11488
|
var t = arguments[0];
|
|
11489
|
-
return _r.getPolygons(t, new
|
|
11489
|
+
return _r.getPolygons(t, new S());
|
|
11490
11490
|
} else if (arguments.length === 2) {
|
|
11491
11491
|
var e = arguments[0], r = arguments[1];
|
|
11492
11492
|
return e instanceof Nt ? r.add(e) : e instanceof Xt && e.apply(new _r(r)), r;
|
|
@@ -11537,23 +11537,23 @@ wt.getLines = function() {
|
|
|
11537
11537
|
wt.getLines(o, r);
|
|
11538
11538
|
}
|
|
11539
11539
|
return r;
|
|
11540
|
-
} else if (arguments[0] instanceof
|
|
11541
|
-
var s = arguments[0], a = arguments[1], u = new
|
|
11540
|
+
} else if (arguments[0] instanceof D && typeof arguments[1] == "boolean") {
|
|
11541
|
+
var s = arguments[0], a = arguments[1], u = new S();
|
|
11542
11542
|
return s.apply(new wt(u, a)), u;
|
|
11543
|
-
} else if (arguments[0] instanceof
|
|
11543
|
+
} else if (arguments[0] instanceof D && T(arguments[1], _t)) {
|
|
11544
11544
|
var l = arguments[0], c = arguments[1];
|
|
11545
11545
|
return l instanceof ut ? c.add(l) : l.apply(new wt(c)), c;
|
|
11546
11546
|
}
|
|
11547
11547
|
} else if (arguments.length === 3) {
|
|
11548
11548
|
if (typeof arguments[2] == "boolean" && T(arguments[0], _t) && T(arguments[1], _t)) {
|
|
11549
|
-
for (var f = arguments[0], h = arguments[1],
|
|
11550
|
-
var
|
|
11551
|
-
wt.getLines(
|
|
11549
|
+
for (var f = arguments[0], h = arguments[1], p = arguments[2], g = f.iterator(); g.hasNext(); ) {
|
|
11550
|
+
var m = g.next();
|
|
11551
|
+
wt.getLines(m, h, p);
|
|
11552
11552
|
}
|
|
11553
11553
|
return h;
|
|
11554
|
-
} else if (typeof arguments[2] == "boolean" && arguments[0] instanceof
|
|
11555
|
-
var
|
|
11556
|
-
return
|
|
11554
|
+
} else if (typeof arguments[2] == "boolean" && arguments[0] instanceof D && T(arguments[1], _t)) {
|
|
11555
|
+
var d = arguments[0], E = arguments[1], I = arguments[2];
|
|
11556
|
+
return d.apply(new wt(E, I)), E;
|
|
11557
11557
|
}
|
|
11558
11558
|
}
|
|
11559
11559
|
};
|
|
@@ -11569,7 +11569,7 @@ var be = function() {
|
|
|
11569
11569
|
};
|
|
11570
11570
|
be.prototype.locateInternal = function() {
|
|
11571
11571
|
var t = this;
|
|
11572
|
-
if (arguments[0] instanceof
|
|
11572
|
+
if (arguments[0] instanceof v && arguments[1] instanceof Nt) {
|
|
11573
11573
|
var e = arguments[0], r = arguments[1];
|
|
11574
11574
|
if (r.isEmpty())
|
|
11575
11575
|
return y.EXTERIOR;
|
|
@@ -11586,15 +11586,15 @@ be.prototype.locateInternal = function() {
|
|
|
11586
11586
|
return y.BOUNDARY;
|
|
11587
11587
|
}
|
|
11588
11588
|
return y.INTERIOR;
|
|
11589
|
-
} else if (arguments[0] instanceof
|
|
11589
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof ut) {
|
|
11590
11590
|
var l = arguments[0], c = arguments[1];
|
|
11591
11591
|
if (!c.getEnvelopeInternal().intersects(l))
|
|
11592
11592
|
return y.EXTERIOR;
|
|
11593
11593
|
var f = c.getCoordinates();
|
|
11594
11594
|
return !c.isClosed() && (l.equals(f[0]) || l.equals(f[f.length - 1])) ? y.BOUNDARY : L.isOnLine(l, f) ? y.INTERIOR : y.EXTERIOR;
|
|
11595
|
-
} else if (arguments[0] instanceof
|
|
11596
|
-
var h = arguments[0],
|
|
11597
|
-
return
|
|
11595
|
+
} else if (arguments[0] instanceof v && arguments[1] instanceof te) {
|
|
11596
|
+
var h = arguments[0], p = arguments[1], g = p.getCoordinate();
|
|
11597
|
+
return g.equals2D(h) ? y.INTERIOR : y.EXTERIOR;
|
|
11598
11598
|
}
|
|
11599
11599
|
};
|
|
11600
11600
|
be.prototype.locateInPolygonRing = function(t, e) {
|
|
@@ -11683,7 +11683,7 @@ Or.prototype.getClass = function() {
|
|
|
11683
11683
|
Or.getPoints = function() {
|
|
11684
11684
|
if (arguments.length === 1) {
|
|
11685
11685
|
var t = arguments[0];
|
|
11686
|
-
return t instanceof te ? we.singletonList(t) : Or.getPoints(t, new
|
|
11686
|
+
return t instanceof te ? we.singletonList(t) : Or.getPoints(t, new S());
|
|
11687
11687
|
} else if (arguments.length === 2) {
|
|
11688
11688
|
var e = arguments[0], r = arguments[1];
|
|
11689
11689
|
return e instanceof te ? r.add(e) : e instanceof Xt && e.apply(new Or(r)), r;
|
|
@@ -11704,7 +11704,7 @@ vn.prototype.getClass = function() {
|
|
|
11704
11704
|
return vn;
|
|
11705
11705
|
};
|
|
11706
11706
|
vn.getLocations = function(t) {
|
|
11707
|
-
var e = new
|
|
11707
|
+
var e = new S();
|
|
11708
11708
|
return t.apply(new vn(e)), e;
|
|
11709
11709
|
};
|
|
11710
11710
|
var Ot = function() {
|
|
@@ -11733,13 +11733,13 @@ Ot.prototype.computeContainmentDistance = function() {
|
|
|
11733
11733
|
} else if (arguments.length === 3) {
|
|
11734
11734
|
if (arguments[2] instanceof Array && T(arguments[0], Ne) && T(arguments[1], Ne)) {
|
|
11735
11735
|
for (var u = arguments[0], l = arguments[1], c = arguments[2], f = 0; f < u.size(); f++)
|
|
11736
|
-
for (var h = u.get(f),
|
|
11737
|
-
if (t.computeContainmentDistance(h, l.get(
|
|
11736
|
+
for (var h = u.get(f), p = 0; p < l.size(); p++)
|
|
11737
|
+
if (t.computeContainmentDistance(h, l.get(p), c), t._minDistance <= t._terminateDistance)
|
|
11738
11738
|
return null;
|
|
11739
11739
|
} else if (arguments[2] instanceof Array && arguments[0] instanceof zt && arguments[1] instanceof Nt) {
|
|
11740
|
-
var
|
|
11741
|
-
if (y.EXTERIOR !== this._ptLocator.locate(E,
|
|
11742
|
-
return this._minDistance = 0,
|
|
11740
|
+
var g = arguments[0], m = arguments[1], d = arguments[2], E = g.getCoordinate();
|
|
11741
|
+
if (y.EXTERIOR !== this._ptLocator.locate(E, m))
|
|
11742
|
+
return this._minDistance = 0, d[0] = g, d[1] = new zt(m, E), null;
|
|
11743
11743
|
}
|
|
11744
11744
|
}
|
|
11745
11745
|
};
|
|
@@ -11792,16 +11792,16 @@ Ot.prototype.computeMinDistance = function() {
|
|
|
11792
11792
|
return null;
|
|
11793
11793
|
}
|
|
11794
11794
|
} else if (arguments[2] instanceof Array && arguments[0] instanceof ut && arguments[1] instanceof ut) {
|
|
11795
|
-
var f = arguments[0], h = arguments[1],
|
|
11795
|
+
var f = arguments[0], h = arguments[1], p = arguments[2];
|
|
11796
11796
|
if (f.getEnvelopeInternal().distance(h.getEnvelopeInternal()) > this._minDistance)
|
|
11797
11797
|
return null;
|
|
11798
|
-
for (var
|
|
11799
|
-
for (var E = 0; E <
|
|
11800
|
-
var I = L.distanceLineLine(
|
|
11798
|
+
for (var g = f.getCoordinates(), m = h.getCoordinates(), d = 0; d < g.length - 1; d++)
|
|
11799
|
+
for (var E = 0; E < m.length - 1; E++) {
|
|
11800
|
+
var I = L.distanceLineLine(g[d], g[d + 1], m[E], m[E + 1]);
|
|
11801
11801
|
if (I < t._minDistance) {
|
|
11802
11802
|
t._minDistance = I;
|
|
11803
|
-
var C = new b(
|
|
11804
|
-
|
|
11803
|
+
var C = new b(g[d], g[d + 1]), x = new b(m[E], m[E + 1]), R = C.closestPoints(x);
|
|
11804
|
+
p[0] = new zt(f, d, R[0]), p[1] = new zt(h, E, R[1]);
|
|
11805
11805
|
}
|
|
11806
11806
|
if (t._minDistance <= t._terminateDistance)
|
|
11807
11807
|
return null;
|
|
@@ -11849,7 +11849,7 @@ Ot.nearestPoints = function(t, e) {
|
|
|
11849
11849
|
return r.nearestPoints();
|
|
11850
11850
|
};
|
|
11851
11851
|
var Mt = function() {
|
|
11852
|
-
this._pt = [new
|
|
11852
|
+
this._pt = [new v(), new v()], this._distance = A.NaN, this._isNull = !0;
|
|
11853
11853
|
};
|
|
11854
11854
|
Mt.prototype.getCoordinates = function() {
|
|
11855
11855
|
return this._pt;
|
|
@@ -11913,33 +11913,33 @@ Be.prototype.getClass = function() {
|
|
|
11913
11913
|
return Be;
|
|
11914
11914
|
};
|
|
11915
11915
|
Be.computeDistance = function() {
|
|
11916
|
-
if (arguments[2] instanceof Mt && arguments[0] instanceof ut && arguments[1] instanceof
|
|
11916
|
+
if (arguments[2] instanceof Mt && arguments[0] instanceof ut && arguments[1] instanceof v)
|
|
11917
11917
|
for (var t = arguments[0], e = arguments[1], r = arguments[2], i = new b(), o = t.getCoordinates(), s = 0; s < o.length - 1; s++) {
|
|
11918
11918
|
i.setCoordinates(o[s], o[s + 1]);
|
|
11919
11919
|
var a = i.closestPoint(e);
|
|
11920
11920
|
r.setMinimum(a, e);
|
|
11921
11921
|
}
|
|
11922
|
-
else if (arguments[2] instanceof Mt && arguments[0] instanceof Nt && arguments[1] instanceof
|
|
11922
|
+
else if (arguments[2] instanceof Mt && arguments[0] instanceof Nt && arguments[1] instanceof v) {
|
|
11923
11923
|
var u = arguments[0], l = arguments[1], c = arguments[2];
|
|
11924
11924
|
Be.computeDistance(u.getExteriorRing(), l, c);
|
|
11925
11925
|
for (var f = 0; f < u.getNumInteriorRing(); f++)
|
|
11926
11926
|
Be.computeDistance(u.getInteriorRingN(f), l, c);
|
|
11927
|
-
} else if (arguments[2] instanceof Mt && arguments[0] instanceof
|
|
11928
|
-
var h = arguments[0],
|
|
11927
|
+
} else if (arguments[2] instanceof Mt && arguments[0] instanceof D && arguments[1] instanceof v) {
|
|
11928
|
+
var h = arguments[0], p = arguments[1], g = arguments[2];
|
|
11929
11929
|
if (h instanceof ut)
|
|
11930
|
-
Be.computeDistance(h,
|
|
11930
|
+
Be.computeDistance(h, p, g);
|
|
11931
11931
|
else if (h instanceof Nt)
|
|
11932
|
-
Be.computeDistance(h,
|
|
11932
|
+
Be.computeDistance(h, p, g);
|
|
11933
11933
|
else if (h instanceof Xt)
|
|
11934
|
-
for (var
|
|
11935
|
-
var E =
|
|
11936
|
-
Be.computeDistance(E,
|
|
11934
|
+
for (var m = h, d = 0; d < m.getNumGeometries(); d++) {
|
|
11935
|
+
var E = m.getGeometryN(d);
|
|
11936
|
+
Be.computeDistance(E, p, g);
|
|
11937
11937
|
}
|
|
11938
11938
|
else
|
|
11939
|
-
|
|
11940
|
-
} else if (arguments[2] instanceof Mt && arguments[0] instanceof b && arguments[1] instanceof
|
|
11941
|
-
var I = arguments[0], C = arguments[1],
|
|
11942
|
-
|
|
11939
|
+
g.setMinimum(h.getCoordinate(), p);
|
|
11940
|
+
} else if (arguments[2] instanceof Mt && arguments[0] instanceof b && arguments[1] instanceof v) {
|
|
11941
|
+
var I = arguments[0], C = arguments[1], x = arguments[2], R = I.closestPoint(C);
|
|
11942
|
+
x.setMinimum(R, C);
|
|
11943
11943
|
}
|
|
11944
11944
|
};
|
|
11945
11945
|
var ve = function() {
|
|
@@ -12020,7 +12020,7 @@ Vr.prototype.filter = function(t, e) {
|
|
|
12020
12020
|
if (e === 0)
|
|
12021
12021
|
return null;
|
|
12022
12022
|
for (var i = t.getCoordinate(e - 1), o = t.getCoordinate(e), s = (o.x - i.x) / this._numSubSegs, a = (o.y - i.y) / this._numSubSegs, u = 0; u < this._numSubSegs; u++) {
|
|
12023
|
-
var l = i.x + u * s, c = i.y + u * a, f = new
|
|
12023
|
+
var l = i.x + u * s, c = i.y + u * a, f = new v(l, c);
|
|
12024
12024
|
r._minPtDist.initialize(), Be.computeDistance(r._geom, f, r._minPtDist), r._maxPtDist.setMaximum(r._minPtDist);
|
|
12025
12025
|
}
|
|
12026
12026
|
};
|
|
@@ -12083,7 +12083,7 @@ $t.prototype.getErrorLocation = function() {
|
|
|
12083
12083
|
return this._errorLocation;
|
|
12084
12084
|
};
|
|
12085
12085
|
$t.prototype.getPolygonLines = function(t) {
|
|
12086
|
-
for (var e = new
|
|
12086
|
+
for (var e = new S(), r = new wt(e), i = _r.getPolygons(t), o = i.iterator(); o.hasNext(); ) {
|
|
12087
12087
|
var s = o.next();
|
|
12088
12088
|
s.apply(r);
|
|
12089
12089
|
}
|
|
@@ -12208,7 +12208,7 @@ je.prototype.getClass = function() {
|
|
|
12208
12208
|
return je;
|
|
12209
12209
|
};
|
|
12210
12210
|
var St = function() {
|
|
12211
|
-
this._findAllIntersections = !1, this._isCheckEndSegmentsOnly = !1, this._li = null, this._interiorIntersection = null, this._intSegments = null, this._intersections = new
|
|
12211
|
+
this._findAllIntersections = !1, this._isCheckEndSegmentsOnly = !1, this._li = null, this._interiorIntersection = null, this._intSegments = null, this._intersections = new S(), this._intersectionCount = 0, this._keepIntersections = !0;
|
|
12212
12212
|
var t = arguments[0];
|
|
12213
12213
|
this._li = t, this._interiorIntersection = null;
|
|
12214
12214
|
};
|
|
@@ -12330,7 +12330,7 @@ rn.prototype.getClass = function() {
|
|
|
12330
12330
|
return rn;
|
|
12331
12331
|
};
|
|
12332
12332
|
rn.toSegmentStrings = function(t) {
|
|
12333
|
-
for (var e = new
|
|
12333
|
+
for (var e = new S(), r = t.iterator(); r.hasNext(); ) {
|
|
12334
12334
|
var i = r.next();
|
|
12335
12335
|
e.add(new je(i.getCoordinates(), i));
|
|
12336
12336
|
}
|
|
@@ -12344,7 +12344,7 @@ var mn = function(t) {
|
|
|
12344
12344
|
this._mapOp = t;
|
|
12345
12345
|
};
|
|
12346
12346
|
mn.prototype.map = function(t) {
|
|
12347
|
-
for (var e = this, r = new
|
|
12347
|
+
for (var e = this, r = new S(), i = 0; i < t.getNumGeometries(); i++) {
|
|
12348
12348
|
var o = e._mapOp.map(t.getGeometryN(i));
|
|
12349
12349
|
o.isEmpty() || r.add(o);
|
|
12350
12350
|
}
|
|
@@ -12361,7 +12361,7 @@ mn.map = function(t, e) {
|
|
|
12361
12361
|
return r.map(t);
|
|
12362
12362
|
};
|
|
12363
12363
|
var Ke = function() {
|
|
12364
|
-
this._op = null, this._geometryFactory = null, this._ptLocator = null, this._lineEdgesList = new
|
|
12364
|
+
this._op = null, this._geometryFactory = null, this._ptLocator = null, this._lineEdgesList = new S(), this._resultLineList = new S();
|
|
12365
12365
|
var t = arguments[0], e = arguments[1], r = arguments[2];
|
|
12366
12366
|
this._op = t, this._geometryFactory = e, this._ptLocator = r;
|
|
12367
12367
|
};
|
|
@@ -12420,7 +12420,7 @@ Ke.prototype.getClass = function() {
|
|
|
12420
12420
|
return Ke;
|
|
12421
12421
|
};
|
|
12422
12422
|
var _n = function() {
|
|
12423
|
-
this._op = null, this._geometryFactory = null, this._resultPointList = new
|
|
12423
|
+
this._op = null, this._geometryFactory = null, this._resultPointList = new S();
|
|
12424
12424
|
var t = arguments[0], e = arguments[1];
|
|
12425
12425
|
this._op = t, this._geometryFactory = e;
|
|
12426
12426
|
};
|
|
@@ -12458,13 +12458,13 @@ Zt.prototype.transformPoint = function(t, e) {
|
|
|
12458
12458
|
Zt.prototype.transformPolygon = function(t, e) {
|
|
12459
12459
|
var r = this, i = !0, o = this.transformLinearRing(t.getExteriorRing(), t);
|
|
12460
12460
|
(o === null || !(o instanceof ir) || o.isEmpty()) && (i = !1);
|
|
12461
|
-
for (var s = new
|
|
12461
|
+
for (var s = new S(), a = 0; a < t.getNumInteriorRing(); a++) {
|
|
12462
12462
|
var u = r.transformLinearRing(t.getInteriorRingN(a), t);
|
|
12463
12463
|
u === null || u.isEmpty() || (u instanceof ir || (i = !1), s.add(u));
|
|
12464
12464
|
}
|
|
12465
12465
|
if (i)
|
|
12466
12466
|
return this._factory.createPolygon(o, s.toArray([]));
|
|
12467
|
-
var l = new
|
|
12467
|
+
var l = new S();
|
|
12468
12468
|
return o !== null && l.add(o), l.addAll(s), this._factory.buildGeometry(l);
|
|
12469
12469
|
};
|
|
12470
12470
|
Zt.prototype.createCoordinateSequence = function(t) {
|
|
@@ -12474,7 +12474,7 @@ Zt.prototype.getInputGeometry = function() {
|
|
|
12474
12474
|
return this._inputGeom;
|
|
12475
12475
|
};
|
|
12476
12476
|
Zt.prototype.transformMultiLineString = function(t, e) {
|
|
12477
|
-
for (var r = this, i = new
|
|
12477
|
+
for (var r = this, i = new S(), o = 0; o < t.getNumGeometries(); o++) {
|
|
12478
12478
|
var s = r.transformLineString(t.getGeometryN(o), t);
|
|
12479
12479
|
s !== null && (s.isEmpty() || i.add(s));
|
|
12480
12480
|
}
|
|
@@ -12487,14 +12487,14 @@ Zt.prototype.transformLineString = function(t, e) {
|
|
|
12487
12487
|
return this._factory.createLineString(this.transformCoordinates(t.getCoordinateSequence(), t));
|
|
12488
12488
|
};
|
|
12489
12489
|
Zt.prototype.transformMultiPoint = function(t, e) {
|
|
12490
|
-
for (var r = this, i = new
|
|
12490
|
+
for (var r = this, i = new S(), o = 0; o < t.getNumGeometries(); o++) {
|
|
12491
12491
|
var s = r.transformPoint(t.getGeometryN(o), t);
|
|
12492
12492
|
s !== null && (s.isEmpty() || i.add(s));
|
|
12493
12493
|
}
|
|
12494
12494
|
return this._factory.buildGeometry(i);
|
|
12495
12495
|
};
|
|
12496
12496
|
Zt.prototype.transformMultiPolygon = function(t, e) {
|
|
12497
|
-
for (var r = this, i = new
|
|
12497
|
+
for (var r = this, i = new S(), o = 0; o < t.getNumGeometries(); o++) {
|
|
12498
12498
|
var s = r.transformPolygon(t.getGeometryN(o), t);
|
|
12499
12499
|
s !== null && (s.isEmpty() || i.add(s));
|
|
12500
12500
|
}
|
|
@@ -12504,7 +12504,7 @@ Zt.prototype.copy = function(t) {
|
|
|
12504
12504
|
return t.copy();
|
|
12505
12505
|
};
|
|
12506
12506
|
Zt.prototype.transformGeometryCollection = function(t, e) {
|
|
12507
|
-
for (var r = this, i = new
|
|
12507
|
+
for (var r = this, i = new S(), o = 0; o < t.getNumGeometries(); o++) {
|
|
12508
12508
|
var s = r.transform(t.getGeometryN(o));
|
|
12509
12509
|
s !== null && (r._pruneEmptyGeometry && s.isEmpty() || i.add(s));
|
|
12510
12510
|
}
|
|
@@ -12554,7 +12554,7 @@ var lr = function n() {
|
|
|
12554
12554
|
lr.prototype.snapVertices = function(t, e) {
|
|
12555
12555
|
for (var r = this, i = this._isClosed ? t.size() - 1 : t.size(), o = 0; o < i; o++) {
|
|
12556
12556
|
var s = t.get(o), a = r.findSnapForVertex(s, e);
|
|
12557
|
-
a !== null && (t.set(o, new
|
|
12557
|
+
a !== null && (t.set(o, new v(a)), o === 0 && r._isClosed && t.set(t.size() - 1, new v(a)));
|
|
12558
12558
|
}
|
|
12559
12559
|
};
|
|
12560
12560
|
lr.prototype.findSnapForVertex = function(t, e) {
|
|
@@ -12580,7 +12580,7 @@ lr.prototype.snapSegments = function(t, e) {
|
|
|
12580
12580
|
e[0].equals2D(e[e.length - 1]) && (i = e.length - 1);
|
|
12581
12581
|
for (var o = 0; o < i; o++) {
|
|
12582
12582
|
var s = e[o], a = r.findSegmentIndexToSnap(s, t);
|
|
12583
|
-
a >= 0 && t.add(a + 1, new
|
|
12583
|
+
a >= 0 && t.add(a + 1, new v(s), !1);
|
|
12584
12584
|
}
|
|
12585
12585
|
};
|
|
12586
12586
|
lr.prototype.findSegmentIndexToSnap = function(t, e) {
|
|
@@ -12742,7 +12742,7 @@ kr.prototype.addCommonBits = function(t) {
|
|
|
12742
12742
|
kr.prototype.removeCommonBits = function(t) {
|
|
12743
12743
|
if (this._commonCoord.x === 0 && this._commonCoord.y === 0)
|
|
12744
12744
|
return t;
|
|
12745
|
-
var e = new
|
|
12745
|
+
var e = new v(this._commonCoord);
|
|
12746
12746
|
e.x = -e.x, e.y = -e.y;
|
|
12747
12747
|
var r = new zr(e);
|
|
12748
12748
|
return t.apply(r), t.geometryChanged(), t;
|
|
@@ -12773,7 +12773,7 @@ En.prototype.filter = function(t) {
|
|
|
12773
12773
|
this._commonBitsX.add(t.x), this._commonBitsY.add(t.y);
|
|
12774
12774
|
};
|
|
12775
12775
|
En.prototype.getCommonCoordinate = function() {
|
|
12776
|
-
return new
|
|
12776
|
+
return new v(this._commonBitsX.getCommon(), this._commonBitsY.getCommon());
|
|
12777
12777
|
};
|
|
12778
12778
|
En.prototype.interfaces_ = function() {
|
|
12779
12779
|
return [nr];
|
|
@@ -13036,7 +13036,7 @@ Tt.isAdjacentSegments = function(t, e) {
|
|
|
13036
13036
|
};
|
|
13037
13037
|
var Qu = function(n) {
|
|
13038
13038
|
function t() {
|
|
13039
|
-
n.call(this), this.events = new
|
|
13039
|
+
n.call(this), this.events = new S(), this.nOverlaps = null;
|
|
13040
13040
|
}
|
|
13041
13041
|
return n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t, t.prototype.prepareEvents = function() {
|
|
13042
13042
|
var r = this;
|
|
@@ -13107,7 +13107,7 @@ cr.prototype.getMax = function() {
|
|
|
13107
13107
|
return this._max;
|
|
13108
13108
|
};
|
|
13109
13109
|
cr.prototype.toString = function() {
|
|
13110
|
-
return xe.toLineString(new
|
|
13110
|
+
return xe.toLineString(new v(this._min, 0), new v(this._max, 0));
|
|
13111
13111
|
};
|
|
13112
13112
|
cr.prototype.interfaces_ = function() {
|
|
13113
13113
|
return [];
|
|
@@ -13164,12 +13164,12 @@ var Ju = function(n) {
|
|
|
13164
13164
|
return t;
|
|
13165
13165
|
}, t;
|
|
13166
13166
|
}(cr), fr = function() {
|
|
13167
|
-
this._leaves = new
|
|
13167
|
+
this._leaves = new S(), this._root = null, this._level = 0;
|
|
13168
13168
|
};
|
|
13169
13169
|
fr.prototype.buildTree = function() {
|
|
13170
13170
|
var t = this;
|
|
13171
13171
|
we.sort(this._leaves, new cr.NodeComparator());
|
|
13172
|
-
for (var e = this._leaves, r = null, i = new
|
|
13172
|
+
for (var e = this._leaves, r = null, i = new S(); ; ) {
|
|
13173
13173
|
if (t.buildLevel(e, i), i.size() === 1)
|
|
13174
13174
|
return i.get(0);
|
|
13175
13175
|
r = e, e = i, i = r;
|
|
@@ -13189,7 +13189,7 @@ fr.prototype.buildRoot = function() {
|
|
|
13189
13189
|
this._root = this.buildTree();
|
|
13190
13190
|
};
|
|
13191
13191
|
fr.prototype.printNode = function(t) {
|
|
13192
|
-
Rt.out.println(xe.toLineString(new
|
|
13192
|
+
Rt.out.println(xe.toLineString(new v(t._min, this._level), new v(t._max, this._level)));
|
|
13193
13193
|
};
|
|
13194
13194
|
fr.prototype.init = function() {
|
|
13195
13195
|
if (this._root !== null)
|
|
@@ -13215,7 +13215,7 @@ fr.prototype.getClass = function() {
|
|
|
13215
13215
|
return fr;
|
|
13216
13216
|
};
|
|
13217
13217
|
var Yn = function() {
|
|
13218
|
-
this._items = new
|
|
13218
|
+
this._items = new S();
|
|
13219
13219
|
};
|
|
13220
13220
|
Yn.prototype.visitItem = function(t) {
|
|
13221
13221
|
this._items.add(t);
|
|
@@ -13345,7 +13345,7 @@ var si = function(n) {
|
|
|
13345
13345
|
if (arguments[0] instanceof te) {
|
|
13346
13346
|
var r = arguments[0], i = r.getCoordinate();
|
|
13347
13347
|
this.insertPoint(this._argIndex, i, y.INTERIOR);
|
|
13348
|
-
} else if (arguments[0] instanceof
|
|
13348
|
+
} else if (arguments[0] instanceof v) {
|
|
13349
13349
|
var o = arguments[0];
|
|
13350
13350
|
this.insertPoint(this._argIndex, o, y.INTERIOR);
|
|
13351
13351
|
}
|
|
@@ -13477,14 +13477,14 @@ jr.prototype.getClass = function() {
|
|
|
13477
13477
|
return jr;
|
|
13478
13478
|
};
|
|
13479
13479
|
jr.map = function() {
|
|
13480
|
-
if (arguments[0] instanceof
|
|
13481
|
-
for (var t = arguments[0], e = arguments[1], r = new
|
|
13480
|
+
if (arguments[0] instanceof D && T(arguments[1], jr.MapOp)) {
|
|
13481
|
+
for (var t = arguments[0], e = arguments[1], r = new S(), i = 0; i < t.getNumGeometries(); i++) {
|
|
13482
13482
|
var o = e.map(t.getGeometryN(i));
|
|
13483
13483
|
o !== null && r.add(o);
|
|
13484
13484
|
}
|
|
13485
13485
|
return t.getFactory().buildGeometry(r);
|
|
13486
13486
|
} else if (T(arguments[0], _t) && T(arguments[1], jr.MapOp)) {
|
|
13487
|
-
for (var s = arguments[0], a = arguments[1], u = new
|
|
13487
|
+
for (var s = arguments[0], a = arguments[1], u = new S(), l = s.iterator(); l.hasNext(); ) {
|
|
13488
13488
|
var c = l.next(), f = a.map(c);
|
|
13489
13489
|
f !== null && u.add(f);
|
|
13490
13490
|
}
|
|
@@ -13496,7 +13496,7 @@ jr.MapOp = function() {
|
|
|
13496
13496
|
var B = function(n) {
|
|
13497
13497
|
function t() {
|
|
13498
13498
|
var e = arguments[0], r = arguments[1];
|
|
13499
|
-
n.call(this, e, r), this._ptLocator = new be(), this._geomFact = null, this._resultGeom = null, this._graph = null, this._edgeList = new Pe(), this._resultPolyList = new
|
|
13499
|
+
n.call(this, e, r), this._ptLocator = new be(), this._geomFact = null, this._resultGeom = null, this._graph = null, this._edgeList = new Pe(), this._resultPolyList = new S(), this._resultLineList = new S(), this._resultPointList = new S(), this._graph = new st(new ga()), this._geomFact = e.getFactory();
|
|
13500
13500
|
}
|
|
13501
13501
|
return n && (t.__proto__ = n), t.prototype = Object.create(n && n.prototype), t.prototype.constructor = t, t.prototype.insertUniqueEdge = function(r) {
|
|
13502
13502
|
var i = this._edgeList.findEqualEdge(r);
|
|
@@ -13517,7 +13517,7 @@ var B = function(n) {
|
|
|
13517
13517
|
}, t.prototype.isCoveredByLA = function(r) {
|
|
13518
13518
|
return !!(this.isCovered(r, this._resultLineList) || this.isCovered(r, this._resultPolyList));
|
|
13519
13519
|
}, t.prototype.computeGeometry = function(r, i, o, s) {
|
|
13520
|
-
var a = new
|
|
13520
|
+
var a = new S();
|
|
13521
13521
|
return a.addAll(r), a.addAll(i), a.addAll(o), a.isEmpty() ? t.createEmptyResult(s, this._arg[0].getGeometry(), this._arg[1].getGeometry(), this._geomFact) : this._geomFact.buildGeometry(a);
|
|
13522
13522
|
}, t.prototype.mergeSymLabels = function() {
|
|
13523
13523
|
for (var r = this._graph.getNodes().iterator(); r.hasNext(); ) {
|
|
@@ -13532,7 +13532,7 @@ var B = function(n) {
|
|
|
13532
13532
|
}
|
|
13533
13533
|
return !1;
|
|
13534
13534
|
}, t.prototype.replaceCollapsedEdges = function() {
|
|
13535
|
-
for (var r = new
|
|
13535
|
+
for (var r = new S(), i = this._edgeList.iterator(); i.hasNext(); ) {
|
|
13536
13536
|
var o = i.next();
|
|
13537
13537
|
o.isCollapsed() && (i.remove(), r.add(o.getCollapsedEdge()));
|
|
13538
13538
|
}
|
|
@@ -13551,7 +13551,7 @@ var B = function(n) {
|
|
|
13551
13551
|
}
|
|
13552
13552
|
}, t.prototype.computeOverlay = function(r) {
|
|
13553
13553
|
this.copyPoints(0), this.copyPoints(1), this._arg[0].computeSelfNodes(this._li, !1), this._arg[1].computeSelfNodes(this._li, !1), this._arg[0].computeEdgeIntersections(this._arg[1], this._li, !0);
|
|
13554
|
-
var i = new
|
|
13554
|
+
var i = new S();
|
|
13555
13555
|
this._arg[0].computeSplitEdges(i), this._arg[1].computeSplitEdges(i), this.insertUniqueEdges(i), this.computeLabelsFromDepths(), this.replaceCollapsedEdges(), rn.checkValid(this._edgeList.getEdges()), this._graph.addEdges(this._edgeList.getEdges()), this.computeLabelling(), this.labelIncompleteNodes(), this.findResultAreaEdges(r), this.cancelDuplicateResultEdges();
|
|
13556
13556
|
var o = new ee(this._geomFact);
|
|
13557
13557
|
o.add(this._graph), this._resultPolyList = o.getPolygons();
|
|
@@ -13724,7 +13724,7 @@ Dr.prototype.getClass = function() {
|
|
|
13724
13724
|
return Dr;
|
|
13725
13725
|
};
|
|
13726
13726
|
var Kn = function() {
|
|
13727
|
-
this._linework = null, this._linework = new
|
|
13727
|
+
this._linework = null, this._linework = new S();
|
|
13728
13728
|
};
|
|
13729
13729
|
Kn.prototype.getLinework = function() {
|
|
13730
13730
|
return this._linework;
|
|
@@ -13757,7 +13757,7 @@ on.prototype.setSidesToGenerate = function(t, e) {
|
|
|
13757
13757
|
this._doLeft = t, this._doRight = e;
|
|
13758
13758
|
};
|
|
13759
13759
|
on.prototype.getPoints = function(t) {
|
|
13760
|
-
for (var e = this, r = new
|
|
13760
|
+
for (var e = this, r = new S(), i = wt.getLines(this._g), o = i.iterator(); o.hasNext(); ) {
|
|
13761
13761
|
var s = o.next();
|
|
13762
13762
|
e.extractPoints(s, t, r);
|
|
13763
13763
|
}
|
|
@@ -13766,12 +13766,12 @@ on.prototype.getPoints = function(t) {
|
|
|
13766
13766
|
on.prototype.computeOffsetPoints = function(t, e, r, i) {
|
|
13767
13767
|
var o = e.x - t.x, s = e.y - t.y, a = Math.sqrt(o * o + s * s), u = r * o / a, l = r * s / a, c = (e.x + t.x) / 2, f = (e.y + t.y) / 2;
|
|
13768
13768
|
if (this._doLeft) {
|
|
13769
|
-
var h = new
|
|
13769
|
+
var h = new v(c - l, f + u);
|
|
13770
13770
|
i.add(h);
|
|
13771
13771
|
}
|
|
13772
13772
|
if (this._doRight) {
|
|
13773
|
-
var
|
|
13774
|
-
i.add(
|
|
13773
|
+
var p = new v(c + l, f - u);
|
|
13774
|
+
i.add(p);
|
|
13775
13775
|
}
|
|
13776
13776
|
};
|
|
13777
13777
|
on.prototype.interfaces_ = function() {
|
|
@@ -13781,7 +13781,7 @@ on.prototype.getClass = function() {
|
|
|
13781
13781
|
return on;
|
|
13782
13782
|
};
|
|
13783
13783
|
var he = function n() {
|
|
13784
|
-
this._geom = null, this._locFinder = null, this._location = new Array(3).fill(null), this._invalidLocation = null, this._boundaryDistanceTolerance = n.TOLERANCE, this._testCoords = new
|
|
13784
|
+
this._geom = null, this._locFinder = null, this._location = new Array(3).fill(null), this._invalidLocation = null, this._boundaryDistanceTolerance = n.TOLERANCE, this._testCoords = new S();
|
|
13785
13785
|
var t = arguments[0], e = arguments[1], r = arguments[2];
|
|
13786
13786
|
this._boundaryDistanceTolerance = n.computeBoundaryDistanceTolerance(t, e), this._geom = [t, e, r], this._locFinder = [new Dr(this._geom[0], this._boundaryDistanceTolerance), new Dr(this._geom[1], this._boundaryDistanceTolerance), new Dr(this._geom[2], this._boundaryDistanceTolerance)];
|
|
13787
13787
|
}, xa = { TOLERANCE: { configurable: !0 } };
|
|
@@ -13854,7 +13854,7 @@ oe.prototype.extractElements = function(t, e) {
|
|
|
13854
13854
|
}
|
|
13855
13855
|
};
|
|
13856
13856
|
oe.prototype.combine = function() {
|
|
13857
|
-
for (var t = this, e = new
|
|
13857
|
+
for (var t = this, e = new S(), r = this._inputGeoms.iterator(); r.hasNext(); ) {
|
|
13858
13858
|
var i = r.next();
|
|
13859
13859
|
t.extractElements(i, e);
|
|
13860
13860
|
}
|
|
@@ -13883,27 +13883,27 @@ oe.extractFactory = function(t) {
|
|
|
13883
13883
|
};
|
|
13884
13884
|
oe.createList = function() {
|
|
13885
13885
|
if (arguments.length === 2) {
|
|
13886
|
-
var t = arguments[0], e = arguments[1], r = new
|
|
13886
|
+
var t = arguments[0], e = arguments[1], r = new S();
|
|
13887
13887
|
return r.add(t), r.add(e), r;
|
|
13888
13888
|
} else if (arguments.length === 3) {
|
|
13889
|
-
var i = arguments[0], o = arguments[1], s = arguments[2], a = new
|
|
13889
|
+
var i = arguments[0], o = arguments[1], s = arguments[2], a = new S();
|
|
13890
13890
|
return a.add(i), a.add(o), a.add(s), a;
|
|
13891
13891
|
}
|
|
13892
13892
|
};
|
|
13893
13893
|
var yt = function() {
|
|
13894
13894
|
this._inputPolys = null, this._geomFactory = null;
|
|
13895
13895
|
var t = arguments[0];
|
|
13896
|
-
this._inputPolys = t, this._inputPolys === null && (this._inputPolys = new
|
|
13896
|
+
this._inputPolys = t, this._inputPolys === null && (this._inputPolys = new S());
|
|
13897
13897
|
}, Sa = { STRTREE_NODE_CAPACITY: { configurable: !0 } };
|
|
13898
13898
|
yt.prototype.reduceToGeometries = function(t) {
|
|
13899
|
-
for (var e = this, r = new
|
|
13899
|
+
for (var e = this, r = new S(), i = t.iterator(); i.hasNext(); ) {
|
|
13900
13900
|
var o = i.next(), s = null;
|
|
13901
|
-
T(o, Ne) ? s = e.unionTree(o) : o instanceof
|
|
13901
|
+
T(o, Ne) ? s = e.unionTree(o) : o instanceof D && (s = o), r.add(s);
|
|
13902
13902
|
}
|
|
13903
13903
|
return r;
|
|
13904
13904
|
};
|
|
13905
13905
|
yt.prototype.extractByEnvelope = function(t, e, r) {
|
|
13906
|
-
for (var i = new
|
|
13906
|
+
for (var i = new S(), o = 0; o < e.getNumGeometries(); o++) {
|
|
13907
13907
|
var s = e.getGeometryN(o);
|
|
13908
13908
|
s.getEnvelopeInternal().intersects(t) ? i.add(s) : r.add(s);
|
|
13909
13909
|
}
|
|
@@ -13969,7 +13969,7 @@ yt.prototype.unionTree = function(t) {
|
|
|
13969
13969
|
return r;
|
|
13970
13970
|
};
|
|
13971
13971
|
yt.prototype.unionUsingEnvelopeIntersection = function(t, e, r) {
|
|
13972
|
-
var i = new
|
|
13972
|
+
var i = new S(), o = this.extractByEnvelope(r, t, i), s = this.extractByEnvelope(r, e, i), a = this.unionActual(o, s);
|
|
13973
13973
|
i.add(a);
|
|
13974
13974
|
var u = oe.combine(i);
|
|
13975
13975
|
return u;
|
|
@@ -14167,17 +14167,17 @@ function bs(n) {
|
|
|
14167
14167
|
function Rs(n, t) {
|
|
14168
14168
|
var e = Et(n), r = It(n), i = Et(t), o = It(t);
|
|
14169
14169
|
function s(a, u) {
|
|
14170
|
-
var l = Et(u), c = Et(a) * l, f = It(a) * l, h = It(u),
|
|
14170
|
+
var l = Et(u), c = Et(a) * l, f = It(a) * l, h = It(u), p = h * e + c * r;
|
|
14171
14171
|
return [
|
|
14172
|
-
Qn(f * i -
|
|
14173
|
-
In(
|
|
14172
|
+
Qn(f * i - p * o, c * e - h * r),
|
|
14173
|
+
In(p * i + f * o)
|
|
14174
14174
|
];
|
|
14175
14175
|
}
|
|
14176
14176
|
return s.invert = function(a, u) {
|
|
14177
|
-
var l = Et(u), c = Et(a) * l, f = It(a) * l, h = It(u),
|
|
14177
|
+
var l = Et(u), c = Et(a) * l, f = It(a) * l, h = It(u), p = h * i - f * o;
|
|
14178
14178
|
return [
|
|
14179
|
-
Qn(f * i + h * o, c * e +
|
|
14180
|
-
In(
|
|
14179
|
+
Qn(f * i + h * o, c * e + p * r),
|
|
14180
|
+
In(p * e - c * r)
|
|
14181
14181
|
];
|
|
14182
14182
|
}, s;
|
|
14183
14183
|
}
|
|
@@ -14214,48 +14214,48 @@ function Pa() {
|
|
|
14214
14214
|
};
|
|
14215
14215
|
}
|
|
14216
14216
|
function nl(n, t, e, r, i, o) {
|
|
14217
|
-
var s = n[0], a = n[1], u = t[0], l = t[1], c = 0, f = 1, h = u - s,
|
|
14218
|
-
if (
|
|
14219
|
-
if (
|
|
14220
|
-
if (
|
|
14217
|
+
var s = n[0], a = n[1], u = t[0], l = t[1], c = 0, f = 1, h = u - s, p = l - a, g;
|
|
14218
|
+
if (g = e - s, !(!h && g > 0)) {
|
|
14219
|
+
if (g /= h, h < 0) {
|
|
14220
|
+
if (g < c)
|
|
14221
14221
|
return;
|
|
14222
|
-
|
|
14222
|
+
g < f && (f = g);
|
|
14223
14223
|
} else if (h > 0) {
|
|
14224
|
-
if (
|
|
14224
|
+
if (g > f)
|
|
14225
14225
|
return;
|
|
14226
|
-
|
|
14226
|
+
g > c && (c = g);
|
|
14227
14227
|
}
|
|
14228
|
-
if (
|
|
14229
|
-
if (
|
|
14230
|
-
if (
|
|
14228
|
+
if (g = i - s, !(!h && g < 0)) {
|
|
14229
|
+
if (g /= h, h < 0) {
|
|
14230
|
+
if (g > f)
|
|
14231
14231
|
return;
|
|
14232
|
-
|
|
14232
|
+
g > c && (c = g);
|
|
14233
14233
|
} else if (h > 0) {
|
|
14234
|
-
if (
|
|
14234
|
+
if (g < c)
|
|
14235
14235
|
return;
|
|
14236
|
-
|
|
14236
|
+
g < f && (f = g);
|
|
14237
14237
|
}
|
|
14238
|
-
if (
|
|
14239
|
-
if (
|
|
14240
|
-
if (
|
|
14238
|
+
if (g = r - a, !(!p && g > 0)) {
|
|
14239
|
+
if (g /= p, p < 0) {
|
|
14240
|
+
if (g < c)
|
|
14241
14241
|
return;
|
|
14242
|
-
|
|
14243
|
-
} else if (
|
|
14244
|
-
if (
|
|
14242
|
+
g < f && (f = g);
|
|
14243
|
+
} else if (p > 0) {
|
|
14244
|
+
if (g > f)
|
|
14245
14245
|
return;
|
|
14246
|
-
|
|
14246
|
+
g > c && (c = g);
|
|
14247
14247
|
}
|
|
14248
|
-
if (
|
|
14249
|
-
if (
|
|
14250
|
-
if (
|
|
14248
|
+
if (g = o - a, !(!p && g < 0)) {
|
|
14249
|
+
if (g /= p, p < 0) {
|
|
14250
|
+
if (g > f)
|
|
14251
14251
|
return;
|
|
14252
|
-
|
|
14253
|
-
} else if (
|
|
14254
|
-
if (
|
|
14252
|
+
g > c && (c = g);
|
|
14253
|
+
} else if (p > 0) {
|
|
14254
|
+
if (g < c)
|
|
14255
14255
|
return;
|
|
14256
|
-
|
|
14256
|
+
g < f && (f = g);
|
|
14257
14257
|
}
|
|
14258
|
-
return c > 0 && (n[0] = s + c * h, n[1] = a + c *
|
|
14258
|
+
return c > 0 && (n[0] = s + c * h, n[1] = a + c * p), f < 1 && (t[0] = s + f * h, t[1] = a + f * p), !0;
|
|
14259
14259
|
}
|
|
14260
14260
|
}
|
|
14261
14261
|
}
|
|
@@ -14269,42 +14269,42 @@ function Vi(n, t, e, r) {
|
|
|
14269
14269
|
}
|
|
14270
14270
|
function ba(n, t, e, r, i) {
|
|
14271
14271
|
var o = [], s = [], a, u;
|
|
14272
|
-
if (n.forEach(function(
|
|
14273
|
-
if (!((
|
|
14274
|
-
var
|
|
14275
|
-
if (zi(
|
|
14276
|
-
for (i.lineStart(), a = 0; a <
|
|
14277
|
-
i.point((
|
|
14272
|
+
if (n.forEach(function(g) {
|
|
14273
|
+
if (!((m = g.length - 1) <= 0)) {
|
|
14274
|
+
var m, d = g[0], E = g[m], I;
|
|
14275
|
+
if (zi(d, E)) {
|
|
14276
|
+
for (i.lineStart(), a = 0; a < m; ++a)
|
|
14277
|
+
i.point((d = g[a])[0], d[1]);
|
|
14278
14278
|
i.lineEnd();
|
|
14279
14279
|
return;
|
|
14280
14280
|
}
|
|
14281
|
-
o.push(I = new Vi(
|
|
14281
|
+
o.push(I = new Vi(d, g, null, !0)), s.push(I.o = new Vi(d, null, I, !1)), o.push(I = new Vi(E, g, null, !1)), s.push(I.o = new Vi(E, null, I, !0));
|
|
14282
14282
|
}
|
|
14283
14283
|
}), !!o.length) {
|
|
14284
14284
|
for (s.sort(t), Ds(o), Ds(s), a = 0, u = s.length; a < u; ++a)
|
|
14285
14285
|
s[a].e = e = !e;
|
|
14286
14286
|
for (var l = o[0], c, f; ; ) {
|
|
14287
|
-
for (var h = l,
|
|
14287
|
+
for (var h = l, p = !0; h.v; )
|
|
14288
14288
|
if ((h = h.n) === l)
|
|
14289
14289
|
return;
|
|
14290
14290
|
c = h.z, i.lineStart();
|
|
14291
14291
|
do {
|
|
14292
14292
|
if (h.v = h.o.v = !0, h.e) {
|
|
14293
|
-
if (
|
|
14293
|
+
if (p)
|
|
14294
14294
|
for (a = 0, u = c.length; a < u; ++a)
|
|
14295
14295
|
i.point((f = c[a])[0], f[1]);
|
|
14296
14296
|
else
|
|
14297
14297
|
r(h.x, h.n.x, 1, i);
|
|
14298
14298
|
h = h.n;
|
|
14299
14299
|
} else {
|
|
14300
|
-
if (
|
|
14300
|
+
if (p)
|
|
14301
14301
|
for (c = h.p.z, a = c.length - 1; a >= 0; --a)
|
|
14302
14302
|
i.point((f = c[a])[0], f[1]);
|
|
14303
14303
|
else
|
|
14304
14304
|
r(h.x, h.p.x, -1, i);
|
|
14305
14305
|
h = h.p;
|
|
14306
14306
|
}
|
|
14307
|
-
h = h.o, c = h.z,
|
|
14307
|
+
h = h.o, c = h.z, p = !p;
|
|
14308
14308
|
} while (!h.v);
|
|
14309
14309
|
i.lineEnd();
|
|
14310
14310
|
}
|
|
@@ -14358,11 +14358,11 @@ function sl(n, t, e, r) {
|
|
|
14358
14358
|
return n <= l && l <= e && t <= c && c <= r;
|
|
14359
14359
|
}
|
|
14360
14360
|
function o(l, c, f, h) {
|
|
14361
|
-
var
|
|
14362
|
-
if (l == null || (
|
|
14361
|
+
var p = 0, g = 0;
|
|
14362
|
+
if (l == null || (p = s(l, f)) !== (g = s(c, f)) || u(l, c) < 0 ^ f > 0)
|
|
14363
14363
|
do
|
|
14364
|
-
h.point(
|
|
14365
|
-
while ((
|
|
14364
|
+
h.point(p === 0 || p === 3 ? n : e, p > 1 ? r : t);
|
|
14365
|
+
while ((p = (p + f + 4) % 4) !== g);
|
|
14366
14366
|
else
|
|
14367
14367
|
h.point(c[0], c[1]);
|
|
14368
14368
|
}
|
|
@@ -14377,7 +14377,7 @@ function sl(n, t, e, r) {
|
|
|
14377
14377
|
return f !== h ? f - h : f === 0 ? c[1] - l[1] : f === 1 ? l[0] - c[0] : f === 2 ? l[1] - c[1] : c[0] - l[0];
|
|
14378
14378
|
}
|
|
14379
14379
|
return function(l) {
|
|
14380
|
-
var c = l, f = Pa(), h,
|
|
14380
|
+
var c = l, f = Pa(), h, p, g, m, d, E, I, C, x, R, O, F = {
|
|
14381
14381
|
point: G,
|
|
14382
14382
|
lineStart: nt,
|
|
14383
14383
|
lineEnd: ct,
|
|
@@ -14388,35 +14388,35 @@ function sl(n, t, e, r) {
|
|
|
14388
14388
|
i(X, ft) && c.point(X, ft);
|
|
14389
14389
|
}
|
|
14390
14390
|
function M() {
|
|
14391
|
-
for (var X = 0, ft = 0, Gt =
|
|
14392
|
-
for (var pe =
|
|
14391
|
+
for (var X = 0, ft = 0, Gt = p.length; ft < Gt; ++ft)
|
|
14392
|
+
for (var pe = p[ft], Te = 1, ii = pe.length, Pr = pe[0], un, br, Mi = Pr[0], wn = Pr[1]; Te < ii; ++Te)
|
|
14393
14393
|
un = Mi, br = wn, Pr = pe[Te], Mi = Pr[0], wn = Pr[1], br <= r ? wn > r && (Mi - un) * (r - br) > (wn - br) * (n - un) && ++X : wn <= r && (Mi - un) * (r - br) < (wn - br) * (n - un) && --X;
|
|
14394
14394
|
return X;
|
|
14395
14395
|
}
|
|
14396
14396
|
function et() {
|
|
14397
|
-
c = f, h = [],
|
|
14397
|
+
c = f, h = [], p = [], O = !0;
|
|
14398
14398
|
}
|
|
14399
14399
|
function K() {
|
|
14400
|
-
var X = M(), ft =
|
|
14401
|
-
(ft || Gt) && (l.polygonStart(), ft && (l.lineStart(), o(null, null, 1, l), l.lineEnd()), Gt && ba(h, a, X, o, l), l.polygonEnd()), c = l, h =
|
|
14400
|
+
var X = M(), ft = O && X, Gt = (h = Oa(h)).length;
|
|
14401
|
+
(ft || Gt) && (l.polygonStart(), ft && (l.lineStart(), o(null, null, 1, l), l.lineEnd()), Gt && ba(h, a, X, o, l), l.polygonEnd()), c = l, h = p = g = null;
|
|
14402
14402
|
}
|
|
14403
14403
|
function nt() {
|
|
14404
|
-
F.point = w,
|
|
14404
|
+
F.point = w, p && p.push(g = []), R = !0, x = !1, I = C = NaN;
|
|
14405
14405
|
}
|
|
14406
14406
|
function ct() {
|
|
14407
|
-
h && (w(
|
|
14407
|
+
h && (w(m, d), E && x && f.rejoin(), h.push(f.result())), F.point = G, x && c.lineEnd();
|
|
14408
14408
|
}
|
|
14409
14409
|
function w(X, ft) {
|
|
14410
14410
|
var Gt = i(X, ft);
|
|
14411
|
-
if (
|
|
14412
|
-
|
|
14413
|
-
else if (Gt &&
|
|
14411
|
+
if (p && g.push([X, ft]), R)
|
|
14412
|
+
m = X, d = ft, E = Gt, R = !1, Gt && (c.lineStart(), c.point(X, ft));
|
|
14413
|
+
else if (Gt && x)
|
|
14414
14414
|
c.point(X, ft);
|
|
14415
14415
|
else {
|
|
14416
14416
|
var pe = [I = Math.max(ki, Math.min(ui, I)), C = Math.max(ki, Math.min(ui, C))], Te = [X = Math.max(ki, Math.min(ui, X)), ft = Math.max(ki, Math.min(ui, ft))];
|
|
14417
|
-
nl(pe, Te, n, t, e, r) ? (
|
|
14417
|
+
nl(pe, Te, n, t, e, r) ? (x || (c.lineStart(), c.point(pe[0], pe[1])), c.point(Te[0], Te[1]), Gt || c.lineEnd(), O = !1) : Gt && (c.lineStart(), c.point(X, ft), O = !1);
|
|
14418
14418
|
}
|
|
14419
|
-
I = X, C = ft,
|
|
14419
|
+
I = X, C = ft, x = Gt;
|
|
14420
14420
|
}
|
|
14421
14421
|
return F;
|
|
14422
14422
|
};
|
|
@@ -14427,15 +14427,15 @@ function al(n, t) {
|
|
|
14427
14427
|
Co.reset();
|
|
14428
14428
|
for (var a = 0, u = n.length; a < u; ++a)
|
|
14429
14429
|
if (c = (l = n[a]).length)
|
|
14430
|
-
for (var l, c, f = l[c - 1], h = f[0],
|
|
14431
|
-
var E = l[
|
|
14432
|
-
if (Co.add(Qn(et * F * It(G),
|
|
14430
|
+
for (var l, c, f = l[c - 1], h = f[0], p = f[1] / 2 + xs, g = It(p), m = Et(p), d = 0; d < c; ++d, h = I, g = x, m = R, f = E) {
|
|
14431
|
+
var E = l[d], I = E[0], C = E[1] / 2 + xs, x = It(C), R = Et(C), O = I - h, F = O >= 0 ? 1 : -1, G = F * O, M = G > Z, et = g * x;
|
|
14432
|
+
if (Co.add(Qn(et * F * It(G), m * R + et * Et(G))), o += M ? O + F * Sr : O, M ^ h >= e ^ I >= e) {
|
|
14433
14433
|
var K = $i(Jn(f), Jn(E));
|
|
14434
14434
|
Fo(K);
|
|
14435
14435
|
var nt = $i(i, K);
|
|
14436
14436
|
Fo(nt);
|
|
14437
|
-
var ct = (M ^
|
|
14438
|
-
(r > ct || r === ct && (K[0] || K[1])) && (s += M ^
|
|
14437
|
+
var ct = (M ^ O >= 0 ? -1 : 1) * In(nt[2]);
|
|
14438
|
+
(r > ct || r === ct && (K[0] || K[1])) && (s += M ^ O >= 0 ? 1 : -1);
|
|
14439
14439
|
}
|
|
14440
14440
|
}
|
|
14441
14441
|
return (o < -at || o < at && Co < -at) ^ s & 1;
|
|
@@ -14463,49 +14463,49 @@ function ul(n, t) {
|
|
|
14463
14463
|
an();
|
|
14464
14464
|
function Da(n, t, e, r) {
|
|
14465
14465
|
return function(i, o) {
|
|
14466
|
-
var s = t(o), a = i.invert(r[0], r[1]), u = Pa(), l = t(u), c = !1, f, h,
|
|
14467
|
-
point:
|
|
14466
|
+
var s = t(o), a = i.invert(r[0], r[1]), u = Pa(), l = t(u), c = !1, f, h, p, g = {
|
|
14467
|
+
point: m,
|
|
14468
14468
|
lineStart: E,
|
|
14469
14469
|
lineEnd: I,
|
|
14470
14470
|
polygonStart: function() {
|
|
14471
|
-
|
|
14471
|
+
g.point = C, g.lineStart = x, g.lineEnd = R, h = [], f = [];
|
|
14472
14472
|
},
|
|
14473
14473
|
polygonEnd: function() {
|
|
14474
|
-
|
|
14475
|
-
var
|
|
14476
|
-
h.length ? (c || (o.polygonStart(), c = !0), ba(h, cl,
|
|
14474
|
+
g.point = m, g.lineStart = E, g.lineEnd = I, h = Oa(h);
|
|
14475
|
+
var O = al(f, a);
|
|
14476
|
+
h.length ? (c || (o.polygonStart(), c = !0), ba(h, cl, O, e, o)) : O && (c || (o.polygonStart(), c = !0), o.lineStart(), e(null, null, 1, o), o.lineEnd()), c && (o.polygonEnd(), c = !1), h = f = null;
|
|
14477
14477
|
},
|
|
14478
14478
|
sphere: function() {
|
|
14479
14479
|
o.polygonStart(), o.lineStart(), e(null, null, 1, o), o.lineEnd(), o.polygonEnd();
|
|
14480
14480
|
}
|
|
14481
14481
|
};
|
|
14482
|
-
function
|
|
14483
|
-
var G = i(
|
|
14484
|
-
n(
|
|
14482
|
+
function m(O, F) {
|
|
14483
|
+
var G = i(O, F);
|
|
14484
|
+
n(O = G[0], F = G[1]) && o.point(O, F);
|
|
14485
14485
|
}
|
|
14486
|
-
function
|
|
14487
|
-
var G = i(
|
|
14486
|
+
function d(O, F) {
|
|
14487
|
+
var G = i(O, F);
|
|
14488
14488
|
s.point(G[0], G[1]);
|
|
14489
14489
|
}
|
|
14490
14490
|
function E() {
|
|
14491
|
-
|
|
14491
|
+
g.point = d, s.lineStart();
|
|
14492
14492
|
}
|
|
14493
14493
|
function I() {
|
|
14494
|
-
|
|
14494
|
+
g.point = m, s.lineEnd();
|
|
14495
14495
|
}
|
|
14496
|
-
function C(
|
|
14497
|
-
|
|
14498
|
-
var G = i(
|
|
14496
|
+
function C(O, F) {
|
|
14497
|
+
p.push([O, F]);
|
|
14498
|
+
var G = i(O, F);
|
|
14499
14499
|
l.point(G[0], G[1]);
|
|
14500
14500
|
}
|
|
14501
|
-
function
|
|
14502
|
-
l.lineStart(),
|
|
14501
|
+
function x() {
|
|
14502
|
+
l.lineStart(), p = [];
|
|
14503
14503
|
}
|
|
14504
|
-
function
|
|
14505
|
-
C(
|
|
14506
|
-
var
|
|
14507
|
-
if (
|
|
14508
|
-
if (
|
|
14504
|
+
function R() {
|
|
14505
|
+
C(p[0][0], p[0][1]), l.lineEnd();
|
|
14506
|
+
var O = l.clean(), F = u.result(), G, M = F.length, et, K, nt;
|
|
14507
|
+
if (p.pop(), f.push(p), p = null, !!M) {
|
|
14508
|
+
if (O & 1) {
|
|
14509
14509
|
if (K = F[0], (et = K.length - 1) > 0) {
|
|
14510
14510
|
for (c || (o.polygonStart(), c = !0), o.lineStart(), G = 0; G < et; ++G)
|
|
14511
14511
|
o.point((nt = K[G])[0], nt[1]);
|
|
@@ -14513,10 +14513,10 @@ function Da(n, t, e, r) {
|
|
|
14513
14513
|
}
|
|
14514
14514
|
return;
|
|
14515
14515
|
}
|
|
14516
|
-
M > 1 &&
|
|
14516
|
+
M > 1 && O & 2 && F.push(F.pop().concat(F.shift())), h.push(F.filter(ll));
|
|
14517
14517
|
}
|
|
14518
14518
|
}
|
|
14519
|
-
return
|
|
14519
|
+
return g;
|
|
14520
14520
|
};
|
|
14521
14521
|
}
|
|
14522
14522
|
function ll(n) {
|
|
@@ -14567,45 +14567,45 @@ function pl(n, t, e, r) {
|
|
|
14567
14567
|
}
|
|
14568
14568
|
function gl(n, t) {
|
|
14569
14569
|
var e = Et(n), r = e > 0, i = Ut(e) > at;
|
|
14570
|
-
function o(c, f, h,
|
|
14571
|
-
rl(
|
|
14570
|
+
function o(c, f, h, p) {
|
|
14571
|
+
rl(p, n, t, h, c, f);
|
|
14572
14572
|
}
|
|
14573
14573
|
function s(c, f) {
|
|
14574
14574
|
return Et(c) * Et(f) > e;
|
|
14575
14575
|
}
|
|
14576
14576
|
function a(c) {
|
|
14577
|
-
var f, h,
|
|
14577
|
+
var f, h, p, g, m;
|
|
14578
14578
|
return {
|
|
14579
14579
|
lineStart: function() {
|
|
14580
|
-
|
|
14580
|
+
g = p = !1, m = 1;
|
|
14581
14581
|
},
|
|
14582
|
-
point: function(
|
|
14583
|
-
var I = [
|
|
14584
|
-
if (!f && (
|
|
14585
|
-
|
|
14586
|
-
else if (i && f && r ^
|
|
14587
|
-
var
|
|
14588
|
-
!(
|
|
14582
|
+
point: function(d, E) {
|
|
14583
|
+
var I = [d, E], C, x = s(d, E), R = r ? x ? 0 : l(d, E) : x ? l(d + (d < 0 ? Z : -Z), E) : 0;
|
|
14584
|
+
if (!f && (g = p = x) && c.lineStart(), x !== p && (C = u(f, I), (!C || zi(f, C) || zi(I, C)) && (I[0] += at, I[1] += at, x = s(I[0], I[1]))), x !== p)
|
|
14585
|
+
m = 0, x ? (c.lineStart(), C = u(I, f), c.point(C[0], C[1])) : (C = u(f, I), c.point(C[0], C[1]), c.lineEnd()), f = C;
|
|
14586
|
+
else if (i && f && r ^ x) {
|
|
14587
|
+
var O;
|
|
14588
|
+
!(R & h) && (O = u(I, f, !0)) && (m = 0, r ? (c.lineStart(), c.point(O[0][0], O[0][1]), c.point(O[1][0], O[1][1]), c.lineEnd()) : (c.point(O[1][0], O[1][1]), c.lineEnd(), c.lineStart(), c.point(O[0][0], O[0][1])));
|
|
14589
14589
|
}
|
|
14590
|
-
|
|
14590
|
+
x && (!f || !zi(f, I)) && c.point(I[0], I[1]), f = I, p = x, h = R;
|
|
14591
14591
|
},
|
|
14592
14592
|
lineEnd: function() {
|
|
14593
|
-
|
|
14593
|
+
p && c.lineEnd(), f = null;
|
|
14594
14594
|
},
|
|
14595
14595
|
// Rejoin first and last segments if there were intersections and the first
|
|
14596
14596
|
// and last points were visible.
|
|
14597
14597
|
clean: function() {
|
|
14598
|
-
return
|
|
14598
|
+
return m | (g && p) << 1;
|
|
14599
14599
|
}
|
|
14600
14600
|
};
|
|
14601
14601
|
}
|
|
14602
14602
|
function u(c, f, h) {
|
|
14603
|
-
var
|
|
14603
|
+
var p = Jn(c), g = Jn(f), m = [1, 0, 0], d = $i(p, g), E = Bi(d, d), I = d[0], C = E - I * I;
|
|
14604
14604
|
if (!C)
|
|
14605
14605
|
return !h && c;
|
|
14606
|
-
var
|
|
14606
|
+
var x = e * E / C, R = -e * I / C, O = $i(m, d), F = Gi(m, x), G = Gi(d, R);
|
|
14607
14607
|
Io(F, G);
|
|
14608
|
-
var M =
|
|
14608
|
+
var M = O, et = Bi(F, M), K = Bi(M, M), nt = et * et - K * (Bi(F, F) - 1);
|
|
14609
14609
|
if (!(nt < 0)) {
|
|
14610
14610
|
var ct = ni(nt), w = Gi(M, (-et - ct) / K);
|
|
14611
14611
|
if (Io(w, F), w = Ao(w), !h)
|
|
@@ -14620,8 +14620,8 @@ function gl(n, t) {
|
|
|
14620
14620
|
}
|
|
14621
14621
|
}
|
|
14622
14622
|
function l(c, f) {
|
|
14623
|
-
var h = r ? n : Z - n,
|
|
14624
|
-
return c < -h ?
|
|
14623
|
+
var h = r ? n : Z - n, p = 0;
|
|
14624
|
+
return c < -h ? p |= 1 : c > h && (p |= 2), f < -h ? p |= 4 : f > h && (p |= 8), p;
|
|
14625
14625
|
}
|
|
14626
14626
|
return Da(s, a, o, r ? [0, -n] : [-Z, n - Z]);
|
|
14627
14627
|
}
|
|
@@ -14677,48 +14677,48 @@ function yl(n) {
|
|
|
14677
14677
|
});
|
|
14678
14678
|
}
|
|
14679
14679
|
function ml(n, t) {
|
|
14680
|
-
function e(r, i, o, s, a, u, l, c, f, h,
|
|
14680
|
+
function e(r, i, o, s, a, u, l, c, f, h, p, g, m, d) {
|
|
14681
14681
|
var E = l - r, I = c - i, C = E * E + I * I;
|
|
14682
|
-
if (C > 4 * t &&
|
|
14683
|
-
var
|
|
14684
|
-
(X * X / C > t || Ut((E * ct + I * w) / C - 0.5) > 0.3 || s * h + a *
|
|
14682
|
+
if (C > 4 * t && m--) {
|
|
14683
|
+
var x = s + h, R = a + p, O = u + g, F = ni(x * x + R * R + O * O), G = In(O /= F), M = Ut(Ut(O) - 1) < at || Ut(o - f) < at ? (o + f) / 2 : Qn(R, x), et = n(M, G), K = et[0], nt = et[1], ct = K - r, w = nt - i, X = I * ct - E * w;
|
|
14684
|
+
(X * X / C > t || Ut((E * ct + I * w) / C - 0.5) > 0.3 || s * h + a * p + u * g < vl) && (e(r, i, o, s, a, u, K, nt, M, x /= F, R /= F, O, m, d), d.point(K, nt), e(K, nt, M, x, R, O, l, c, f, h, p, g, m, d));
|
|
14685
14685
|
}
|
|
14686
14686
|
}
|
|
14687
14687
|
return function(r) {
|
|
14688
|
-
var i, o, s, a, u, l, c, f, h,
|
|
14688
|
+
var i, o, s, a, u, l, c, f, h, p, g, m, d = {
|
|
14689
14689
|
point: E,
|
|
14690
14690
|
lineStart: I,
|
|
14691
|
-
lineEnd:
|
|
14691
|
+
lineEnd: x,
|
|
14692
14692
|
polygonStart: function() {
|
|
14693
|
-
r.polygonStart(),
|
|
14693
|
+
r.polygonStart(), d.lineStart = R;
|
|
14694
14694
|
},
|
|
14695
14695
|
polygonEnd: function() {
|
|
14696
|
-
r.polygonEnd(),
|
|
14696
|
+
r.polygonEnd(), d.lineStart = I;
|
|
14697
14697
|
}
|
|
14698
14698
|
};
|
|
14699
14699
|
function E(G, M) {
|
|
14700
14700
|
G = n(G, M), r.point(G[0], G[1]);
|
|
14701
14701
|
}
|
|
14702
14702
|
function I() {
|
|
14703
|
-
f = NaN,
|
|
14703
|
+
f = NaN, d.point = C, r.lineStart();
|
|
14704
14704
|
}
|
|
14705
14705
|
function C(G, M) {
|
|
14706
14706
|
var et = Jn([G, M]), K = n(G, M);
|
|
14707
|
-
e(f, h, c,
|
|
14707
|
+
e(f, h, c, p, g, m, f = K[0], h = K[1], c = G, p = et[0], g = et[1], m = et[2], Fs, r), r.point(f, h);
|
|
14708
14708
|
}
|
|
14709
|
-
function
|
|
14710
|
-
|
|
14709
|
+
function x() {
|
|
14710
|
+
d.point = E, r.lineEnd();
|
|
14711
14711
|
}
|
|
14712
|
-
function
|
|
14713
|
-
I(),
|
|
14712
|
+
function R() {
|
|
14713
|
+
I(), d.point = O, d.lineEnd = F;
|
|
14714
14714
|
}
|
|
14715
|
-
function
|
|
14716
|
-
C(i = G, M), o = f, s = h, a =
|
|
14715
|
+
function O(G, M) {
|
|
14716
|
+
C(i = G, M), o = f, s = h, a = p, u = g, l = m, d.point = C;
|
|
14717
14717
|
}
|
|
14718
14718
|
function F() {
|
|
14719
|
-
e(f, h, c,
|
|
14719
|
+
e(f, h, c, p, g, m, o, s, i, a, u, l, Fs, r), d.lineEnd = x, x();
|
|
14720
14720
|
}
|
|
14721
|
-
return
|
|
14721
|
+
return d;
|
|
14722
14722
|
};
|
|
14723
14723
|
}
|
|
14724
14724
|
var _l = Ta({
|
|
@@ -14732,22 +14732,22 @@ function El(n) {
|
|
|
14732
14732
|
})();
|
|
14733
14733
|
}
|
|
14734
14734
|
function Il(n) {
|
|
14735
|
-
var t, e = 150, r = 480, i = 250, o, s, a = 0, u = 0, l = 0, c = 0, f = 0, h,
|
|
14735
|
+
var t, e = 150, r = 480, i = 250, o, s, a = 0, u = 0, l = 0, c = 0, f = 0, h, p, g = null, m = As, d = null, E, I, C, x = Ts, R = 0.5, O = Bs(K, R), F, G;
|
|
14736
14736
|
function M(w) {
|
|
14737
|
-
return w =
|
|
14737
|
+
return w = p(w[0] * Ae, w[1] * Ae), [w[0] * e + o, s - w[1] * e];
|
|
14738
14738
|
}
|
|
14739
14739
|
function et(w) {
|
|
14740
|
-
return w =
|
|
14740
|
+
return w = p.invert((w[0] - o) / e, (s - w[1]) / e), w && [w[0] * Xr, w[1] * Xr];
|
|
14741
14741
|
}
|
|
14742
14742
|
function K(w, X) {
|
|
14743
14743
|
return w = t(w, X), [w[0] * e + o, s - w[1] * e];
|
|
14744
14744
|
}
|
|
14745
14745
|
M.stream = function(w) {
|
|
14746
|
-
return F && G === w ? F : F = _l(
|
|
14746
|
+
return F && G === w ? F : F = _l(m(h, O(x(G = w))));
|
|
14747
14747
|
}, M.clipAngle = function(w) {
|
|
14748
|
-
return arguments.length ? (
|
|
14748
|
+
return arguments.length ? (m = +w ? gl(g = w * Ae, 6 * Ae) : (g = null, As), ct()) : g * Xr;
|
|
14749
14749
|
}, M.clipExtent = function(w) {
|
|
14750
|
-
return arguments.length ? (
|
|
14750
|
+
return arguments.length ? (x = w == null ? (d = E = I = C = null, Ts) : sl(d = +w[0][0], E = +w[0][1], I = +w[1][0], C = +w[1][1]), ct()) : d == null ? null : [[d, E], [I, C]];
|
|
14751
14751
|
}, M.scale = function(w) {
|
|
14752
14752
|
return arguments.length ? (e = +w, nt()) : e;
|
|
14753
14753
|
}, M.translate = function(w) {
|
|
@@ -14757,14 +14757,14 @@ function Il(n) {
|
|
|
14757
14757
|
}, M.rotate = function(w) {
|
|
14758
14758
|
return arguments.length ? (l = w[0] % 360 * Ae, c = w[1] % 360 * Ae, f = w.length > 2 ? w[2] % 360 * Ae : 0, nt()) : [l * Xr, c * Xr, f * Xr];
|
|
14759
14759
|
}, M.precision = function(w) {
|
|
14760
|
-
return arguments.length ? (
|
|
14760
|
+
return arguments.length ? (O = Bs(K, R = w * w), ct()) : ni(R);
|
|
14761
14761
|
}, M.fitExtent = function(w, X) {
|
|
14762
14762
|
return Ma(M, w, X);
|
|
14763
14763
|
}, M.fitSize = function(w, X) {
|
|
14764
14764
|
return dl(M, w, X);
|
|
14765
14765
|
};
|
|
14766
14766
|
function nt() {
|
|
14767
|
-
|
|
14767
|
+
p = wa(h = el(l, c, f), t);
|
|
14768
14768
|
var w = t(a, u);
|
|
14769
14769
|
return o = r - w[0] * e, s = i + w[1] * e, ct();
|
|
14770
14770
|
}
|
|
@@ -14844,21 +14844,21 @@ function Ui(n, t, e, r) {
|
|
|
14844
14844
|
var i = n.properties || {}, o = n.type === "Feature" ? n.geometry : n;
|
|
14845
14845
|
if (o.type === "GeometryCollection") {
|
|
14846
14846
|
var s = [];
|
|
14847
|
-
return Zs(n, function(
|
|
14848
|
-
var
|
|
14849
|
-
|
|
14847
|
+
return Zs(n, function(m) {
|
|
14848
|
+
var d = Ui(m, t, e, r);
|
|
14849
|
+
d && s.push(d);
|
|
14850
14850
|
}), bo(s);
|
|
14851
14851
|
}
|
|
14852
14852
|
var a = Sl(o), u = {
|
|
14853
14853
|
type: o.type,
|
|
14854
14854
|
coordinates: Va(o.coordinates, a)
|
|
14855
|
-
}, l = new jo(), c = l.read(u), f = hu(pu(t, e), "meters"), h = Pt.bufferOp(c, f, r),
|
|
14856
|
-
if (h =
|
|
14857
|
-
var
|
|
14855
|
+
}, l = new jo(), c = l.read(u), f = hu(pu(t, e), "meters"), h = Pt.bufferOp(c, f, r), p = new ua();
|
|
14856
|
+
if (h = p.write(h), !Ga(h.coordinates)) {
|
|
14857
|
+
var g = {
|
|
14858
14858
|
type: h.type,
|
|
14859
14859
|
coordinates: ka(h.coordinates, a)
|
|
14860
14860
|
};
|
|
14861
|
-
return ro(
|
|
14861
|
+
return ro(g, i);
|
|
14862
14862
|
}
|
|
14863
14863
|
}
|
|
14864
14864
|
function Ga(n) {
|
|
@@ -14946,136 +14946,138 @@ function Pl(n, t, e = !0, r = !0, i = {}, o = {}, s = {
|
|
|
14946
14946
|
filter: ["!", ["has", "isMask"]]
|
|
14947
14947
|
}
|
|
14948
14948
|
}) {
|
|
14949
|
-
let a, u = [], l, c;
|
|
14950
|
-
function
|
|
14951
|
-
(s != null && s.fill || s != null && s.line) && n.addSource("full-geom", {
|
|
14949
|
+
let a, u = [], l, c, f;
|
|
14950
|
+
function h() {
|
|
14951
|
+
!n.getSource("full-geom") && (s != null && s.fill || s != null && s.line) && n.addSource("full-geom", {
|
|
14952
14952
|
type: "geojson",
|
|
14953
14953
|
data: zs
|
|
14954
|
-
}), s != null && s.fill && n.addLayer({
|
|
14954
|
+
}), !n.getLayer("full-geom-fill") && (s != null && s.fill) && n.addLayer({
|
|
14955
14955
|
...s == null ? void 0 : s.fill,
|
|
14956
14956
|
id: "full-geom-fill",
|
|
14957
14957
|
type: "fill",
|
|
14958
14958
|
source: "full-geom"
|
|
14959
|
-
}), s != null && s.line && n.addLayer({
|
|
14959
|
+
}), !n.getLayer("full-geom-line") && (s != null && s.line) && n.addLayer({
|
|
14960
14960
|
...s == null ? void 0 : s.line,
|
|
14961
14961
|
id: "full-geom-line",
|
|
14962
14962
|
type: "line",
|
|
14963
14963
|
source: "full-geom"
|
|
14964
|
-
});
|
|
14964
|
+
}), f && m(f);
|
|
14965
14965
|
}
|
|
14966
|
-
n.loaded() ?
|
|
14967
|
-
|
|
14966
|
+
n.loaded() ? h() : n.once("load", () => {
|
|
14967
|
+
h();
|
|
14968
|
+
}), n.on("styledata", () => {
|
|
14969
|
+
h();
|
|
14968
14970
|
});
|
|
14969
|
-
const
|
|
14971
|
+
const p = (d) => {
|
|
14970
14972
|
a == null || a({
|
|
14971
14973
|
type: "mapClick",
|
|
14972
|
-
coordinates: [
|
|
14974
|
+
coordinates: [d.lngLat.lng, d.lngLat.lat]
|
|
14973
14975
|
});
|
|
14974
14976
|
};
|
|
14975
|
-
function g(
|
|
14977
|
+
function g(d = !1) {
|
|
14976
14978
|
if (!t)
|
|
14977
14979
|
throw new Error();
|
|
14978
|
-
const
|
|
14979
|
-
return
|
|
14980
|
+
const E = document.createElement("div");
|
|
14981
|
+
return d && E.classList.add("marker-interactive"), new Mu({
|
|
14980
14982
|
props: { displayIn: "maplibre" },
|
|
14981
|
-
target:
|
|
14982
|
-
}), new t.Marker({ element:
|
|
14983
|
+
target: E
|
|
14984
|
+
}), new t.Marker({ element: E, offset: [1, -13] });
|
|
14985
|
+
}
|
|
14986
|
+
function m(d) {
|
|
14987
|
+
var E;
|
|
14988
|
+
f = d, (E = n.getSource("full-geom")) == null || E.setData(d);
|
|
14983
14989
|
}
|
|
14984
14990
|
return {
|
|
14985
|
-
setEventHandler(
|
|
14986
|
-
|
|
14991
|
+
setEventHandler(d) {
|
|
14992
|
+
d ? (a = d, n.on("click", p)) : (a = void 0, n.off("click", p));
|
|
14987
14993
|
},
|
|
14988
|
-
flyTo(
|
|
14989
|
-
n.flyTo({ center:
|
|
14994
|
+
flyTo(d, E) {
|
|
14995
|
+
n.flyTo({ center: d, zoom: E, ...i });
|
|
14990
14996
|
},
|
|
14991
|
-
fitBounds(
|
|
14997
|
+
fitBounds(d, E, I) {
|
|
14992
14998
|
n.fitBounds(
|
|
14993
14999
|
[
|
|
14994
|
-
[
|
|
14995
|
-
[
|
|
15000
|
+
[d[0], d[1]],
|
|
15001
|
+
[d[2], d[3]]
|
|
14996
15002
|
],
|
|
14997
|
-
{ padding:
|
|
15003
|
+
{ padding: E, maxZoom: I, ...o }
|
|
14998
15004
|
);
|
|
14999
15005
|
},
|
|
15000
|
-
indicateReverse(
|
|
15001
|
-
n.getCanvasContainer().style.cursor =
|
|
15006
|
+
indicateReverse(d) {
|
|
15007
|
+
n.getCanvasContainer().style.cursor = d ? "crosshair" : "";
|
|
15002
15008
|
},
|
|
15003
|
-
setReverseMarker(
|
|
15004
|
-
!t || !e || (c ?
|
|
15009
|
+
setReverseMarker(d) {
|
|
15010
|
+
!t || !e || (c ? d ? c.setLngLat(d) : (c.remove(), c = void 0) : d && (c = (typeof e == "object" ? new t.Marker(e) : g()).setLngLat(d).addTo(n), c.getElement().classList.add("marker-reverse")));
|
|
15005
15011
|
},
|
|
15006
|
-
setMarkers(
|
|
15007
|
-
if (
|
|
15008
|
-
|
|
15009
|
-
|
|
15010
|
-
|
|
15011
|
-
|
|
15012
|
-
|
|
15013
|
-
|
|
15014
|
-
|
|
15015
|
-
|
|
15016
|
-
if (v) {
|
|
15017
|
-
let E = !1;
|
|
15018
|
-
if (v.geometry.type === "GeometryCollection") {
|
|
15019
|
-
const I = v.geometry.geometries.filter(
|
|
15020
|
-
(C) => C.type === "Polygon" || C.type === "MultiPolygon"
|
|
15021
|
-
);
|
|
15022
|
-
if (I.length > 0) {
|
|
15023
|
-
let C = I.pop();
|
|
15024
|
-
for (const S of I)
|
|
15025
|
-
C = gu(C, S);
|
|
15026
|
-
ks({ ...v, geometry: C }, m), E = !0;
|
|
15027
|
-
} else {
|
|
15028
|
-
const C = v.geometry.geometries.filter(
|
|
15029
|
-
(S) => S.type === "LineString" || S.type === "MultiLineString"
|
|
15012
|
+
setMarkers(d, E) {
|
|
15013
|
+
if (e) {
|
|
15014
|
+
for (const I of u)
|
|
15015
|
+
I.remove();
|
|
15016
|
+
if (u.length = 0, m(zs), !!t) {
|
|
15017
|
+
if (E) {
|
|
15018
|
+
let I = !1;
|
|
15019
|
+
if (E.geometry.type === "GeometryCollection") {
|
|
15020
|
+
const C = E.geometry.geometries.filter(
|
|
15021
|
+
(x) => x.type === "Polygon" || x.type === "MultiPolygon"
|
|
15030
15022
|
);
|
|
15031
|
-
C.length > 0
|
|
15032
|
-
|
|
15033
|
-
|
|
15034
|
-
|
|
15023
|
+
if (C.length > 0) {
|
|
15024
|
+
let x = C.pop();
|
|
15025
|
+
for (const R of C)
|
|
15026
|
+
x = gu(x, R);
|
|
15027
|
+
ks({ ...E, geometry: x }, m), I = !0;
|
|
15028
|
+
} else {
|
|
15029
|
+
const x = E.geometry.geometries.filter(
|
|
15030
|
+
(R) => R.type === "LineString" || R.type === "MultiLineString"
|
|
15031
|
+
);
|
|
15032
|
+
x.length > 0 && (m({
|
|
15033
|
+
...E,
|
|
15034
|
+
geometry: { type: "GeometryCollection", geometries: x }
|
|
15035
|
+
}), I = !0);
|
|
15036
|
+
}
|
|
15035
15037
|
}
|
|
15036
|
-
|
|
15037
|
-
|
|
15038
|
-
|
|
15039
|
-
|
|
15040
|
-
|
|
15041
|
-
|
|
15042
|
-
|
|
15038
|
+
if (!I) {
|
|
15039
|
+
if (E.geometry.type === "Polygon" || E.geometry.type === "MultiPolygon")
|
|
15040
|
+
ks(E, m);
|
|
15041
|
+
else if (E.geometry.type === "LineString" || E.geometry.type === "MultiLineString") {
|
|
15042
|
+
m(E);
|
|
15043
|
+
return;
|
|
15044
|
+
}
|
|
15043
15045
|
}
|
|
15046
|
+
e && u.push(
|
|
15047
|
+
(typeof e == "object" ? new t.Marker(e) : g()).setLngLat(E.center).addTo(n)
|
|
15048
|
+
);
|
|
15044
15049
|
}
|
|
15045
|
-
|
|
15046
|
-
(
|
|
15047
|
-
|
|
15050
|
+
if (r)
|
|
15051
|
+
for (const I of d ?? []) {
|
|
15052
|
+
if (I === E)
|
|
15053
|
+
continue;
|
|
15054
|
+
const C = (typeof r == "object" ? new t.Marker(r) : g(!0)).setLngLat(I.center).setPopup(
|
|
15055
|
+
new t.Popup({
|
|
15056
|
+
offset: [1, -27],
|
|
15057
|
+
closeButton: !1,
|
|
15058
|
+
closeOnMove: !0,
|
|
15059
|
+
className: "maptiler-gc-popup"
|
|
15060
|
+
}).setText(
|
|
15061
|
+
I.place_type[0] === "reverse" ? I.place_name : I.place_name.replace(/,.*/, "")
|
|
15062
|
+
)
|
|
15063
|
+
).addTo(n), x = C.getElement();
|
|
15064
|
+
x.addEventListener("click", (R) => {
|
|
15065
|
+
R.stopPropagation(), a == null || a({ type: "markerClick", id: I.id });
|
|
15066
|
+
}), x.addEventListener("mouseenter", () => {
|
|
15067
|
+
a == null || a({ type: "markerMouseEnter", id: I.id }), C.togglePopup();
|
|
15068
|
+
}), x.addEventListener("mouseleave", () => {
|
|
15069
|
+
a == null || a({ type: "markerMouseLeave", id: I.id }), C.togglePopup();
|
|
15070
|
+
}), u.push(C);
|
|
15071
|
+
}
|
|
15048
15072
|
}
|
|
15049
|
-
if (r)
|
|
15050
|
-
for (const E of p ?? []) {
|
|
15051
|
-
if (E === v)
|
|
15052
|
-
continue;
|
|
15053
|
-
const I = (typeof r == "object" ? new t.Marker(r) : g(!0)).setLngLat(E.center).setPopup(
|
|
15054
|
-
new t.Popup({
|
|
15055
|
-
offset: [1, -27],
|
|
15056
|
-
closeButton: !1,
|
|
15057
|
-
closeOnMove: !0,
|
|
15058
|
-
className: "maptiler-gc-popup"
|
|
15059
|
-
}).setText(
|
|
15060
|
-
E.place_type[0] === "reverse" ? E.place_name : E.place_name.replace(/,.*/, "")
|
|
15061
|
-
)
|
|
15062
|
-
).addTo(n), C = I.getElement();
|
|
15063
|
-
C.addEventListener("click", (S) => {
|
|
15064
|
-
S.stopPropagation(), a == null || a({ type: "markerClick", id: E.id });
|
|
15065
|
-
}), C.addEventListener("mouseenter", () => {
|
|
15066
|
-
a == null || a({ type: "markerMouseEnter", id: E.id }), I.togglePopup();
|
|
15067
|
-
}), C.addEventListener("mouseleave", () => {
|
|
15068
|
-
a == null || a({ type: "markerMouseLeave", id: E.id }), I.togglePopup();
|
|
15069
|
-
}), u.push(I);
|
|
15070
|
-
}
|
|
15071
15073
|
}
|
|
15072
15074
|
},
|
|
15073
|
-
setSelectedMarker(
|
|
15074
|
-
l && l.getElement().classList.toggle("marker-selected", !1), l =
|
|
15075
|
+
setSelectedMarker(d) {
|
|
15076
|
+
l && l.getElement().classList.toggle("marker-selected", !1), l = d > -1 ? u[d] : void 0, l == null || l.getElement().classList.toggle("marker-selected", !0);
|
|
15075
15077
|
},
|
|
15076
15078
|
getCenterAndZoom() {
|
|
15077
|
-
const
|
|
15078
|
-
return [n.getZoom(),
|
|
15079
|
+
const d = n.getCenter();
|
|
15080
|
+
return [n.getZoom(), d.lng, d.lat];
|
|
15079
15081
|
}
|
|
15080
15082
|
};
|
|
15081
15083
|
}
|