API reference / @jsprismarine/prismarine / stats/StatsPlatform
stats/StatsPlatform
Interfaces
StatsPlatform
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:7
The host the server runs on, as node:os describes it, the same for every provider. A provider that needs another form maps these fields itself.
Properties
arch
readonlyarch:string
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:15
The CPU architecture, from os.arch(), such as x64.
coreCount
readonlycoreCount:number
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:17
The CPUs the process may use, from os.availableParallelism().
memoryGb
readonlymemoryGb:number
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:19
The host's memory from os.totalmem(), rounded to whole gigabytes (1024³ bytes).
release
readonlyrelease:string
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:11
The kernel release, from os.release(), such as 6.1.0 or 23.5.0.
type
readonlytype:string
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:9
The operating system name, from os.type(), such as Linux, Darwin or Windows_NT.
version
readonlyversion:string
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:13
The kernel or product version, from os.version(), such as Windows 11 Pro.
Functions
readPlatform()
readPlatform():
StatsPlatform
Defined in: packages/prismarine/src/stats/StatsPlatform.ts:28
Reads the host description from node:os.
Returns
The current platform fields.