Page 1 of 1

xRoute2: RouteOptions.Currency released ( v2.20 )

Posted: Thu Oct 22, 2020 11:48 am
by Bernd Welter
Hi,

these days I was aksed about the handling of currencies in xRoute 2. Maybe you have already noticed that with the latest version v2.20 we also restructured and released some relevant properties. Here we are:
currency CurrencyCode (String) no - 2.20 Specifies the currency for costs both in the request and the response.
This will enable you to compute the following output (just an example) - I did request the prices in RUB (Russian Rubel)... of course you could also ask for EUR or other currencies. Just wanted to highlight an example where the requested currency itself isn't a local currency in any one of the involved countries...
Sample route from OSLO / Norway via COPENHAGEN/Denmark to BERLIN/Germany. Three waypoints, therefore two legs.
Sample route from OSLO / Norway via COPENHAGEN/Denmark to BERLIN/Germany. Three waypoints, therefore two legs.
detailed toll sections: national currencies  -  not all countries contribute with an official distance by the way
detailed toll sections: national currencies - not all countries contribute with an official distance by the way
client logic: toll sections aggregated  -  not all countries contribute with an official distance by the way
client logic: toll sections aggregated - not all countries contribute with an official distance by the way
Currencies.tollSections.aggregated.PNG (9.66 KiB) Viewed 2059 times
Toll per leg (Oslo to Copenhagen, Copenhagen to Berlin)
Toll per leg (Oslo to Copenhagen, Copenhagen to Berlin)
Currencies.tollPerLeg2.PNG (2.99 KiB) Viewed 2059 times
Just to be complete: the systems that are used...
Just to be complete: the systems that are used...
Currencies.tollSystems.PNG (11.24 KiB) Viewed 2059 times
So while the "price/per leg" is returned in the requested currency code the other prices are returned in the affected countries currency.

Best regards,
Bernd