I searched a lot i didn\'t find any proper solution for it.Help and link could be appreciated :-)
Try this -
@Override
public void onMapReady(GoogleMap map) {
// Add a thin red line from A to B.
Polyline line1 = map.addPolyline(new PolylineOptions()
.add(new LatLng(40.1, -74.2), new LatLng(40.7, -74.0))
.width(5)
.color(Color.RED));
and then another line from B to C with a different color and so on
Polyline line2 = map.addPolyline(new PolylineOptions()
.add(new LatLng(40.7, -74.0), new LatLng(41.3, -74.5))
.width(5)
.color(Color.GREEN));
....
Note that getMapAsync() is the new preferred way to get the map object. https://developers.google.com/maps/documentation/android-api/map
Polyline details here - https://developers.google.com/android/reference/com/google/android/gms/maps/model/Polyline