Ahmed90 / j2memaprouteprovider

Automatically exported from code.google.com/p/j2memaprouteprovider
0 stars 0 forks source link

The method toPixels(GeoPoint, Point) in the type Projection is not applicable for the arguments (GeoPoint, Point) #6

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Checkout the project using SVN in my eclipse IDE
2. Added missing android libraries in it.
3. Getting compile and syntax errors in the following method:
public void drawPath(MapView mv, Canvas canvas){
... 
...
Point point = new Point();
mv.getProjection().toPixels(mPoints.get(i), point);
x2 = point.x;
y2 = point.y;
}

What is the expected output? What do you see instead?
It should run smoothly.

What version of the product are you using? On what operating system?
Windows 7(32 bit)
Eclipse Helios
ADT - 16

Please provide any additional information below.
When I deployed the j2memaprouteproviderAndroidEx project in my eclipse ide, 
its showing erros in the above method on using toPixels() method. Its issuing 
this warning : "The method toPixels(GeoPoint, Point) in the type Projection is 
not applicable for the arguments (GeoPoint, Point)"
How to resolve the above problem? I am unable to run the project.
Please help.
Herewith I am attaching the screenshot of my IDE please check it. 

Original issue reported on code.google.com by yunuslun...@gmail.com on 20 Jun 2012 at 7:45

Attachments:

GoogleCodeExporter commented 9 years ago
hi 
can you pls tell me why do i have "null null" in the description and the name 
of the route ?? when i run the application it dispalys this "null,null" 
textView and closes 
and these are the logCat: 
08-01 14:28:30.738: E/MapActivity(682): Couldn't get connection factory client
08-01 14:28:31.598: W/System.err(682): 
org.apache.harmony.xml.ExpatParser$ParseException: At line 1, column 1083: not 
well-formed (invalid token)
08-01 14:28:31.609: W/System.err(682):  at 
org.apache.harmony.xml.ExpatParser.parseFragment(ExpatParser.java:515)
08-01 14:28:31.609: W/System.err(682):  at 
org.apache.harmony.xml.ExpatParser.parseDocument(ExpatParser.java:474)
08-01 14:28:31.609: W/System.err(682):  at 
org.apache.harmony.xml.ExpatReader.parse(ExpatReader.java:321)
08-01 14:28:31.669: W/System.err(682):  at 
org.apache.harmony.xml.ExpatReader.parse(ExpatReader.java:279)
08-01 14:28:31.769: W/System.err(682):  at 
javax.xml.parsers.SAXParser.parse(SAXParser.java:390)
08-01 14:28:31.769: W/System.err(682):  at 
javax.xml.parsers.SAXParser.parse(SAXParser.java:187)
08-01 14:28:31.769: W/System.err(682):  at 
org.ci.geo.route.RoadProvider.getRoute(RoadProvider.java:23)
08-01 14:28:31.769: W/System.err(682):  at 
com.test.MainActivity$2.run(MainActivity.java:50)
08-01 14:28:31.918: W/dalvikvm(682): threadid=1: thread exiting with uncaught 
exception (group=0x409c01f8)
08-01 14:28:32.079: E/AndroidRuntime(682): FATAL EXCEPTION: main
08-01 14:28:32.079: E/AndroidRuntime(682): java.lang.NullPointerException
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.test.MapOverlay.drawPath(MainActivity.java:126)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.test.MapOverlay.draw(MainActivity.java:116)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.google.android.maps.OverlayBundle.draw(OverlayBundle.java:42)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.google.android.maps.MapView.onDraw(MapView.java:530)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.View.draw(View.java:10978)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.drawChild(ViewGroup.java:2887)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.drawChild(ViewGroup.java:2885)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.drawChild(ViewGroup.java:2885)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.drawChild(ViewGroup.java:2885)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.View.draw(View.java:10981)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.widget.FrameLayout.draw(FrameLayout.java:450)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.android.internal.policy.impl.PhoneWindow$DecorView.draw(PhoneWindow.java:212
6)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewRootImpl.draw(ViewRootImpl.java:2026)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1634)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.view.ViewRootImpl.handleMessage(ViewRootImpl.java:2442)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.os.Handler.dispatchMessage(Handler.java:99)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.os.Looper.loop(Looper.java:137)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
android.app.ActivityThread.main(ActivityThread.java:4424)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
java.lang.reflect.Method.invokeNative(Native Method)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
java.lang.reflect.Method.invoke(Method.java:511)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
08-01 14:28:32.079: E/AndroidRuntime(682):  at 
dalvik.system.NativeStart.main(Native Method)

Original comment by berrich....@gmail.com on 31 Jul 2012 at 5:23