I realize that GWt doesn't compile the classes not in the Client package. But what is the importance of the shared package? What are the classes that I need to put in this package?
The contents of the . gwt. xml file specify the precise list of Java classes and other resources that are included in the GWT module. For all the details on how to create a GWT Module, consult the Modules Fundamentals page.
These are all files referenced by your GWT module, such as Host HTML page, CSS or images. The location of these resources can be configured using <public path = "path" /> element in module configuration file. By default, it is the public subdirectory underneath where the Module XML File is stored.
GWT contains a number of HTTP client classes that simplify making custom HTTP requests to your server and optionally processing a JSON- or XML-formatted response. GWT contains a set of HTTP client classes that allow your application to make generic HTTP requests.
What are the classes that I need to put in this package?
Any logic or data types that are used by both the client and the server. This will save you from duplicating code across both sides, and potentially keep the logic and data types consistent.
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