📅  最后修改于: 2020-11-15 03:03:57             🧑  作者: Mango
java.lang.ProcessBuilder类用于创建操作系统进程。此类未同步。
以下是java.lang.ProcessBuilder类的声明-
public final class ProcessBuilder
extends Object
Sr.No. | Constructor & Description |
---|---|
1 |
ProcessBuilder(List This constructs a process builder with the specified operating system program and arguments. |
2 |
ProcessBuilder(String… command) This constructs a process builder with the specified operating system program and arguments. |
Sr.No. | Method & Description |
---|---|
1 | List This method returns this process builder’s operating system program and arguments. |
2 | ProcessBuilder command(List This method sets this process builder’s operating system program and arguments. |
3 | ProcessBuilder command(String… command)
This method sets this process builder’s operating system program and arguments. |
4 | File directory()
This method returns this process builder’s working directory. |
5 | ProcessBuilder directory(File directory)
This method sets this process builder’s working directory. |
6 | Map This method returns a string map view of this process builder’s environment. |
7 | boolean redirectErrorStream()
This method tells whether this process builder merges standard error and standard output. |
8 | ProcessBuilder redirectErrorStream(boolean redirectErrorStream)
This method sets this process builder’s redirectErrorStream property. |
9 | Process start()
This method starts a new process using the attributes of this process builder. |
此类从以下类继承方法-