开发者

Getting a GWT application to communicate with a local client process

I'm actually not too sure what I'm looking for can be done but I'd love to hear otherwise.

Currently I have a GWT application which communicates with a Java server via GWT-RPC; This GWT application is in many ways a desktop application as I have a wrapper which loads the web application and the users interact with this web-control. My needs have changed significantly and now I need to separate the application to two separate parts:

1) The UI

2) The communication with the server which needs to change to working with a local client process which will do the actual communication and will hand the application whatever it needs when updates arrive.

The main lead I was thinking of, and I don't know if it's applicable, is to have the other client process mimick (in some way which I need to think of) a server and then have the appli开发者_StackOverflow社区cation talk with it, via XML/JSONP, while the process talks with the server in some way (not important for now).

If this does not make sense please ask and I'll try to clarify.

I'd appreciate any suggestions,

Ittai


You (probably) can't communicate in a cross-platform (and cross-browser) way from a web client to a local process, in any other way than you could with a web service.

In other words, I think your main idea is the way to go - set up a local HTTP server that will serve the client, and then have that process also communicate with whatever remote services you may need. Perhaps you can find a lightweight Java-based HTTP server that can run your local process with GWT-RPC code inside it to minimize the changes to your current code.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜