GWT + gwt-maps + GEPlugin = a whole lotta wow!

152 views
Skip to first unread message

jdc

unread,
Jun 6, 2008, 7:22:12 PM6/6/08
to Google Web Toolkit
all,

i'm sure others have come to the same conclusion that i did, that by
combining all of the goodness Google has been serving up lately, one
can make rather amazing GIS applications. i have been working on a
GWT WebMapServer client as a 20% project for quite some time now (more
like 80% the last few days). with a day of work, i modified my
MapView widget to use the gwt-maps MapWidget (a wrapper around Google
Maps). by changing my WMS client code so that i made GroundOverlays
instead of Images, i was able to place my WMS imagery over Google Maps
imagery and it was good. "Great", says my boss, "but what about
Google Earth?" (that's all the ever say: what about Google Earth?...)

so i've been playing with the Google Earth Plugin since it was
released, and i was pleased to learn that including it in a Google
Maps application is a very simple process. "okay", i thought, "but
what about GWT?" gwt-maps-0.0.29 was great for getting my application
up and running with Google Maps, but does it expose the GEPlugin?
sadly, no, it does not. but it was a simple enough process to check
out gwt-google-apis and add in the EarthMapType, recompile, and voila!
i've got Earth in my GWT map app!

screenshots can be seen here <a href="http://www.flickr.com/photos/
bedtime/2556505333/" title="webcop2-on-ge by diegofive0, on
Flickr"><img src="http://farm4.static.flickr.com/
3047/2556505333_14ab9b65b0.jpg" width="500" height="249" alt="webcop2-
on-ge" /></a> and here <a href="http://www.flickr.com/photos/bedtime/
2556505087/" title="webcop2-tsunami-wms-on-google-maps by diegofive0,
on Flickr"><img src="http://farm3.static.flickr.com/
2227/2556505087_e6b2f6a0f5_o.png" width="1270" height="632"
alt="webcop2-tsunami-wms-on-google-maps" /></a>.

sadly, once i go to Earth mode, my GroundOverlays do not appear. i'm
debugging that issue now.

if you (like me) just can't wait for the next gwt-maps release in
order to start integrating GE into your GWT app, try these mods:

in com.google.gwt.maps.client.impl.MapTypeImpl, add:

@Global("$wnd.G_SATELLITE_3D_MAP")
JavaScriptObject getEarthMapType();

in com.google.gwt.maps.client.MapType

-add the following static field
private static MapType earthMap;

-add the following static method
/**
* Returns a map type that shows Google Earth using the browser
plugin.
*
* @return a map type that shows Google Earth.
*/
public static MapType getEarthMap() {
initMapTypes();
return earthMap;
}

-add the following line to the static initMapTypes method (add it
before the mapTypesInitialized = true; line)
earthMap = createPeer(MapTypeImpl.impl.getEarthMapType());

hope that gives some others some good ideas.
many thanks to the army of flying monkeys at google for making my job
oh-so-much easier.


jdc

jdc

unread,
Jun 6, 2008, 7:24:59 PM6/6/08
to Google Web Toolkit
sorry, those links are awful (whatever happened to previewing before
posting?)

these are a bit simpler

http://www.flickr.com/photos/bedtime/2556505087/sizes/o/

http://www.flickr.com/photos/bedtime/2556505333/sizes/o/

Eric B

unread,
Jun 7, 2008, 12:17:05 PM6/7/08
to Google Web Toolkit
You may want to check out the GWT Google API's project,
http://code.google.com/p/gwt-google-apis/. It's a google run project
for porting their API's to GWT. Their Google Maps implementation
(from subversion, not the download), is pretty good.

Thanks,
Eric

jdc

unread,
Jun 7, 2008, 12:27:07 PM6/7/08
to Google Web Toolkit
Eric,

the gwt-maps-0.0.29 jar i was referring to IS the GWT Google API's
maps jar.
the classes that i added mods to were from the svn version of gwt-
google-apis/maps code.
i fully expect the googlites to add Earth support to gwt-maps.jar,
i just couldn't wait!

thanks,
jdc

On Jun 7, 9:17 am, Eric B <ebesse...@gmail.com> wrote:
> You may want to check out the GWT Google API's project,http://code.google.com/p/gwt-google-apis/. It's a google run project

Eric Ayers

unread,
Jun 8, 2008, 8:39:02 AM6/8/08
to Google-We...@googlegroups.com
Hey jdc,

Thanks for posting this!  A patch is on its way to make it into the next milestone.

I entered issue 128 to track it:

http://code.google.com/p/gwt-google-apis/issues/detail?id=128

You can open it and star it to be notified when its status changes.

Could you please fill out a Contributor License Agreement (CLA) at: http://code.google.com/webtoolkit/makinggwtbetter.html

If you have more contributions, I would appreciate it if you could post a patch made with 'svn diff' or the equivalent using a subversion tool and send a message to the GWT contributors mailing list. 


Regards,
-Eric.
--
Eric Z. Ayers - GWT Team - Atlanta, GA USA
http://code.google.com/webtoolkit/

Asaf Lahav

unread,
Jun 7, 2008, 7:11:03 PM6/7/08
to Google-We...@googlegroups.com
When building a GWT project using the cypal plugin for eclipse, I'm getting
the following output (with an exception in the end of it):

Loading module 'com.pg.gwt.tests.modules.first.MyModule'
Module location:
file:/C:/eclipse3.3/workspace/GWT/com.pg.gwt.tests/src/com/pg/gwt/tests/modu
les/first/MyModule.gwt.xml
Loading inherited module 'com.google.gwt.user.User'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/User.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/core/Core.gwt.xml
Loading inherited module
'com.google.gwt.dev.jjs.intrinsic.Intrinsic'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-dev-windo
ws.jar!/com/google/gwt/dev/jjs/intrinsic/Intrinsic.gwt.xml
Loading inherited module 'com.google.gwt.lang.LongLib'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-dev-windo
ws.jar!/com/google/gwt/lang/LongLib.gwt.xml
Loading inherited module 'com.google.gwt.emul.Emulation'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/emul/Emulation.gwt.xml
Loading inherited module 'com.google.gwt.animation.Animation'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/animation/Animation.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.User'
Module 'com.google.gwt.user.User' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.RemoteService'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/RemoteService.gwt.xml
Loading inherited module 'com.google.gwt.http.HTTP'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/http/HTTP.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.DocumentRoot'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/DocumentRoot.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/UserAgent.gwt.xml
Loading inherited module 'com.google.gwt.user.DOM'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/DOM.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.dom.DOM'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/dom/DOM.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been
loaded and will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.Window'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/Window.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.HTTPRequest'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/HTTPRequest.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.History'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/History.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.i18n.I18N'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/i18n/I18N.gwt.xml
Loading inherited module 'com.google.gwt.user.Popup'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/Popup.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.Form'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/Form.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.TextBox'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/TextBox.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.Focus'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/Focus.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.ImageBundle'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/ImageBundle.gwt.xml
Loading inherited module 'com.google.gwt.user.ClippedImage'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/ClippedImage.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been
loaded and will be skipped
Loading inherited module 'com.google.gwt.user.ClippedImage'
Module 'com.google.gwt.user.ClippedImage' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.RichText'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/RichText.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.SplitPanel'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/SplitPanel.gwt.xml
Loading inherited module 'com.google.gwt.user.User'
Module 'com.google.gwt.user.User' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.ListBox'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/ListBox.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.DOM'
Module 'com.google.gwt.user.DOM' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.CaptionPanel'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/CaptionPanel.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Loading inherited module 'com.google.gwt.user.Window'
Module 'com.google.gwt.user.Window' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.Accessibility'
Module location:
jar:file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar!
/com/google/gwt/user/Accessibility.gwt.xml
Loading inherited module 'com.google.gwt.core.Core'
Module 'com.google.gwt.core.Core' has already been loaded and
will be skipped
Loading inherited module 'com.google.gwt.user.UserAgent'
Module 'com.google.gwt.user.UserAgent' has already been loaded
and will be skipped
Public resources found in...
Refreshing resources
Searching for resources within
file:/C:/Tomcat/common/lib/commons-el.jar
Indexing zip file: C:\Tomcat\common\lib\commons-el.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jasper-compiler-jdt.jar
Indexing zip file: C:\Tomcat\common\lib\jasper-compiler-jdt.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jasper-compiler.jar
Indexing zip file: C:\Tomcat\common\lib\jasper-compiler.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jasper-runtime.jar
Indexing zip file: C:\Tomcat\common\lib\jasper-runtime.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jsp-api.jar
Indexing zip file: C:\Tomcat\common\lib\jsp-api.jar
Searching for resources within
file:/C:/Tomcat/common/lib/naming-factory-dbcp.jar
Indexing zip file: C:\Tomcat\common\lib\naming-factory-dbcp.jar
Searching for resources within
file:/C:/Tomcat/common/lib/naming-factory.jar
Indexing zip file: C:\Tomcat\common\lib\naming-factory.jar
Searching for resources within
file:/C:/Tomcat/common/lib/naming-resources.jar
Indexing zip file: C:\Tomcat\common\lib\naming-resources.jar
Searching for resources within
file:/C:/Tomcat/common/lib/servlet-api.jar
Indexing zip file: C:\Tomcat\common\lib\servlet-api.jar
Searching for resources within
file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-servlet.jar
Indexing zip file:
C:\downloads\GWT\gwt-windows-1.5.0\gwt-windows-1.5.0\gwt-servlet.jar
Searching for resources within
file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar
Indexing zip file:
C:\downloads\GWT\gwt-windows-1.5.0\gwt-windows-1.5.0\gwt-user.jar
Searching for resources within
file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-dev-windows.j
ar
Indexing zip file:
C:\downloads\GWT\gwt-windows-1.5.0\gwt-windows-1.5.0\gwt-dev-windows.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/dnsns.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\dnsns.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/localedata.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\localedata.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/sunjce_provider.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\sunjce_provider.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/sunpkcs11.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\sunpkcs11.jar
Translatable source found in...
Refreshing resources
Searching for resources within
file:/C:/Tomcat/common/lib/commons-el.jar
Indexing zip file: C:\Tomcat\common\lib\commons-el.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jasper-compiler-jdt.jar
Indexing zip file: C:\Tomcat\common\lib\jasper-compiler-jdt.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jasper-compiler.jar
Indexing zip file: C:\Tomcat\common\lib\jasper-compiler.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jasper-runtime.jar
Indexing zip file: C:\Tomcat\common\lib\jasper-runtime.jar
Searching for resources within
file:/C:/Tomcat/common/lib/jsp-api.jar
Indexing zip file: C:\Tomcat\common\lib\jsp-api.jar
Searching for resources within
file:/C:/Tomcat/common/lib/naming-factory-dbcp.jar
Indexing zip file: C:\Tomcat\common\lib\naming-factory-dbcp.jar
Searching for resources within
file:/C:/Tomcat/common/lib/naming-factory.jar
Indexing zip file: C:\Tomcat\common\lib\naming-factory.jar
Searching for resources within
file:/C:/Tomcat/common/lib/naming-resources.jar
Indexing zip file: C:\Tomcat\common\lib\naming-resources.jar
Searching for resources within
file:/C:/Tomcat/common/lib/servlet-api.jar
Indexing zip file: C:\Tomcat\common\lib\servlet-api.jar
Searching for resources within
file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-servlet.jar
Indexing zip file:
C:\downloads\GWT\gwt-windows-1.5.0\gwt-windows-1.5.0\gwt-servlet.jar
Searching for resources within
file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-user.jar
Indexing zip file:
C:\downloads\GWT\gwt-windows-1.5.0\gwt-windows-1.5.0\gwt-user.jar
Searching for resources within
file:/C:/downloads/GWT/gwt-windows-1.5.0/gwt-windows-1.5.0/gwt-dev-windows.j
ar
Indexing zip file:
C:\downloads\GWT\gwt-windows-1.5.0\gwt-windows-1.5.0\gwt-dev-windows.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/dnsns.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\dnsns.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/localedata.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\localedata.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/sunjce_provider.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\sunjce_provider.jar
Searching for resources within
file:/C:/Program%20Files/Java/jre1.5.0_10/lib/ext/sunpkcs11.jar
Indexing zip file: C:\Program
Files\Java\jre1.5.0_10\lib\ext\sunpkcs11.jar
Exception in thread "main" java.lang.NoSuchMethodError:
org.eclipse.jdt.internal.compiler.Compiler.<init>(Lorg/eclipse/jdt/internal/
compiler/env/INameEnvironment;Lorg/eclipse/jdt/internal/compiler/IErrorHandl
ingPolicy;Lorg/eclipse/jdt/internal/compiler/impl/CompilerOptions;Lorg/eclip
se/jdt/internal/compiler/ICompilerRequestor;Lorg/eclipse/jdt/internal/compil
er/IProblemFactory;)V
at
com.google.gwt.dev.javac.JdtCompiler$CompilerImpl.<init>(JdtCompiler.java:93
)
at com.google.gwt.dev.javac.JdtCompiler.<init>(JdtCompiler.java:233)
at
com.google.gwt.dev.javac.JdtCompiler.compile(JdtCompiler.java:194)
at
com.google.gwt.dev.javac.CompilationState.compile(CompilationState.java:72)
at com.google.gwt.dev.GWTCompiler.distill(GWTCompiler.java:327)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:564)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:554)
at com.google.gwt.dev.GWTCompiler.main(GWTCompiler.java:214)

Thanks,
Asaf

jdc

unread,
Jun 9, 2008, 2:19:13 PM6/9/08
to Google Web Toolkit
Eric,

i'll sign the CLA shortly, i just need to inform my bosses.

also, i want to undo Asaf's thread-jacking...


jdc


On Jun 8, 5:39 am, "Eric Ayers" <zun...@google.com> wrote:
> Hey jdc,
>
> Thanks for posting this! A patch is on its way to make it into the next
> milestone.
>
> I entered issue 128 to track it:
>
> http://code.google.com/p/gwt-google-apis/issues/detail?id=128
>
> You can open it and star it to be notified when its status changes.
> Could you please fill out a Contributor License Agreement (CLA) at:http://code.google.com/webtoolkit/makinggwtbetter.htmlIfyou have more

Quan

unread,
Jun 14, 2008, 4:40:55 PM6/14/08
to Google Web Toolkit
hey jdc,

Could you please go over the process to incorporate your changes. I
assume you recompile the source to a jar file and replace the r290 gwt-
apis. I'm not familiar with svn or jar creation.

Thanks,

On Jun 9, 2:19 pm, jdc <jesse.cross...@gmail.com> wrote:
> Eric,
>
> i'll sign the CLA shortly, i just need to inform my bosses.
>
> also, i want to undo Asaf's thread-jacking...
>
> jdc
>
> On Jun 8, 5:39 am, "Eric Ayers" <zun...@google.com> wrote:
>
> > Hey jdc,
>
> > Thanks for posting this! A patch is on its way to make it into the next
> > milestone.
>
> > I entered issue 128 to track it:
>
> >http://code.google.com/p/gwt-google-apis/issues/detail?id=128
>
> > You can open it and star it to be notified when its status changes.
> > Could you please fill out a Contributor License Agreement (CLA) at:http://code.google.com/webtoolkit/makinggwtbetter.htmlIfyouhave more
> > contributions, I would appreciate it if you could post a patch made
> > with'svn diff' or the equivalent using a subversion tool and send a
> > message to
> > the GWT contributors mailing list.
>
> > Regards,
> > -Eric.
>
> > On Sat, Jun 7, 2008 at 12:27 PM, jdc <jesse.cross...@gmail.com> wrote:
>
> > > Eric,
>
> > > the gwt-maps-0.0.29 jar i was referring to IS the GWT Google API's
> > > maps jar.
> > > the classes that i added mods to were from the svn version ofgwt-> > google-apis/maps code.

jdc

unread,
Jun 14, 2008, 4:54:44 PM6/14/08
to Google Web Toolkit
Quan,

i'm no longer using the r290 jar; it's far easier to build gwt-google-
apis from svn.
you'll need to install an svn client (i use tortoisesvn, found here
http://tortoisesvn.tigris.org/).

then checkout the source as shown here
http://code.google.com/p/gwt-google-apis/source/checkout

once you have the source checked out, you can apply the svn patch
found here
http://code.google.com/p/gwt-google-apis/issues/detail?id=128#c7
i *think* you just download the patch to your local machine, and (with
tortoisesvn)
right-click on the gwt-google-apis trunk folder and select Apply
Patch.
(i've never actually applied a patch; the issue 128 patch was the
first i ever created...
hence the multiple corrections).

then call "ant" in /gwt-google-apis/maps and the new maps jar will be
built
(you may need to fiddle with the GWT_HOME and other settings to get
the build to work correctly).

hope that helps,
jdc

Quan

unread,
Jun 14, 2008, 11:08:27 PM6/14/08
to Google Web Toolkit
jdc,

Thanks for the quick reply. I'm using subclipse to checkout in eclipse
and build using the Ant version that came with Eclipse as well.
However, I keep getting this error
BUILD FAILED
C:\Documents and Settings\Q\Desktop\maps\maps\build.xml:4: The
following error occurred while executing this line:
C:\Documents and Settings\Q\Desktop\maps\maps\common.ant.xml:121:
Cannot find 'C:\Documents and Settings\Q\Desktop\maps\tools' tools
directory; perhaps you should define the GWT_TOOLS environment
variable

Is this related to what you mentioned here:
> (you may need to fiddle with the GWT_HOME and other settings to get
> the build to work correctly).

This is my first time building a jar so this whole process seems
foreign to me. Obviously I need to set the GWT_TOOLS environment
variable, I know where to set this, I'm just not sure what value to
set it to and where I even find this 'tools directory'. It would be
nice if you can explain what these environment variables are and their
purposes. May be that will give me some clue to to take the next stop
and find the right answer from google.

Regards,

On Jun 14, 4:54 pm, jdc <jesse.cross...@gmail.com> wrote:
> Quan,
>
> i'm no longer using the r290 jar; it's far easier to buildgwt-google-apisfrom svn.
> you'll need to install an svn client (i use tortoisesvn, found herehttp://tortoisesvn.tigris.org/).
>
> then checkout the source as shown herehttp://code.google.com/p/gwt-google-apis/source/checkout
>
> once you have the source checked out, you can apply the svn patch
> found herehttp://code.google.com/p/gwt-google-apis/issues/detail?id=128#c7
> i *think* you just download the patch to your local machine, and (with
> tortoisesvn)
> right-click on thegwt-google-apistrunk folder and select Apply

jdc

unread,
Jun 14, 2008, 11:22:37 PM6/14/08
to Google Web Toolkit
what i discovered was that i also needed to check out and build the
gwt source as well.
if you check out the gwt trunk and tools directories (along with gwt-
google-apis) in a structure like this:

gwt
|-gwt-google-apis
|-gwt-trunk
\-tools

then you should be able to get gwt-google-apis built (after building
gwt-trunk, as well).

i would wager you could check out the tools directory and set the
GWT_TOOLS env var,
and then you'd need to set a GWT_HOME as well...and perhaps you could
just put jars in there
and build gwt-google-apis with them...but i'm not sure.

this is my first time using ant in years (i use maven for all of my
projects), so there's prolly a better way,
i just haven't bothered to find it.

good luck,
jdc

Quan

unread,
Jun 15, 2008, 3:23:49 PM6/15/08
to Google Web Toolkit
jdc,

Thanks again for your help, I think this is way over my head. I
checked out gwt/trunk and gwt/tools, set GWT_TOOLS and GWT_HOME env
var but new errors keep popping up. The current one I'm encounter
right now is

BUILD FAILED
C:\Documents and Settings\Q\Desktop\gwt\trunk\build.xml:53: The
following error occurred while executing this line:
C:\Documents and Settings\Q\Desktop\gwt\trunk\build.xml:47: The
following error occurred while executing this line:
C:\Documents and Settings\Q\Desktop\gwt\trunk\build-tools\build.xml:
24: The following error occurred while executing this line:
C:\Documents and Settings\Q\Desktop\gwt\trunk\build-tools\build.xml:
10: The following error occurred while executing this line:
C:\Documents and Settings\Q\Desktop\gwt\trunk\build-tools\ant-gwt
\build.xml:8: Unable to find a javac compiler;
com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
It is currently set to "C:\Program Files\Java\jre1.6.0_04"

I'm following the steps from this tutorial:
http://wiki.oreade.nl/Wiki.jsp?page=GwtSubversionDownloadCompile it
seems that they don't have this problem. Oh, well I guess I just have
to wait for the next gwt-api release, hope they're coming very very
soon. In the meantime, I prolly have to waste my time using JSNI to
wrap JS calls to the google map api.

Anyways, thanks for all your help.

Quan

unread,
Jun 15, 2008, 5:51:06 PM6/15/08
to Google Web Toolkit
jdc,

I gave it another try and actually got it to successfully build. The
problem I had was because the Ant that came with Eclipse uses the
default Eclipse JAVA_HOME path, which was set to the JRE path instead
of the JDK. After changing it, the build runs into another problem
which was described here: http://wiki.oreade.nl/Wiki.jsp?page=GwtSubversionDownloadCompile
Basically I just added import org.eclipse.swt.internal.gtk.LONG; to
this file: trunk\dev\linux\src\org\eclipse\swt\browser\Browser.java

Anyways, I can now call Google Earth from GWT (thanks alot to you).
For me, my next step is to test which existing function work with this
new MapType. Hopefully the gwt-api dev team is also working to
integrate these functions with Earth as well as adding new functions
unique to Earth (camera control, loading KML file, etc.) Would be
awesome to have these features in the next release.


On Jun 15, 3:23 pm, Quan <mquan...@gmail.com> wrote:
> jdc,
>
> > if you check out the gwt trunk and tools directories (along withgwt-> google-apis) in a structure like this:
>
> > gwt
> > |-gwt-google-apis
> > |-gwt-trunk
> > \-tools
>
> > then you should be able to getgwt-google-apisbuilt (after building
> > gwt-trunk, as well).
>
> > i would wager you could check out the tools directory and set the
> > GWT_TOOLS env var,
> > and then you'd need to set a GWT_HOME as well...and perhaps you could
> > just put jars in there
> > and buildgwt-google-apiswith them...but i'm not sure.

jdc

unread,
Jun 16, 2008, 1:39:15 AM6/16/08
to Google Web Toolkit
Quan,

congrats on a successful build! i always feel better when my changes
compile on others' machines.

i've been working on accessing Google Earth APIs from GWT as well and
have started an issue for that,
http://code.google.com/p/gwt-google-apis/issues/detail?id=133. i've
started working on Earth, the KmlObject hierarchy up to Overlays, and
all related Impl classes, but i haven't tested it all...in fact, i
believe my build is now failing in new and interesting ways...so i'll
post a patch once i have something worthwhile to use.

of most interest to me right now are the Earth instance,
GroundOverlays, and the Features list (i mostly want to see my WMS
images in Earth). i have dumped lists of properties and functions for
these objects (see below), but what's taken me the most time is
finding the right signatures for the functions, such as discovering
that createGroundOverlay() uses a String and then adjusting the Java
and JSNI calls accordingly. it helped quite a lot when i finally
followed step 4 and looked at the the Earth APIs (http://
code.google.com/apis/earth/documentation/API.html), especially those
for the GEPlugin...

let me know if you find anything good,
jdc


e a r t h o b j e c t

ALTITUDE_ABSOLUTE (number) = 2
ALTITUDE_CLAMP_TO_GROUND (number) = 0
ALTITUDE_RELATIVE_TO_GROUND (number) = 1
COLOR_INHERIT (number) = 2
COLOR_NORMAL (number) = 0

COLOR_RANDOM (number) = 1
EVENT_AT_TARGET_PHASE (number) = 2
EVENT_BUBBLING_PHASE (number) = 3
EVENT_CAPTURING_PHASE (number) = 1
LAYER_BORDERS (string) = 53004770-c7b3-11dc-92c2-dd553d8c9902
LAYER_BUILDINGS (string) = 4bbe65ea-e0aa-11dc-9f82-4dbccf810608

LAYER_ROADS (string) = 4ddec456-c7b3-11dc-aaa5-dd553d8c9902
LAYER_TERRAIN (string) = terrainUUID
MAP_TYPE_EARTH (number) = 1
MAP_TYPE_SKY (number) = 2
QueryInterface = [method]
REFRESH_ON_CHANGE (number) = 0

REFRESH_ON_EXPIRE (number) = 2
REFRESH_ON_INTERVAL (number) = 1
SPEED_TELEPORT (number) = 5
UNITS_FRACTION (number) = 1
UNITS_INSET_PIXELS (number) = 2
UNITS_PIXELS (number) = 0
VIEW_REFRESH_NEVER (number) = 0

VIEW_REFRESH_ON_REGION (number) = 3
VIEW_REFRESH_ON_REQUEST (number) = 1
VIEW_REFRESH_ON_STOP (number) = 2
VISIBILITY_AUTO (number) = 2
VISIBILITY_HIDE (number) = 0
VISIBILITY_SHOW (number) = 1
closeBalloon_ = [method]

createCamera = [method]
createCoord = [method]
createDocument = [method]
createElement = [method]
createFeatureBalloon = [method]
createFetchKmlHelper_ = [method]
createFolder = [method]
createGroundOverlay = [method]

createHtmlDivBalloon = [method]
createHtmlStringBalloon = [method]
createIcon = [method]
createLatLonAltBox = [method]
createLatLonBox = [method]
createLineString = [method]
createLinearRing = [method]

createLink = [method]
createLocation = [method]
createLod = [method]
createLookAt = [method]
createModel = [method]
createMultiGeometry = [method]
createNetworkLink = [method]
createOrientation = [method]

createPlacemark = [method]
createPoint = [method]
createPolygon = [method]
createRegion = [method]
createScale = [method]
createScreenOverlay = [method]
createStyle = [method]
createStyleMap = [method]

debugLogBridgeCalls_ = [method]
fetchKmlUsingHelper_ = [method]
getApiVersion = [method]
getBalloon = [method]
getBalloonState_ = [method]
getBridgeErrorCode_ = [method]
getBridgeErrorDetail_ = [method]

getDiv_ = [method]
getEarthVersion = [method]
getEventHandlersId = [method]
getFeatures = [method]
getGlobe = [method]
getJavascriptInitCode_ = [method]
getLayerRoot = [method]
getNavigationControl = [method]

getOptions = [method]
getPluginInstanceId_ = [method]
getPluginVersion = [method]
getRefCount_ = [method]
getRootObject = [method]
getSelf = [method]
getSun = [method]
getType = [method]
getView = [method]

getWindow = [method]
noOp_ = [method]
onBalloonchangenotify_EventEnabled = [method]
onBallooncloseEventEnabled = [method]
onBalloonmoved_EventEnabled = [method]
onDefaultfeatureclick_EventEnabled = [method]

onFrameendEventEnabled = [method]
onTermsofuseclick_EventEnabled = [method]
parseKml = [method]
setBalloon = [method]
setDiv_ = [method]
setEventsProxy_ = [method]
showFeatureBalloon_ = [method]
showGenericBalloon_ = [method]

start_ = [method]
testEarthInitialized_ = [method]

g r o u n d o v e r l a y
QueryInterface = [method]
getAbstractView = [method]
getAddress = [method]
getAltitude = [method]
getAltitudeMode = [method]
getBalloonText_ = [method]
getColor = [method]
getDescription = [method]
getDrawOrder = [method]
getEventHandlersId = [method]
getIcon = [method]
getId = [method]
getKml = [method]
getLatLonBox = [method]
getName = [method]
getNextSibling = [method]
getOpen = [method]
getOwnerDocument = [method]
getParentNode = [method]
getPluginInstanceId_ = [method]
getPreviousSibling = [method]
getRefCount_ = [method]
getRegion = [method]
getRemoteRefCount_ = [method]
getRetrievalCount_ = [method]
getRootObject = [method]
getSnippet = [method]
getStyleSelector = [method]
getStyleUrl = [method]
getType = [method]
getVisibility = [method]
onClickEventEnabled = [method]
onDblclickEventEnabled = [method]
onMousedownEventEnabled = [method]
onMousemoveEventEnabled = [method]
onMouseoutEventEnabled = [method]
onMouseoverEventEnabled = [method]
onMouseupEventEnabled = [method]
set = [method]
setAbstractView = [method]
setAddress = [method]
setAltitude = [method]
setAltitudeMode = [method]
setDescription = [method]
setDrawOrder = [method]
setIcon = [method]
setLatLonBox = [method]
setName = [method]
setOpen = [method]
setRegion = [method]
setSnippet = [method]
setStyleSelector = [method]
setStyleUrl = [method]
setVisibility = [method]

f e a t u r e s l i s t
QueryInterface = [method]
appendChild = [method]
getChildNodes = [method]
getDummy_feature_array__ = [method]
getEventHandlersId = [method]
getFirstChild = [method]
getLastChild = [method]
getPluginInstanceId_ = [method]
getRefCount_ = [method]
getRemoteRefCount_ = [method]
getRetrievalCount_ = [method]
getRootObject = [method]
getType = [method]
hasChildNodes = [method]
insertBefore = [method]
removeChild = [method]
replaceChild = [method]

Quan

unread,
Jun 17, 2008, 12:33:39 AM6/17/08
to Google Web Toolkit
Wow, looks like you are racing quite far ahead. Just wonder if those
new methods are committed to trunk yet? I'm only starting to get to
know the Earth API so it's been painfully slow for me. I know that in
order to expose new api functions in GWT I have to create JSNI
wrapper. Since you have implemented a bunch of them, I'm curious how
you go about implementing a method, say moving the camera by creating
LookAt object. I know that I gotta add the new method in MapWidget,
and then modifying Impl classes, but it's all seem blurry with
modifications at multiple places. Could you go over the process step
by step, some code snipet would also be helpful.

Thanks,

On Jun 16, 1:39 am, jdc <jesse.cross...@gmail.com> wrote:
> Quan,
>
> congrats on a successful build! i always feel better when my changes
> compile on others' machines.
>
> i've been working on accessing Google Earth APIs from GWT as well and
> have started an issue for that,http://code.google.com/p/gwt-google-apis/issues/detail?id=133. i've
> ...
>
> read more »

jesse crossley

unread,
Jun 17, 2008, 1:27:20 AM6/17/08
to Google-We...@googlegroups.com
none of my Earth work is committed (i don't have commit privileges just yet...i'm not a Google employee, so i'll likely hafta keep submitting patches and going through the contributor process). 

this isn't exactly step-by-step; it's more stream of consciousness, but maybe it'll give you the gist of things...

what i've been doing is copying the JSFlyweightWrapper pattern used extensively in gwt-maps.  for your LookAt example, what i would do is create all of the Kml*** and Kml***Impl objects needed in the object hierarchy from KmlLookAt down to KmlObject (see http://code.google.com/apis/earth/documentation/API.html#KmlLookAt, http://code.google.com/apis/earth/documentation/API.html#KmlAbstractView, and http://code.google.com/apis/earth/documentation/API.html#KmlObject...i punted on implementing GEEventEmitter...i really want events, but i've already bitten off significantly more than i can chew already).
since i've already impl'd KmlObject for other object hierarchies, i would start with KmlAbstractView.
the first step is making the KmlAbstractViewImpl interface (extends KmlObjectImpl, which extends JSFlyweightWrapper), thusly:

public interface KmlAbstractViewImpl extends KmlObjectImpl {
  KmlAbstractViewImpl impl = GWT.create(KmlAbstractViewImpl.class);
}
since the KmlAbstractView has no fields or methods of its own, the Impl has no methods, just an impl object created for completeness.  the KmlLookAtImpl interface is significantly more interesting, with accessors and mutators for latitude, longitude, range, tilt, heading, altitude, and altitudeMode, as well as an all-in-one set() method for setting all the properties at once.  notice the interface methods also take a JavaScriptObject argument, which is the actual Google Earth API LookAt JavaScriptObject these methods will be called on (that's the magic of the JSFlyweightWrapper stuff).  mutators are omitted for brevity below:

public interface KmlLookAtImpl extends KmlAbstractViewImpl {
  KmlLookAtImpl impl = GWT.create(KmlLookAtImpl.class);
  double getAltitude(JavaScriptObject jsoPeer);
  int/* KmlAltitudeModeEnum */getAltitudeMode(JavaScriptObject jsoPeer);
  double getHeading(JavaScriptObject jsoPeer);
  double getLatitude(JavaScriptObject jsoPeer);
  double getLongitude(JavaScriptObject jsoPeer);
  double getRange(JavaScriptObject jsoPeer);
  double getTilt(JavaScriptObject jsoPeer);
  void set(JavaScriptObject jsoPeer, double latitude, double longitude,
      double altitude, int/* KmlAltitudeModeEnum */altitudeMode, double heading,
      double tilt, double range);
}

you'll notice i'm using an int instead of properly wrapping the KmlAltitudeModeEnum...while gwt-maps does have examples of wrapping static constants and enums, the earth constants and enums are actually fields on the earth instance itself, so i'm not exactly sure how to expose 'em yet.

alright, on to the actual classes.  i'll include KmlAbstractView for completeness...i'm not sure if it's absolutely necessary to create a wrapper for all of the marker classes (tho i spose that even if public APIs aren't listed in the Earth API Reference, that there may be protected or private APIs which will need to be exposed later on), but i've been making 'em all day long, so one more won't hurt:

public class KmlAbstractView extends KmlObject {
  /**
   * Used to create a new KmlAbstractView by wrapping an existing js
   * KmlAbstractView object. This method is invoked by the jsio library.
   *
   * @param jsoPeer KmlAbstractView js object to wrap.
   * @return a new instance of KmlAbstractView.
   */
  @SuppressWarnings("unused")
  private static KmlAbstractView createPeer(JavaScriptObject jsoPeer) {
    return new KmlAbstractView(jsoPeer);
  }

  protected KmlAbstractView(final JavaScriptObject jsoPeer) {
    super(jsoPeer);
  }
}

this pattern of static createPeer()/protected or private constructor is more of the JSFlyweightWrapper magic.  i haven't needed to dig further into why it works cos so far it's just worked.
now, your final KmlLookAt class:

public class KmlLookAt extends KmlAbstractView {

  // **************************************************************************
  // static methods
  // **************************************************************************

  /**
   * Used to create a new KmlLookAt by wrapping an existing js KmlLookAt object.
   * This method is invoked by the jsio library.
   *
   * @param jsoPeer KmlLookAt js object to wrap.
   * @return a new instance of KmlLookAt.
   */
  @SuppressWarnings("unused")
  private static KmlLookAt createPeer(JavaScriptObject jsoPeer) {
    return new KmlLookAt(jsoPeer);
  }

  // **************************************************************************
  // constructors
  // **************************************************************************

  protected KmlLookAt(final JavaScriptObject jsoPeer) {
    super(jsoPeer);
  }

  public double getAltitude() {
    return KmlLookAtImpl.impl.getAltitude(jsoPeer);
  }

  public int/* KmlAltitudeModeEnum */getAltitudeMode() {
    return KmlLookAtImpl.impl.getAltitudeMode(jsoPeer);
  }

  public double getHeading() {
    return KmlLookAtImpl.impl.getHeading(jsoPeer);
  }

  public double getLatitude() {
    return KmlLookAtImpl.impl.getLatitude(jsoPeer);
  }

  public double getLongitude() {
    return KmlLookAtImpl.impl.getLongitude(jsoPeer);
  }

  public double getRange() {
    return KmlLookAtImpl.impl.getRange(jsoPeer);
  }

  public double getTilt() {
    return KmlLookAtImpl.impl.getTilt(jsoPeer);
  }

  public void set(double latitude, double longitude, double altitude,
      int/* KmlAltitudeModeEnum */altitudeMode, double heading, double tilt,
      double range) {
    KmlLookAtImpl.impl.set(jsoPeer, latitude, longitude, altitude,
        altitudeMode, heading, tilt, range);
  }
}

one last thing to do...now that KmlLookAt is implemented, it must be wired into the Earth and EarthImpl methods.  so the EarthImpl getLookAt method that i currently have as a placeholder:

JavaScriptObject createLookAt(JavaScriptObject jsoPeer);

becomes

KmlLookAt createLookAt(JavaScriptObject jsoPeer);

and then the Earth method changes its signature as well, so that it becomes:

public KmlLookAt createLookAt() {
    return EarthImpl.impl.createLookAt(jsoPeer);
  }

with all of that in place, you will then be able to call

mapWidget.getEarthInstance().createLookAt().set(...);

and that should have the desired look-at effect.  i've been building wrappers and impls all day, as i said, and i STILL can't get my WMS to render using the KmlGroundOverlay.  however, i do have a quite a pile of code that others might find useful, so i'd like to make an initial patch so others can take a look at this work and tell me if i'm on the right track or if i've gone as crazy as i feel.  i don't think that posting an incomplete patch on Issue 133 is appropriate, but i could email it out tomorrow if you're feeling adventurous.


all for now,
jdc

Eric Ayers

unread,
Jun 17, 2008, 6:18:48 AM6/17/08
to Google-We...@googlegroups.com, Miguel Méndez
This is a lot of work. I'm thinking that it would be best if we
created a new project that included all of the Google Earth bindings.

--

Miguel Méndez

unread,
Jun 17, 2008, 8:13:04 AM6/17/08
to Eric Ayers, jesse.c...@gmail.com, Google-We...@googlegroups.com
There is a lot of surface area to the GEarth API.  I'm not sure that integrating it as a first class citizen into the Maps API is the way to go.  It should really be its own set of bindings in gwt-google-apis (just like gears and maps are).  That way they can be released and updated independently.

How about I reach out to the GEarth API folks to see if someone on their team is available to provide feedback on your GWT bindings?  I think their feedback would be very valuable to this exercise.
--
Miguel

Quan

unread,
Jun 17, 2008, 10:27:28 AM6/17/08
to Google Web Toolkit
jdc,

I will need some time to digest what you wrote there, but yes I'm
definitely interested in testing out what you have now that I know how
to compile jar properly. There seems to be not a lot of overlaps b/w
the Map and Earth apis even though the Earth doc claims it to be. So
far, I have not found that to be the case as a lot of my map
implementations breaks when using with Earth, not sure if it's a gwt
or the Earth api problem.

Quan
On Jun 17, 1:27 am, "jesse crossley" <jesse.cross...@gmail.com> wrote:
> none of my Earth work is committed (i don't have commit privileges just
> yet...i'm not a Google employee, so i'll likely hafta keep submitting
> patches and going through the contributor process).
>
> this isn't exactly step-by-step; it's more stream of consciousness, but
> maybe it'll give you the gist of things...
>
> what i've been doing is copying the JSFlyweightWrapper pattern used
> extensively in gwt-maps. for your LookAt example, what i would do is create
> all of the Kml*** and Kml***Impl objects needed in the object hierarchy from
> KmlLookAt down to KmlObject (seehttp://code.google.com/apis/earth/documentation/API.html#KmlLookAt,http://code.google.com/apis/earth/documentation/API.html#KmlAbstractView,
> andhttp://code.google.com/apis/earth/documentation/API.html#KmlObject......
> on implementing GEEventEmitter...i really want events, but i've
> already bitten off significantly more than i can chew already).
> since i've already impl'd KmlObject for other object hierarchies, i would
> start with KmlAbstractView.
> the first step is making the KmlAbstractViewImpl interface (extends
> KmlObjectImpl, which extends JSFlyweightWrapper), thusly:
>
> public interface KmlAbstractViewImpl extends KmlObjectImpl {
> KmlAbstractViewImpl impl = GWT.create(KmlAbstractViewImpl.class);}
>
> since the KmlAbstractView has no fields or methods of its own, the Impl has
> no methods, just an *impl* object created for completeness. the
> ...
>
> read more »

jesse crossley

unread,
Jun 17, 2008, 12:00:13 PM6/17/08
to Miguel Méndez, Eric Ayers, Google-We...@googlegroups.com
Miguel, Eric,

thus far i have developed all of the Earth wrappers in separate packages from the gwt-maps classes (com.google.gwt.maps.client.earth and com.google.gwt.maps.client.earth.impl), so placing them in a separate project should be fairly simple.  the maps and earth APIs are also so different that separate projects seem quite appropriate. 

there is the small matter of the maps-earth integration...in order to enable the GE plugin from GoogleMaps, the gwt-maps project will have a dependency on the (pending) gwt-earth project.  right now, the gwt-earth bindings are following the gwt-maps JSFlyweightWrapper pattern, and this introduces a circular dependency (gwt-maps depends on gwt-earth depends on gwt-maps).  so the binding architecture may need to be factored out of gwt-maps as well, but we can address that later.

oh, and absolutely!, i could use some feedback on my current bindings.  i've been happily tinkering on all of this hoping that the dif't Google teams would weigh in sooner or later.

incidentally, last night i succeeded in getting my imagery into the GE plugin.  turns out the problem was that the KmlGroundOverlay's KmlIcon's href could not contain unencoded pipe characters ("|") and all i needed was to replace 'em with "%7b".  it's somewhat unfortunate that i needed to hack it like that (the Google Maps API's Overlays have no problem with pipe characters) but since this is serious demoware at the moment, i can let it slide for a bit.

pictures > 1000 words
http://www.flickr.com/photos/bedtime/2586860535/sizes/l/
http://www.flickr.com/photos/bedtime/2587694724/sizes/o/
http://www.flickr.com/photos/bedtime/2586859573/sizes/o/

Miguel Méndez

unread,
Jun 17, 2008, 4:40:24 PM6/17/08
to Google-We...@googlegroups.com, Eric Ayers
On Tue, Jun 17, 2008 at 12:00 PM, jesse crossley <jesse.c...@gmail.com> wrote:
Miguel, Eric,

thus far i have developed all of the Earth wrappers in separate packages from the gwt-maps classes (com.google.gwt.maps.client.earth and com.google.gwt.maps.client.earth.impl), so placing them in a separate project should be fairly simple.  the maps and earth APIs are also so different that separate projects seem quite appropriate. 

Sounds good.
 

there is the small matter of the maps-earth integration...in order to enable the GE plugin from GoogleMaps, the gwt-maps project will have a dependency on the (pending) gwt-earth project.  right now, the gwt-earth bindings are following the gwt-maps JSFlyweightWrapper pattern, and this introduces a circular dependency (gwt-maps depends on gwt-earth depends on gwt-maps).  so the binding architecture may need to be factored out of gwt-maps as well, but we can address that later.

If the earth stuff could use overlay types, then we could use that to break the cycle.
 

oh, and absolutely!, i could use some feedback on my current bindings.  i've been happily tinkering on all of this hoping that the dif't Google teams would weigh in sooner or later.

I'll reach out to the earth team to see if we can get some of their eyes on it.
 

incidentally, last night i succeeded in getting my imagery into the GE plugin.  turns out the problem was that the KmlGroundOverlay's KmlIcon's href could not contain unencoded pipe characters ("|") and all i needed was to replace 'em with "%7b".  it's somewhat unfortunate that i needed to hack it like that (the Google Maps API's Overlays have no problem with pipe characters) but since this is serious demoware at the moment, i can let it slide for a bit.

pictures > 1000 words
http://www.flickr.com/photos/bedtime/2586860535/sizes/l/
http://www.flickr.com/photos/bedtime/2587694724/sizes/o/
http://www.flickr.com/photos/bedtime/2586859573/sizes/o/
Nice pics!

-- 
Miguel
Reply all
Reply to author
Forward
0 new messages