Hi,
We would like to better understand how the information whether a road segment can be used by a truck transporting ADR goods (any hazardous type) is available. We understand that we can request roads with a proper profile setting to avoid or to allow to use specific roads, the question is whether this information is available as an attribute on the segment on the result.
Can you help us to understand how this information is available both in case of xServer 1.x and 2.x?
Thanks in advance,
Aron
Segment level hazardous goods (ADR) information
-
- Posts: 3
- Joined: Mon Apr 27, 2020 9:50 am
- Location: HU-Budapest
- Contact:
- Bernd Welter
- Site Admin
- Posts: 2695
- Joined: Mon Apr 14, 2014 10:28 am
- Contact:
Re: Segment level hazardous goods (ADR) information
Hello Aron,
both routing APIs return the FeatureLayer attributes on request, the xRoute 1 also returns the old school truck attributes:
OK with that?
Bernd
both routing APIs return the FeatureLayer attributes on request, the xRoute 1 also returns the old school truck attributes:
- xRoute2 - FeatureLayer: request the result fields
returns segment infos:
Code: Select all
{ "waypoints": [ { "$type": "OffRoadWaypoint", "location": { "offRoadCoordinate": { "x": 8.4413785372, "y": 49.043582958 } } }, { "$type": "OffRoadWaypoint", "location": { "offRoadCoordinate": { "x": 8.3937854215, "y": 49.077491723 } } } ], "requestProfile":{ "featureLayerProfile" : { "themes": [ { "id":"PTV_TruckAttributes", "enabled": true } ] } }, "resultFields": { "segments": { "enabled": true, "featureThemeIds" : ["PTV_TruckAttributes"] } } }
Code: Select all
{ "distance": 93, "travelTime": 6.696, "travelSpeed": 50, "violated": false, "type": "NETWORK_SEGMENT", "attributes": { "features": [ { "themeId": "PTV_TruckAttributes", "attributes": [ { "key": "driveType", "value": "MOTOR_VEHICLE" }, { "key": "hazardousToWaters", "value": "1" } ] } ] } },
- xRoute1 - FeatureLayer:
request the resultListOptions.segments + resultListOptions.segmentAttributes and you will get:Code: Select all
{ "firstPolyIdx": 35, "polyC": 2, "firstNodeIdx": 31, "nodeC": 2, "streetNoIdx": -1, "streetNameIdx": -1, "dirInfoIdx": -1, "accTime": 361, "accDist": 3428, "normSpeed": { "normSpeed": 41, "normSpeedType": "STATIC" }, "iuCode": 49, "segmentAttr": { "brunnelCode": "NOTHING", "isFerry": false, "isBlockedCar": false, "isBlockedTruck": false, "hasTollCar": false, "hasTollTruck": false, "hasVignetteCar": false, "hasVignetteTruck": false, "hasExtraToll": false, "hasSeparator": false, "isPedestrianZone": false, "lowEmissionZoneType": "0", "isPiggyback": false }, "countryCode": "DE", "utcOffset": 120, "featureDescriptions": [ { "themeId": "PTV_TruckAttributes", "description": "driveType=0|hazardousGoods=1|freeForDelivery=1" }, { "themeId": "PTV_TruckAttributes", "description": "driveType=0|combustibles=1|freeForDelivery=1" }, { "themeId": "PTV_TruckAttributes", "description": "driveType=0|hazardousToWaters=1|freeForDelivery=1" } ], "vNorm": 0, "nC": "COUNTRY_ROAD", "vCalc": 41 },
- xRoute1 - tradditional BIN Layer:
Code: Select all
{ "firstPolyIdx": 37, "polyC": 2, "firstNodeIdx": 33, "nodeC": 2, "streetNoIdx": -1, "streetNameIdx": -1, "dirInfoIdx": -1, "accTime": 376, "accDist": 3599, "normSpeed": { "normSpeed": 41, "normSpeedType": "STATIC" }, "iuCode": 49, "segmentAttr": { "brunnelCode": "NOTHING", "isFerry": false, "isBlockedCar": false, "isBlockedTruck": false, "hasTollCar": false, "hasTollTruck": false, "hasVignetteCar": false, "hasVignetteTruck": false, "hasExtraToll": false, "hasSeparator": false, "isPedestrianZone": false, "additionalRE": "HAZARDOUS_TO_WATERS|0=1;HAZARDOUS_GOODS|0=1;COMBUSTIBLES|0=1", "lowEmissionZoneType": "0", "isPiggyback": false }, "countryCode": "DE", "utcOffset": 120, "vCalc": 41, "vNorm": 0, "nC": "COUNTRY_ROAD" },
OK with that?
Bernd
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany
Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning...
Technical Partner Manager Developer Components
PTV Logistics - Germany
Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning...
-
- Posts: 3
- Joined: Mon Apr 27, 2020 9:50 am
- Location: HU-Budapest
- Contact:
Re: Segment level hazardous goods (ADR) information
Hi Bernd,
Perfect, thank you for the prompt and thorough reply!
Perfect, thank you for the prompt and thorough reply!