官术网_书友最值得收藏!

Process handling API

In prior versions of Java, developers interacting with native operating system processes had to use a fairly limited API, with some operations requiring resorting to native code. As part of Java Enhancement Proposal (JEP) 102, the Java process API was extended with the following features (quoting from the JEP text):

  • The ability to get the pid (or equivalent) of the current Java virtual machine and the pid of processes created with the existing API.
  • The ability to enumerate processes on the system. Information on each process may include its pid, name, state, and perhaps resource usage.
  • The ability to deal with process trees; in particular, some means to destroy a process tree.
  • The ability to deal with hundreds of subprocesses, perhaps multiplexing the output or error streams to avoid creating a thread per subprocess.

We will explore these API changes in our first project, the Process Viewer/Manager (see the following sections for details).

主站蜘蛛池模板: 东辽县| 佳木斯市| 泰顺县| 杭州市| 南溪县| 镇宁| 屏南县| 普格县| 静安区| 焦作市| 大理市| 顺平县| 新密市| 大竹县| 饶平县| 怀柔区| 大新县| 时尚| 磐石市| 东宁县| 双城市| 额尔古纳市| 南靖县| 鄄城县| 宿州市| 迁西县| 乐平市| 凉城县| 裕民县| 眉山市| 广饶县| 丰原市| 墨竹工卡县| 会同县| 舒城县| 淳化县| 菏泽市| 天津市| 登封市| 麦盖提县| 保靖县|