diff options
| author | Andrew Dolgov <fox@fakecake.org> | 2024-12-10 05:22:37 +0000 |
|---|---|---|
| committer | Andrew Dolgov <fox@fakecake.org> | 2024-12-10 05:22:37 +0000 |
| commit | 0ef2dd7175248e1116a867e0a86579d9f6ca16eb (patch) | |
| tree | 452fc6e3391544b209ea075d587935e7ab42e714 /vendor/thecodingmachine/safe/generated/rrd.php | |
| parent | f15db7b9610467aa29f6441361fdc4e6c90deaa1 (diff) | |
| parent | 3860435cba19cf2cd9c86dcc5d8938198c6b6736 (diff) | |
Merge branch 'feature/alpine_3.21-and-php_8.4' into 'master'
Bump to Alpine 3.21 and PHP 8.4, raise the minimum to PHP 8.2
See merge request tt-rss/tt-rss!85
Diffstat (limited to 'vendor/thecodingmachine/safe/generated/rrd.php')
| -rw-r--r-- | vendor/thecodingmachine/safe/generated/rrd.php | 190 |
1 files changed, 0 insertions, 190 deletions
diff --git a/vendor/thecodingmachine/safe/generated/rrd.php b/vendor/thecodingmachine/safe/generated/rrd.php deleted file mode 100644 index 2da227d0e..000000000 --- a/vendor/thecodingmachine/safe/generated/rrd.php +++ /dev/null @@ -1,190 +0,0 @@ -<?php - -namespace Safe; - -use Safe\Exceptions\RrdException; - -/** - * Creates the rdd database file. - * - * @param string $filename Filename for newly created rrd file. - * @param array $options Options for rrd create - list of strings. See man page of rrd create - * for whole list of options. - * @throws RrdException - * - */ -function rrd_create(string $filename, array $options): void -{ - error_clear_last(); - $result = \rrd_create($filename, $options); - if ($result === false) { - throw RrdException::createFromPhpError(); - } -} - - -/** - * Returns the first data sample from the specified RRA of the RRD file. - * - * @param string $file RRD database file name. - * @param int $raaindex The index number of the RRA that is to be examined. Default value is 0. - * @return int Integer number of unix timestamp. - * @throws RrdException - * - */ -function rrd_first(string $file, int $raaindex = 0): int -{ - error_clear_last(); - $result = \rrd_first($file, $raaindex); - if ($result === false) { - throw RrdException::createFromPhpError(); - } - return $result; -} - - -/** - * Creates image for a particular data from RRD file. - * - * @param string $filename The filename to output the graph to. This will generally end in either - * .png, .svg or - * .eps, depending on the format you want to output. - * @param array $options Options for generating image. See man page of rrd graph for all - * possible options. All options (data definitions, variable definitions, etc.) - * are allowed. - * @return array Array with information about generated image is returned. - * @throws RrdException - * - */ -function rrd_graph(string $filename, array $options): array -{ - error_clear_last(); - $result = \rrd_graph($filename, $options); - if ($result === false) { - throw RrdException::createFromPhpError(); - } - return $result; -} - - -/** - * Returns information about particular RRD database file. - * - * @param string $filename RRD database file name. - * @return array Array with information about requested RRD file. - * @throws RrdException - * - */ -function rrd_info(string $filename): array -{ - error_clear_last(); - $result = \rrd_info($filename); - if ($result === false) { - throw RrdException::createFromPhpError(); - } - return $result; -} - - -/** - * Gets array of the UNIX timestamp and the values stored for each date in the - * most recent update of the RRD database file. - * - * @param string $filename RRD database file name. - * @return array Array of information about last update. - * @throws RrdException - * - */ -function rrd_lastupdate(string $filename): array -{ - error_clear_last(); - $result = \rrd_lastupdate($filename); - if ($result === false) { - throw RrdException::createFromPhpError(); - } - return $result; -} - - -/** - * Restores the RRD file from the XML dump. - * - * @param string $xml_file XML filename with the dump of the original RRD database file. - * @param string $rrd_file Restored RRD database file name. - * @param array $options Array of options for restoring. See man page for rrd restore. - * @throws RrdException - * - */ -function rrd_restore(string $xml_file, string $rrd_file, array $options = null): void -{ - error_clear_last(); - if ($options !== null) { - $result = \rrd_restore($xml_file, $rrd_file, $options); - } else { - $result = \rrd_restore($xml_file, $rrd_file); - } - if ($result === false) { - throw RrdException::createFromPhpError(); - } -} - - -/** - * Change some options in the RRD dabase header file. E.g. renames the source for - * the data etc. - * - * @param string $filename RRD database file name. - * @param array $options Options with RRD database file properties which will be changed. See - * rrd tune man page for details. - * @throws RrdException - * - */ -function rrd_tune(string $filename, array $options): void -{ - error_clear_last(); - $result = \rrd_tune($filename, $options); - if ($result === false) { - throw RrdException::createFromPhpError(); - } -} - - -/** - * Updates the RRD database file. The input data is time interpolated according to the - * properties of the RRD database file. - * - * @param string $filename RRD database file name. This database will be updated. - * @param array $options Options for updating the RRD database. This is list of strings. See man page of rrd update - * for whole list of options. - * @throws RrdException - * - */ -function rrd_update(string $filename, array $options): void -{ - error_clear_last(); - $result = \rrd_update($filename, $options); - if ($result === false) { - throw RrdException::createFromPhpError(); - } -} - - -/** - * Exports the information about RRD database file. This data can be converted - * to XML file via user space PHP script and then restored back as RRD database - * file. - * - * @param array $options Array of options for the export, see rrd xport man page. - * @return array Array with information about RRD database file. - * @throws RrdException - * - */ -function rrd_xport(array $options): array -{ - error_clear_last(); - $result = \rrd_xport($options); - if ($result === false) { - throw RrdException::createFromPhpError(); - } - return $result; -} |