开发者

http error codes in gwt rpc

I am working with a web application which uses gwt, spring, hibernate. And I am using gwtrpcspring RemoteServiceDispatcher for remote service mapping. Currently if my application throws MyException from any method I want catch that and have to send some http error codes like 402. Based on the ex开发者_如何学Pythonception type error codes will change. I am planning to do this at generic level. Is there any way to achieve without help of spring AOP?

How to achieve this in gwt rpc/spring at higher level?


A good generic way of approaching this problem is to define/subclass your "MyException" class, that represents the different error states. Using RPC those can be sent to the client where you can do your processing.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜