File manager - Edit - /home/ferretapmx/public_html/administrator/components/com_akeebabackup/src/CliCommands/MixIt/MemoryInfo.php
Back
<?php /** * @package akeebabackup * @copyright Copyright 2006-2026 Nicholas K. Dionysopoulos / Akeeba Ltd * @license GNU General Public License version 3, or later */ namespace Akeeba\Component\AkeebaBackup\Administrator\CliCommands\MixIt; defined('_JEXEC') || die; /** * Utility methods to get memory information * * @since 7.5.0 */ trait MemoryInfo { /** * Returns the current memory usage * * @return string * * @since 7.5.0 */ private function memUsage(): string { if (function_exists('memory_get_usage')) { $size = memory_get_usage(); $unit = ['b', 'KB', 'MB', 'GB', 'TB', 'PB']; return @round($size / 1024 ** ($i = floor(log($size, 1024))), 2) . ' ' . $unit[$i]; } else { return "(unknown)"; } } /** * Returns the peak memory usage * * @return string * * @since 7.5.0 */ private function peakMemUsage(): string { if (function_exists('memory_get_peak_usage')) { $size = memory_get_peak_usage(); $unit = ['b', 'KB', 'MB', 'GB', 'TB', 'PB']; return @round($size / 1024 ** ($i = floor(log($size, 1024))), 2) . ' ' . $unit[$i]; } else { return "(unknown)"; } } }
| ver. 1.4 |
Github
|
.
| PHP 8.2.32 | Generation time: 0.06 |
proxy
|
phpinfo
|
Settings