I want com.google.android.maps library.
I am just creating a demo for Map on android mobile but at the
extends MapActivity it give error to create the class.
any downloadable link.
thanks in advance.
You need to download Google Api,and set build target as that Google Api.So that you can extend map activity.
you can find maps library from android-sdk-tools -> add-ons -> your api version.
You can find the maps.jar in the android-sdk folder on you file system
Download jar file from following link:
It is a bit old thread but someone might find it useful.
I had issues with Google Maps V1 and a dependency on it as suddenly
dependencies in Gradle were not loading
compileSdkVersion 'Google Inc.:Google APIs:23' which includes Maps V1, I switched to
compileSdkVersion 23 and got bunch of compile errors similar to OPs problem with
extends MapActivity. I went on to look for Jars for Maps V1 and found them hiding in:
List includes bunch of pointers to various
zip files eg:
... <archives> <archive> <!-- Built on: Mon Aug 15 05:06:51 2016. --> <complete> <size>86099835</size> <checksum>e9999f4fa978812174dfeceec0721c793a636e5d</checksum> <url>google_apis-12_r01.zip</url> </complete> </archive> </archives> ...
In order to download that zip file you need to take
<url> value and add it to
https://dl.google.com/android/repository/ which would end up looking like:
And after you download and unzip, you will get the sources:
google_apis-12_r01 | |-docs |-images |-libs | | | |- maps.jar | \- usb.jar | |-samples \-manifest.ini
Afterwards just drop
libs directory, make sure it is loaded in dependencies
compile fileTree(dir: 'libs', include: ['*.jar']) and your project should compile.
Here you can find the downloadable maps.jar http://www.java2s.com/Code/Jar/a/Downloadandroidgooglemapsapi8jar.htm