System
| Module | ejs.sys |
| Namespace | "ejs.sys" |
| Definition | class System |
| Specified | Ejs-11. |
| Inheritance | System Object |
System is a utility class providing methods to interact with the operating system.
Properties
| Qualifiers | Property | Type | Description |
|---|---|---|---|
| public static const | Bufsize | Number |
System Methods
| Qualifiers | Method |
|---|---|
| public static get | hostname(fullyQualified: Boolean): String |
| Get the system hostname. | |
| public static | run(cmd: String): String |
| Execute a command/program using the default operating system shell. | |
| public static | runx(cmd: String): Void |
Method Detail
Get the system hostname.
- Parameters
fullyQualified: Boolean If true, return a hostname including a domain portion [default: true]
- Returns
- A host name string.
Execute a command/program using the default operating system shell.
- Parameters
- Returns
- A text stream connected to the programs standard output.
Throws
IOError: if the command exits with non-zero status.