diff options
author | Simon Rettberg | 2023-11-14 14:47:55 +0100 |
---|---|---|
committer | Simon Rettberg | 2023-11-14 14:47:55 +0100 |
commit | 06bff0b9b84d47c43f9bc8aff06a29d85ebb7ed0 (patch) | |
tree | 7e5493b102074672d8cfd8fe1a61e49f080edbe8 /modules-available/vmstore/inc | |
parent | Update phpstorm config (diff) | |
download | slx-admin-06bff0b9b84d47c43f9bc8aff06a29d85ebb7ed0.tar.gz slx-admin-06bff0b9b84d47c43f9bc8aff06a29d85ebb7ed0.tar.xz slx-admin-06bff0b9b84d47c43f9bc8aff06a29d85ebb7ed0.zip |
Add function param/return types, fix a lot more phpstorm complaints
Diffstat (limited to 'modules-available/vmstore/inc')
-rw-r--r-- | modules-available/vmstore/inc/vmstorebenchmark.inc.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/modules-available/vmstore/inc/vmstorebenchmark.inc.php b/modules-available/vmstore/inc/vmstorebenchmark.inc.php index b13f4e37..b819ef8a 100644 --- a/modules-available/vmstore/inc/vmstorebenchmark.inc.php +++ b/modules-available/vmstore/inc/vmstorebenchmark.inc.php @@ -24,13 +24,12 @@ class VmStoreBenchmark } /** - * @param array $machineUuids * @param string $image relative path/name of image * @param string $serverOrMode IP address of DNBD3 server, OR 'auto' for all servers known to client, or 'nfs' for NFS * @param int $start timestamp when the clients should start * @return ?string taskId, or null on error */ - public static function start(string $id, array $machineUuids, string $image, string $serverOrMode, int &$start) + public static function start(string $id, array $machineUuids, string $image, string $serverOrMode, int &$start): ?string { Module::isAvailable('rebootcontrol'); $clients = Database::queryAll('SELECT machineuuid, clientip FROM machine WHERE machineuuid IN (:uuids)', @@ -68,6 +67,9 @@ COMMAND; return $task['id'] ?? null; } + /** + * @return array{cpu: array, net: array} + */ public static function parseBenchLine(string $line): array { $out = ['cpu' => [], 'net' => []]; |