At the moment, this library only contains classes, which were in the project's "client" folder.But I also want to move classes from the "shared" folder into this library.
- Where do I have to move the shared classes within my library and how do these folders have to be declared in the gwt.xml file?
Anywhere you want as long you make them visible to the GWT compiler using <source path="..." /> in your GWT module. So for example you could just copy the source to your library project and add an additional <source path="shared" /> to your GWT module.
- How does it work, using a shared folder for both client and server side code?
Does the same code be compiled twice, once by a traditional java compiler and once by the GWT compiler?
What's the mechanism behind this "shared" folder concept?
GWT itself does not have a concept of "shared" folders. The only thing GWT cares about are source files made available to the GWT compiler using <source path="..." />. It happens that people often create a package named "shared" to express that classes in that package work on server side as well as on client side.
-- J.
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment