@esri/arcgis-rest-routing 4.0.0-beta.2 → 4.0.1

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.
@@ -1 +1 @@
1
- {"version":3,"file":"solveRoute.js","sourceRoot":"","sources":["../../src/solveRoute.ts"],"names":[],"mappings":"AAAA;gBACgB;AAEhB,OAAO,EACL,OAAO,EACP,QAAQ,EAKT,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EACL,yBAAyB,EAEzB,kBAAkB,EAClB,YAAY,EACb,MAAM,cAAc,CAAC;AAEtB,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AA+BtD,SAAS,eAAe,CACtB,MAAwE;IAExE,OAAO,CACJ,MAA2B,CAAC,MAAM,KAAK,CAAC;QACxC,MAAmC,CAAC,MAAM,KAAK,CAAC,CAClD,CAAC;AACJ,CAAC;AAED,SAAS,UAAU,CACjB,MAAwE;IAExE,OAAO,CACJ,MAAoB,CAAC,QAAQ,KAAK,SAAS;QAC3C,MAAoB,CAAC,GAAG,KAAK,SAAS,CACxC,CAAC;AACJ,CAAC;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,UAAU,UAAU,CACxB,cAAkC;IAElC,MAAM,OAAO,mBACX,QAAQ,EAAE,cAAc,CAAC,QAAQ,IAAI,yBAAyB,EAC9D,MAAM,EAAE,EAAE,IACP,cAAc,CAClB,CAAC;IAEF,uDAAuD;IACvD,IACE,CAAC,cAAc,CAAC,cAAc;QAC9B,OAAO,CAAC,QAAQ,KAAK,yBAAyB,EAC9C;QACA,OAAO,OAAO,CAAC,MAAM,CACnB,0DAA0D,CAC3D,CAAC;KACH;IAED,IAAI,YAAY,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE;QACtC,OAAO,CAAC,MAAM,CAAC,KAAK,GAAG,cAAc,CAAC,KAAK,CAAC;KAC7C;SAAM;QACL,MAAM,KAAK,GAAa,cAAc,CAAC,KAAK,CAAC,GAAG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,GAAG,CACjC,CAAC,SAKA,EAAE,EAAE;YACH,SAAS,CAAC,QAAQ,GAAG,SAAS,CAAC,QAAQ,CAAC,GAAG,CACzC,CAAC,OAAuC,EAAE,EAAE;gBAC1C,OAAO,CAAC,QAAQ,GAAG,kBAAkB,CAAC,OAAO,CAAC,kBAAkB,CAAC,CAAC;gBAClE,OAAO,OAAO,CAAC;YACjB,CAAC,CACF,CAAC;YACF,OAAO,SAAS,CAAC;QACnB,CAAC,CACF,CAAC;KACH;IAED,qCAAqC;IACrC,IAAI,GAAG,CAAC,MAAM,CAAC,gBAAgB,CAAC,IAAI,KAAK,IAAI,EAAE;QAC7C,MAAM,QAAQ,GAAG,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,OAAY,EAAE,EAAE;YACxD,OAAO;gBACL,IAAI,EAAE,SAAS;gBACf,QAAQ,EAAE,eAAe,CAAC,OAAO,CAAC,QAAQ,CAAC;gBAC3C,UAAU,EAAE,MAAM,CAAC,MAAM,CAAC,EAAE,EAAE,OAAO,CAAC,UAAU,CAAC;aAClD,CAAC;QACJ,CAAC,CAAC,CAAC;QAEH,GAAG,CAAC,MAAM,CAAC,OAAO,GAAG;YACnB,IAAI,EAAE,mBAAmB;YACzB,QAAQ;SACT,CAAC;KACH;IACD,OAAO,GAAG,CAAC;AACb,CAAC;AAED,eAAe;IACb,UAAU;CACX,CAAC","sourcesContent":["/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\r\n * Apache-2.0 */\r\n\r\nimport { \r\n request, \r\n cleanUrl, \r\n ILocation,\r\n IPoint,\r\n IFeature,\r\n IFeatureSet\r\n} from \"@esri/arcgis-rest-request\";\r\n\r\nimport {\r\n ARCGIS_ONLINE_ROUTING_URL,\r\n IEndpointOptions,\r\n decompressGeometry,\r\n isFeatureSet\r\n} from \"./helpers.js\";\r\n\r\nimport { arcgisToGeoJSON } from \"@terraformer/arcgis\";\r\n\r\ninterface IFeatureWithCompressedGeometry extends IFeature {\r\n compressedGeometry?: string;\r\n}\r\n\r\ninterface IFeatureSetWithGeoJson extends IFeatureSet {\r\n geoJson?: {};\r\n}\r\n\r\nexport interface ISolveRouteOptions extends IEndpointOptions {\r\n /**\r\n * Specify two or more locations between which the route is to be found.\r\n */\r\n stops:\r\n | Array<IPoint | ILocation | [number, number] | [number, number, number]>\r\n | IFeatureSet;\r\n}\r\n\r\nexport interface ISolveRouteResponse {\r\n messages: string[];\r\n checksum: string;\r\n routes: IFeatureSetWithGeoJson;\r\n directions?: Array<{\r\n routeId: number;\r\n routeName: string;\r\n summary: object;\r\n features: IFeature[];\r\n }>;\r\n}\r\n\r\nfunction isLocationArray(\r\n coords: ILocation | IPoint | [number, number] | [number, number, number]\r\n): coords is [number, number] | [number, number, number] {\r\n return (\r\n (coords as [number, number]).length === 2 ||\r\n (coords as [number, number, number]).length === 3\r\n );\r\n}\r\n\r\nfunction isLocation(\r\n coords: ILocation | IPoint | [number, number] | [number, number, number]\r\n): coords is ILocation {\r\n return (\r\n (coords as ILocation).latitude !== undefined ||\r\n (coords as ILocation).lat !== undefined\r\n );\r\n}\r\n\r\n/**\r\n * ```js\r\n * import { solveRoute } from '@esri/arcgis-rest-routing';\r\n * //\r\n * solveRoute({\r\n * stops: [\r\n * [-117.195677, 34.056383],\r\n * [-117.918976, 33.812092],\r\n * ],\r\n * authentication\r\n * })\r\n * .then(response) // => {routes: {features: [{attributes: { ... }, geometry:{ ... }}]}\r\n * ```\r\n * Used to find the best way to get from one location to another or to visit several locations. See the [REST Documentation](https://developers.arcgis.com/rest/network/api-reference/route-synchronous-service.htm) for more information.\r\n *\r\n * @param requestOptions Options to pass through to the routing service.\r\n * @returns A Promise that will resolve with routes and directions for the request.\r\n * @restlink https://developers.arcgis.com/rest/network/api-reference/route-synchronous-service.htm\r\n */\r\nexport function solveRoute(\r\n requestOptions: ISolveRouteOptions\r\n): Promise<ISolveRouteResponse> {\r\n const options: ISolveRouteOptions = {\r\n endpoint: requestOptions.endpoint || ARCGIS_ONLINE_ROUTING_URL,\r\n params: {},\r\n ...requestOptions\r\n };\r\n\r\n // the SAAS service does not support anonymous requests\r\n if (\r\n !requestOptions.authentication &&\r\n options.endpoint === ARCGIS_ONLINE_ROUTING_URL\r\n ) {\r\n return Promise.reject(\r\n \"Routing using the ArcGIS service requires authentication\"\r\n );\r\n }\r\n\r\n if (isFeatureSet(requestOptions.stops)) {\r\n options.params.stops = requestOptions.stops;\r\n } else {\r\n const stops: string[] = requestOptions.stops.map((coords) => {\r\n if (isLocationArray(coords)) {\r\n return coords.join();\r\n } else if (isLocation(coords)) {\r\n if (coords.lat) {\r\n return (\r\n coords.long + \",\" + coords.lat + (coords.z ? \",\" + coords.z : \"\")\r\n );\r\n } else {\r\n return (\r\n coords.longitude +\r\n \",\" +\r\n coords.latitude +\r\n (coords.z ? \",\" + coords.z : \"\")\r\n );\r\n }\r\n } else {\r\n return coords.x + \",\" + coords.y + (coords.z ? \",\" + coords.z : \"\");\r\n }\r\n });\r\n\r\n options.params.stops = stops.join(\";\");\r\n }\r\n\r\n return request(`${cleanUrl(options.endpoint)}/solve`, options).then(\r\n cleanResponse\r\n );\r\n}\r\n\r\nfunction cleanResponse(res: any): ISolveRouteResponse {\r\n if (res.directions && res.directions.length > 0) {\r\n res.directions = res.directions.map(\r\n (direction: {\r\n features: IFeatureWithCompressedGeometry[];\r\n routeId: number;\r\n routeName: string;\r\n summary: {};\r\n }) => {\r\n direction.features = direction.features.map(\r\n (feature: IFeatureWithCompressedGeometry) => {\r\n feature.geometry = decompressGeometry(feature.compressedGeometry);\r\n return feature;\r\n }\r\n );\r\n return direction;\r\n }\r\n );\r\n }\r\n\r\n // add \"geoJson\" property to \"routes\"\r\n if (res.routes.spatialReference.wkid === 4326) {\r\n const features = res.routes.features.map((feature: any) => {\r\n return {\r\n type: \"Feature\",\r\n geometry: arcgisToGeoJSON(feature.geometry),\r\n properties: Object.assign({}, feature.attributes)\r\n };\r\n });\r\n\r\n res.routes.geoJson = {\r\n type: \"FeatureCollection\",\r\n features\r\n };\r\n }\r\n return res;\r\n}\r\n\r\nexport default {\r\n solveRoute\r\n};\r\n"]}
1
+ {"version":3,"file":"solveRoute.js","sourceRoot":"","sources":["../../src/solveRoute.ts"],"names":[],"mappings":"AAAA;gBACgB;AAEhB,OAAO,EACL,OAAO,EACP,QAAQ,EAKT,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EACL,yBAAyB,EAEzB,kBAAkB,EAClB,YAAY,EACb,MAAM,cAAc,CAAC;AAEtB,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AA+BtD,SAAS,eAAe,CACtB,MAAwE;IAExE,OAAO,CACJ,MAA2B,CAAC,MAAM,KAAK,CAAC;QACxC,MAAmC,CAAC,MAAM,KAAK,CAAC,CAClD,CAAC;AACJ,CAAC;AAED,SAAS,UAAU,CACjB,MAAwE;IAExE,OAAO,CACJ,MAAoB,CAAC,QAAQ,KAAK,SAAS;QAC3C,MAAoB,CAAC,GAAG,KAAK,SAAS,CACxC,CAAC;AACJ,CAAC;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,UAAU,UAAU,CACxB,cAAkC;IAElC,MAAM,OAAO,mBACX,QAAQ,EAAE,cAAc,CAAC,QAAQ,IAAI,yBAAyB,EAC9D,MAAM,EAAE,EAAE,IACP,cAAc,CAClB,CAAC;IAEF,uDAAuD;IACvD,IACE,CAAC,cAAc,CAAC,cAAc;QAC9B,OAAO,CAAC,QAAQ,KAAK,yBAAyB,EAC9C;QACA,OAAO,OAAO,CAAC,MAAM,CACnB,0DAA0D,CAC3D,CAAC;KACH;IAED,IAAI,YAAY,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE;QACtC,OAAO,CAAC,MAAM,CAAC,KAAK,GAAG,cAAc,CAAC,KAAK,CAAC;KAC7C;SAAM;QACL,MAAM,KAAK,GAAa,cAAc,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;YAC1D,IAAI,eAAe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AAC,QAAQ,GAAG,SAAS,CAAC,QAAQ,CAAC,GAAG,CACzC,CAAC,OAAuC,EAAE,EAAE;gBAC1C,OAAO,CAAC,QAAQ,GAAG,kBAAkB,CAAC,OAAO,CAAC,kBAAkB,CAAC,CAAC;gBAClE,OAAO,OAAO,CAAC;YACjB,CAAC,CACF,CAAC;YACF,OAAO,SAAS,CAAC;QACnB,CAAC,CACF,CAAC;KACH;IAED,qCAAqC;IACrC,IAAI,GAAG,CAAC,MAAM,CAAC,gBAAgB,CAAC,IAAI,KAAK,IAAI,EAAE;QAC7C,MAAM,QAAQ,GAAG,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,OAAY,EAAE,EAAE;YACxD,OAAO;gBACL,IAAI,EAAE,SAAS;gBACf,QAAQ,EAAE,eAAe,CAAC,OAAO,CAAC,QAAQ,CAAC;gBAC3C,UAAU,EAAE,MAAM,CAAC,MAAM,CAAC,EAAE,EAAE,OAAO,CAAC,UAAU,CAAC;aAClD,CAAC;QACJ,CAAC,CAAC,CAAC;QAEH,GAAG,CAAC,MAAM,CAAC,OAAO,GAAG;YACnB,IAAI,EAAE,mBAAmB;YACzB,QAAQ;SACT,CAAC;KACH;IACD,OAAO,GAAG,CAAC;AACb,CAAC;AAED,eAAe;IACb,UAAU;CACX,CAAC","sourcesContent":["/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n\nimport {\n request,\n cleanUrl,\n ILocation,\n IPoint,\n IFeature,\n IFeatureSet\n} from \"@esri/arcgis-rest-request\";\n\nimport {\n ARCGIS_ONLINE_ROUTING_URL,\n IEndpointOptions,\n decompressGeometry,\n isFeatureSet\n} from \"./helpers.js\";\n\nimport { arcgisToGeoJSON } from \"@terraformer/arcgis\";\n\ninterface IFeatureWithCompressedGeometry extends IFeature {\n compressedGeometry?: string;\n}\n\ninterface IFeatureSetWithGeoJson extends IFeatureSet {\n geoJson?: {};\n}\n\nexport interface ISolveRouteOptions extends IEndpointOptions {\n /**\n * Specify two or more locations between which the route is to be found.\n */\n stops:\n | Array<IPoint | ILocation | [number, number] | [number, number, number]>\n | IFeatureSet;\n}\n\nexport interface ISolveRouteResponse {\n messages: string[];\n checksum: string;\n routes: IFeatureSetWithGeoJson;\n directions?: Array<{\n routeId: number;\n routeName: string;\n summary: object;\n features: IFeature[];\n }>;\n}\n\nfunction isLocationArray(\n coords: ILocation | IPoint | [number, number] | [number, number, number]\n): coords is [number, number] | [number, number, number] {\n return (\n (coords as [number, number]).length === 2 ||\n (coords as [number, number, number]).length === 3\n );\n}\n\nfunction isLocation(\n coords: ILocation | IPoint | [number, number] | [number, number, number]\n): coords is ILocation {\n return (\n (coords as ILocation).latitude !== undefined ||\n (coords as ILocation).lat !== undefined\n );\n}\n\n/**\n * Used to find the best way to get from one location to another or to visit several locations. See the [REST Documentation](https://developers.arcgis.com/rest/network/api-reference/route-synchronous-service.htm) for more information.\n *\n * ```js\n * import { solveRoute } from '@esri/arcgis-rest-routing';\n *\n * solveRoute({\n * stops: [\n * [-117.195677, 34.056383],\n * [-117.918976, 33.812092],\n * ],\n * authentication\n * })\n * .then(response) // => {routes: {features: [{attributes: { ... }, geometry:{ ... }}]}\n * ```\n *\n * @param requestOptions Options to pass through to the routing service.\n * @returns A Promise that will resolve with routes and directions for the request.\n * @restlink https://developers.arcgis.com/rest/network/api-reference/route-synchronous-service.htm\n */\nexport function solveRoute(\n requestOptions: ISolveRouteOptions\n): Promise<ISolveRouteResponse> {\n const options: ISolveRouteOptions = {\n endpoint: requestOptions.endpoint || ARCGIS_ONLINE_ROUTING_URL,\n params: {},\n ...requestOptions\n };\n\n // the SAAS service does not support anonymous requests\n if (\n !requestOptions.authentication &&\n options.endpoint === ARCGIS_ONLINE_ROUTING_URL\n ) {\n return Promise.reject(\n \"Routing using the ArcGIS service requires authentication\"\n );\n }\n\n if (isFeatureSet(requestOptions.stops)) {\n options.params.stops = requestOptions.stops;\n } else {\n const stops: string[] = requestOptions.stops.map((coords) => {\n if (isLocationArray(coords)) {\n return coords.join();\n } else if (isLocation(coords)) {\n if (coords.lat) {\n return (\n coords.long + \",\" + coords.lat + (coords.z ? \",\" + coords.z : \"\")\n );\n } else {\n return (\n coords.longitude +\n \",\" +\n coords.latitude +\n (coords.z ? \",\" + coords.z : \"\")\n );\n }\n } else {\n return coords.x + \",\" + coords.y + (coords.z ? \",\" + coords.z : \"\");\n }\n });\n\n options.params.stops = stops.join(\";\");\n }\n\n return request(`${cleanUrl(options.endpoint)}/solve`, options).then(\n cleanResponse\n );\n}\n\nfunction cleanResponse(res: any): ISolveRouteResponse {\n if (res.directions && res.directions.length > 0) {\n res.directions = res.directions.map(\n (direction: {\n features: IFeatureWithCompressedGeometry[];\n routeId: number;\n routeName: string;\n summary: {};\n }) => {\n direction.features = direction.features.map(\n (feature: IFeatureWithCompressedGeometry) => {\n feature.geometry = decompressGeometry(feature.compressedGeometry);\n return feature;\n }\n );\n return direction;\n }\n );\n }\n\n // add \"geoJson\" property to \"routes\"\n if (res.routes.spatialReference.wkid === 4326) {\n const features = res.routes.features.map((feature: any) => {\n return {\n type: \"Feature\",\n geometry: arcgisToGeoJSON(feature.geometry),\n properties: Object.assign({}, feature.attributes)\n };\n });\n\n res.routes.geoJson = {\n type: \"FeatureCollection\",\n features\n };\n }\n return res;\n}\n\nexport default {\n solveRoute\n};\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@esri/arcgis-rest-routing",
3
- "version": "4.0.0-beta.2",
3
+ "version": "4.0.1",
4
4
  "description": "Routing helpers for @esri/arcgis-rest-js",
5
5
  "license": "Apache-2.0",
6
6
  "keywords": [
@@ -31,7 +31,9 @@
31
31
  "postbuild": "node ../../scripts/create-dist-package-jsons.js",
32
32
  "build:bundled": "rollup -c ../../rollup.js",
33
33
  "build:cjs": "tsc --outDir ./dist/cjs -m commonjs",
34
+ "postbuild:cjs": "node ../../scripts/create-dist-package-jsons.js",
34
35
  "build:esm": "tsc --outDir ./dist/esm --declaration",
36
+ "postbuild:esm": "node ../../scripts/create-dist-package-jsons.js",
35
37
  "dev": "npm-run-all --parallel dev:*",
36
38
  "dev:bundled": "rollup -w -c ../../rollup.js",
37
39
  "dev:cjs": "tsc -w --outDir ./dist/cjs -m commonjs",
@@ -46,10 +48,10 @@
46
48
  "tslib": "^2.3.0"
47
49
  },
48
50
  "peerDependencies": {
49
- "@esri/arcgis-rest-request": "4.0.0-beta.2"
51
+ "@esri/arcgis-rest-request": "4.0.1"
50
52
  },
51
53
  "devDependencies": {
52
- "@esri/arcgis-rest-request": "4.0.0-beta.2"
54
+ "@esri/arcgis-rest-request": "4.0.1"
53
55
  },
54
56
  "contributors": [
55
57
  "Gavin Rehkemper <gavin@gavinr.com>"
@@ -65,5 +67,16 @@
65
67
  },
66
68
  "publishConfig": {
67
69
  "access": "public"
70
+ },
71
+ "esri": {
72
+ "keyExports": [
73
+ "closestFacility",
74
+ "decompressGeometry",
75
+ "isFeatureSet",
76
+ "normalizeLocationsList",
77
+ "originDestinationMatrix",
78
+ "serviceArea",
79
+ "solveRoute"
80
+ ]
68
81
  }
69
82
  }