did you forget to inherit a required module

did you forget to inherit a required module?
[ERROR] Line 38: No source code is available for type com.hqh.test.image.Icons; did you forget to inherit a required module?

在Gwt中用RPC传递个自定义类型的,竟然老报错!!!搞了N久才发现错哪啦,还是在一个网站上看到一个老外的回复才恍然大悟!
did you forget to inherit a required module

Hi,

In my application I wrote one utility class DateHelper.java which will be used for parsing the date,etc..etc.. this DateHelper.java is in the package of web.utility. My entry point classes
in web.client package. so When I tried to call this DateHelper.java in the entry point class,
It is giving error like Line 531: No source code is available for type web.utils.DateHelper; did you forget to inherit a required module?. cant we write any utility methods like this?

thanks



You can't use classes from other packages than client on the client side code. You can put it in web.client.utils.DateHelper.

看到这,想起把class放client下面试试,结果还真解决了问题!!!