What is the difference between gwt-user.jar and gwt-dev.jar? Looking at their contents, I cannot see why they are packaged as they are.
I am wondering especially how to use the two JARs for compilation and deployment.
Which of the two do I need ...
javac
(.java to .class)?Any clarification on these uses or, even better, an explanation of why that is, would be greatly appreciated.
Officially, support is dropped for running the GWT compiler or server-side tooling on Java 7. The GWT distribution is still compiled to run on Java 7 for this release, but no guarantees are made about whether or not this will work. Future versions will compile bytecode for Java 8+.
The latest GWT release is 2.9. 0.
Language support. GWT supports most of the core Java language syntax and semantics, but there are a few differences you will want to be aware of. GWT 2.8+ supports Java 8 syntax.
gwt-user.jar contains the GWT api which you will interface directly with.
gwt-dev.jar contains code for gwt compiler, development/hosted mode etc.
for running javac (.java to .class)?
I assume you just mean to resolve references in which case gwt-user.jar
for running the GWT compiler (.class to JavaScript)?
gwt-dev.jar as well as gwt-user.jar for dependency resolution
for running GWT development mode and debugging?
again gwt-dev.jar contains everything to actually run development mode, but your code will be making use of gwt-user.jar here as well
for deploying my app to Google App Engine?
this is handled by the Google Eclipse Plugin and neither of these jars. If you are doing this via some other method though you should have no need for deploying either of these jar files to App Engine
to have in my Eclipse project's classpath?
your eclipse project should just need gwt-user.jar
One jar you have not mentioned is the gwt-servlet.jar if you are planning to do any server side communication you will also need this as a project dependency in your eclipse project.
Making use of the GWT Eclipse plugin will take care of a lot of these dependencies for you.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With