How to get a list of current open windows/process with Java?

后端 未结 14 1339
抹茶落季
抹茶落季 2020-11-22 05:20

Does any one know how do I get the current open windows or process of a local machine using Java?

What I\'m trying to do is: list the current open task, windows or

14条回答
  •  情深已故
    2020-11-22 05:33

    There is no platform-neutral way of doing this. In the 1.6 release of Java, a "Desktop" class was added the allows portable ways of browsing, editing, mailing, opening, and printing URI's. It is possible this class may someday be extended to support processes, but I doubt it.

    If you are only curious in Java processes, you can use the java.lang.management api for getting thread/memory information on the JVM.

提交回复
热议问题