HardwareService
in package
Provides service to store user meta
Tags
Table of Contents
Properties
- $linux : mixed
Methods
- __construct() : mixed
- This method initializes the `User` object, retrieves the user's information, and ensures the user is valid.
- getAll() : array<string|int, mixed>
- getCPUTemperature() : mixed
- getHWVersion() : mixed
- getMemoryUsage() : array<string|int, mixed>
- getOSVersion() : mixed
- getPerCoreCPULoad() : array<string|int, mixed>
- readCpuStats() : array<string|int, mixed>
- convertKb() : string
Properties
$linux
protected
mixed
$linux
Methods
__construct()
This method initializes the `User` object, retrieves the user's information, and ensures the user is valid.
public
__construct() : mixed
If the user is not valid, the process is halted with an error message.
It also initializes the appropriate user_meta
Tags
getAll()
public
getAll() : array<string|int, mixed>
Return values
array<string|int, mixed>getCPUTemperature()
public
getCPUTemperature() : mixed
getHWVersion()
public
getHWVersion() : mixed
getMemoryUsage()
public
getMemoryUsage() : array<string|int, mixed>
Return values
array<string|int, mixed>getOSVersion()
public
getOSVersion() : mixed
getPerCoreCPULoad()
public
getPerCoreCPULoad([float $interval = 1.0 ]) : array<string|int, mixed>
Parameters
- $interval : float = 1.0
Return values
array<string|int, mixed>readCpuStats()
public
readCpuStats() : array<string|int, mixed>
Return values
array<string|int, mixed>convertKb()
private
convertKb(int $size) : string
Parameters
- $size : int