123456789101112131415161718192021222324252627 |
- import {
- U
- } from "./chunk-DVUG3KID.js";
- // node_modules/@arcgis/core/layers/support/fetchService.js
- async function r(e, r2) {
- var _a, _b, _c;
- let s = await a(e, r2);
- s = s || {}, s.layers = ((_a = s.layers) == null ? void 0 : _a.filter(t)) || [];
- const n = { serviceJSON: s };
- if (((_b = s.currentVersion) != null ? _b : 0) < 10.5)
- return n;
- const o = await a(e + "/layers", r2);
- return n.layersJSON = { layers: ((_c = o == null ? void 0 : o.layers) == null ? void 0 : _c.filter(t)) || [], tables: (o == null ? void 0 : o.tables) || [] }, n;
- }
- function t(e) {
- return !e.type || "Feature Layer" === e.type;
- }
- async function a(r2, t2) {
- return (await U(r2, { responseType: "json", query: { f: "json", ...t2 == null ? void 0 : t2.customParameters, token: t2 == null ? void 0 : t2.apiKey } })).data;
- }
- export {
- r,
- a
- };
- //# sourceMappingURL=chunk-KDQ32XYX.js.map
|