Removal of the ../client/.. package?

19 views
Skip to first unread message

Daniel Wirtz

unread,
Jan 25, 2013, 12:48:37 PM1/25/13
to gwtex...@googlegroups.com
Hello everyone,

I just found out about gwtexporter and it turns out to be exactly the tool that I need. So I have been playing around with it a bit, having the following project:

src/App.gwt.xml
<module>
    <inherits name="com.google.gwt.user.User"/>
    <inherits name='org.timepedia.exporter.Exporter'/>
    <set-property name="export" value="yes"/>
    <source path="com/something" />
    <entry-point class="com.something.MainEntryPoint"/>
</module>
src/com/something/MainEntryPoint.java
src/com/something/client/MyClass.java (set to be exported, just @Export and implements Exportable)

JavaScript Result:
var myObj = new com.something.MyClass(); // without the "client" package

Of course I could manually @ExportPackage("com.something.client.MyClass") which will work, but I'd like to prevent adding this to each class. I also tried to change the paths of the App.gwt.xml and the MainEntryPoint but this also didn't change anything. I tried with 2.5.0-SNAPSHOT on Maven and adding it locally from the downloads section). So I assume that I've missed an essential point here. My question therefore is: Why is the "client" package removed and can this behaviour be prevented e.g. by a configuration option?

Cheers and thanks in advance,
Daniel

Manuel Carrasco Moñino

unread,
Feb 15, 2013, 3:42:36 AM2/15/13
to gwtex...@googlegroups.com
Yes the client part is removed (see JExportableClassType line #217). 
It is just a convention since most gwt apps have this in their namespace. There is no way to disable it. If you consider that this should be removed just fill an issue.



--
 
 

Reply all
Reply to author
Forward
0 new messages