THIS SDK ISDEPRECATED.

We rolled out a new and better SDK for you.

Routing with language parameter

Allow your user to get results in different languages to make your app international. The language parameter determines the language of the guidance messages. It does not affect proper nouns (the names of streets, plazas, etc.)

Sample use case: You are planning a journey and you want to have the list of instructions in different languages.

To request a route using the language parameter:

1RouteDescriptor routeDescriptor = new RouteDescriptor.Builder()
2 .considerTraffic(false)
3 .build()
4
5RouteCalculationDescriptor routeCalculationDescriptor = new RouteCalculationDescriptor.Builder()
6 .routeDescription(routeDescriptor)
7 .maxAlternatives(0)
8 .reportType(ReportType.NONE)
9 .instructionType(InstructionsType.TEXT)
10 .language(language)
11 .build();
12
13RouteSpecification routeSpecification = new RouteSpecification.Builder(
14 routeConfig.getOrigin(),
15 routeConfig.getDestination()
16)
17 .routeCalculationDescriptor(routeCalculationDescriptor)
18 .build();