* 2) each external class used in the app must be explicitly entered with
the "inherits" tag in the App.gwt.xml file.
*
That is incorrect.

If you want to use external classes, this is what you have to do -

   1. Create a jar file containing both java source files and the
   corresponding classes. GWTC needs the *.java files, while Eclipse would need
   the *.class files.
   Typical structure of your jar file is -
   com
   ------ntm
   -------------correction
   ----------------------------Correction.gwt.xml
   ----------------------------client
   ----------------------------------------<Java Source files and Class
   Files>
   2. You need to create a gwt.xml file for your module. It need not have a
   Entry point class, but all other things remain same.
   3. Then, in your second module, you put an inherits tag and specify the
   module name, not the class name. In this case, you will specifiy
   com.ntm.correction.Correction - because that is where you have the .gwt.xml
   file


--Sri


2009/9/21 thc <[email protected]>

>
> Hi, I am having difficulty trying to compile to javascript ("ant
> build" - web mode)  my GWT app with externally-include jar files (that
> is, non google, non gwt jar files).
>
> My understanding of the process for these jar files is that:
>
> 1) you ensure they are on your classpath (in my case, my eclipse build
> path since I use eclipse for IDE).
> 2) each external class used in the app must be explicitly entered with
> the "inherits" tag in the App.gwt.xml file.
>
> However, I get the following error for any external class I capture in
> the inherits tag in the gwt.xml file:
>
>     [java]    Loading inherited module 'ntm.Correction'
>     [java]       [ERROR] Unable to find 'ntm/Correction/gwt.xml' on
> your classpath; could be a typo, or maybe you forgot to include a
> classpath entry for source?
>
>     [java]    [ERROR] Line 15: Unexpected exception while processing
> element 'inherits'
>     [java] com.google.gwt.core.ext.UnableToCompleteException: (see
> previous log entries)
>
> etc..
>
> Here is the actual entire gwt.xml file:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit .7.0//
> EN" "http://google-web-toolkit.googlecode.com/svn/tags/1.7.0/distro-
> source/core/src/gwt-module.dtd<http://google-web-toolkit.googlecode.com/svn/tags/1.7.0/distro-%0Asource/core/src/gwt-module.dtd>
> ">
> <module rename-to='ntmapp'>
>  <!-- Inherit the core Web Toolkit stuff.                        -->
>  <inherits name='com.google.gwt.user.User'/>
>
>  <!-- Inherit the default GWT style sheet.  You can change       -->
>  <!-- the theme of your GWT application by uncommenting          -->
>  <!-- any one of the following lines.                            -->
>  <inherits name='com.google.gwt.user.theme.standard.Standard'/>
>  <!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/> -->
>  <!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/>     -->
>
>  <!-- Other module inherits                                      -->
> <inherits name='ntm.Correction'/>
>        <!-- Specify the app entry point class.                         -->
>  <entry-point class='ntm.google.client.NTMApp'/>
> </module>
>
>
> Furthermore, it makes no difference which required external class I
> put there, the error also has the same ambiguous format. In other
> words, I can include anything as:
>
> <inherits name='foo.Bar'/>
>
> , and the error is always the same, and dependably:
>
>     [java]    Loading inherited module 'foo.Bar'
>     [java]       [ERROR] Unable to find 'foo/Bar/gwt.xml' on your
> classpath; could be a typo, or maybe you forgot to include a classpath
> entry for source?
>
>     [java]    [ERROR] Line 15: Unexpected exception while processing
> element 'inherits'
>     [java] com.google.gwt.core.ext.UnableToCompleteException: (see
> previous log entries)
>
> etc..
>
> I do not understand how to interpret this message nor how to correct
> and would be grateful for any insights. Thanks
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to