BT.system
BT.system
Function
returns lightweight system fields. This method only reads the compilation target and the number of available parallel threads, and does not scan hardware, disks, network interfaces, or host information.
Syntax
BT.system()
Parameters
| Parameters | Type | Required | Default value | Description |
|---|---|---|---|---|
| None | - | No | None | No parameters required. |
Return Value
| Type | Description |
|---|---|
| Object | Returns a lightweight system information object. See "Return Object Fields" below for fields. |
Return object field
| Field | Type | Must exist | Description |
|---|---|---|---|
| os | String | Yes | Current target operating system name, such as windows, linux, macos. |
| arch | String | Yes | Current CPU architecture name, such as x86_64, aarch64. |
| family | String | Yes | The current operating system family, such as windows, unix, wasm. |
| threads | Int | Yes | Number of parallel threads available in the current system. 1 is returned when the read fails. |
Examples
system = BT.system() result = system.os // Output: windows print result
Notes
- BT.system() does not scan CPU details, memory, disk, network card, or hostname.