开发者

How to create multiple processes in Adobe Air program?

How to create multiple processes in Adobe Air program? Docs? Tuts? Algorithms? (for ex I have some design logic and some services client logic i want to ru开发者_Python百科n them in separate processes) (Air 2.0 is ok for me)


You said that you can use AIR 2.0, in this case you can write a client AIR app with all the GUI and a server app, also written in AIR (if you want you can change language), that contains the logic. Using AIR 2.0 you have the ability to run new process. When the GUI starts it runs the server and then they can communicate using HTTP in the same machine. You can also invert the boot order running the server first and then running the GUI. Here you can find a guide to use NativeProcess in AIR 2.0


If you are looking for multi-threading in AIR, sorry to be the bearer of bad news, but there is no support for threads in AIR. If you must use threading, you can connect your AIR app with java using air-java-bridge and exploit java's threading.


Another possibility is to implement green threads yourself. However you will never get any benifit from a multicore architecture.


I think you can kick off multiple threads with merapi, but then you have to fight with installation architecture etc...

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜