Esri / android-gps-test-tool

Test all aspects of Android's location capabilities. Configurable for trying out different scenarios.
Apache License 2.0
112 stars 65 forks source link

Problem with esriquickstart.jar #4

Closed elbarsal closed 11 years ago

elbarsal commented 11 years ago

I'm having problems getting the code to run with the esriquickstart library - what version is the included jar? When I attempt to run with the included esriquickstart.jar, I get "NoClassDefFoundError for com.esri.quickstart.EsriQuickStart" - but when I downloaded the EsriQuickstart project (from https://github.com/Esri/quickstart-map-android), the syntax of some of the functions is different, so it won't compile. Any thoughts?

andygup commented 11 years ago

Good question, I'll clarify that in the README. The version of esriquickstart.jar included in the current repo seems to be v1.0 (Oops, my bad. I'll fix that). And it's been tested with v1.2.1.1 of the GPS Test Tool running Android v2.3, Android v4.2.2 and ArcGIS Runtime SDK for Android 10.1.1. My test environment is the latest ADT Bundle download.

I have a couple suggestions:

Did you download and install the ArcGIS Runtime SDK for Android? And, did you try explicitly including the jar in your Java Build Path?

andygup commented 11 years ago

@elbarsal I just tried out the GPS Tester v1.2.1.1 with the esriquickstart.jar v1.1 and it did work. As I mentioned above, double check all your environment settings.

I have another question, are you able to launch a Hello World map? The pattern is File > New > Project > ArcGIS Samples Android > Next > Local Samples > Select a Sample

Also be sure to check out the Install and Set up docs here to make sure everything is installed correctly: http://developers.arcgis.com/en/android/install.html

elbarsal commented 11 years ago

Hi Andy,

Yes, I did download and install the ArcGIS Runtime, tried multiple versions in fact. I have also checked the project settings, but I will try everything from scratch again. I'm using the ADT Bundle as well, updated to the latest.

Thanks for your help, I'll let you know if I can get it sorted.

andygup commented 11 years ago

@elbarsal can you please clarify a few details of your environment: what operating system and version? Which version of Eclipse? Which version of Java SE is installed? Thank you.

elbarsal commented 11 years ago

Hi Andy,

Somehow, after a full restart of my system, things are working, can't say I know why.

I'm running the Eclipse ADT Bundle version 21.0.1.201212060302 on Mac OS X 10.8.4, with the ArcGIS 10.1.1.201301161115.

Java: java version "1.6.0_45" Java(TM) SE Runtime Environment (build 1.6.0_45-b06-451-11M4406) Java HotSpot(TM) 64-Bit Server VM (build 20.45-b01-451, mixed mode)

When I first tried to use the GPSTester app, I was getting the NoClassDefFoundError. Now after playing with the project settings and starting from scratch, I was getting a method not defined error when the first fix would come in.

Side question - when I downloaded the EsriQuickStart package to try to use the source, the method signatures for some of the functions were different - particularly CenterAt (in the GPSTester code, there are four parameters, and in the EsriQuickStart v 1.2 code at https://github.com/Esri/quickstart-map-android/tree/master/EsriQuickStart there are only three - this prompted my initial version question.

Thanks for your help, wish I knew part of it what solved it though!

ed

andygup commented 11 years ago

Glad you got it working! As for the different method signatures, whoa you were absolutely right. I did a diff and because of a permissions error on my local machine the final copy of the v1.2 files didn't get updated and pushed, it was an earlier version that was committed. I've corrected that now and after double checking everything looks properly updated. Thank you for the heads up.

In regards to GPSTester, I will be updating it to use the new QuickStart v1.2 final. The current version is using a v1.2beta, which wasn't documented. Hopefully some of the confusion will be eliminated going forward now that I've started adding the version number to the quickstart.jar file (which I should have done in the first place) and from your feedback I'm going to be adding information into the GPSTester README about QuickStart version compatibility.

andygup commented 11 years ago

In regards to centerAt(), it is now correctly represented by an overloaded method with properties. There are no breaking changes. Also there were three additional public methods added:

clearPointsGraphicsLayer() clearDrawGraphicLayer() clearAllGraphics()