Incompatible types List of List and ArrayList of ArrayList
Hello everybody, I am using google maps api to display a kml layer ... after rebuilding the project I got an issue in the google maps api's java file KmlPolygonTest.java ... in this function :
public KmlPolygon createRegularPolygon() {
ArrayList<LatLng> outerCoordinates = new ArrayList<LatLng>();
outerCoordinates.add(new LatLng(10, 10));
outerCoordinates.add(new LatLng(20, 20));
outerCoordinates.add(new LatLng(30, 30));
outerCoordinates.add(new LatLng(10, 10));
ArrayList<ArrayList<LatLng>> innerCoordinates = new ArrayList<ArrayList<LatLng>>();
ArrayList<LatLng> innerHole = new ArrayList<LatLng>();
innerHole.add(new LatLng(20, 20));
innerHole.add(new LatLng(10, 10));
innerHole.add(new LatLng(20, 20));
innerCoordinates.add(innerHole);
return new KmlPolygon(**outerCoordinates**, **innerCoordinates**);
}
specifically at words in bold ...
the compiler says :
"Error:(30, 49) error: incompatible types: ArrayList<ArrayList
Compilation failed; see the compiler error output for details. " here is a screenshot..

You should be able to fix this by changing your ArrayList declarations to just List. See https://github.com/googlemaps/android-maps-utils/commit/9be09a2e4a77a222d62d5719bcaa6413dcf373f6 for an example. If that doesn't work, let us know!
it worked thank u :)