Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Karla ImageMagick wrapper library |
| 5 | * |
| 6 | * PHP Version 8.0< |
| 7 | * |
| 8 | * @category Utility |
| 9 | * @author Johannes Skov Frandsen <jsf@greenoak.dk> |
| 10 | * @license http://www.opensource.org/licenses/mit-license.php MIT |
| 11 | * @link https://github.com/localgod/karla Karla |
| 12 | * @since 2012-04-05 |
| 13 | */ |
| 14 | |
| 15 | declare(strict_types=1); |
| 16 | |
| 17 | namespace Karla; |
| 18 | |
| 19 | /** |
| 20 | * Interface for Karla caching tools |
| 21 | * |
| 22 | * @category Utility |
| 23 | * @author Johannes Skov Frandsen <jsf@greenoak.dk> |
| 24 | * @license http://www.opensource.org/licenses/mit-license.php MIT |
| 25 | * @link https://github.com/localgod/karla Karla |
| 26 | */ |
| 27 | interface Cache |
| 28 | { |
| 29 | /** |
| 30 | * Check if there exists a cached version of the file |
| 31 | * |
| 32 | * @param string $inputFile |
| 33 | * Path to file |
| 34 | * @param string $outputFile |
| 35 | * Path to file |
| 36 | * @param string[] $options |
| 37 | * Options |
| 38 | * |
| 39 | * @return boolean |
| 40 | */ |
| 41 | public function isCached(string $inputFile, string $outputFile, array $options): bool; |
| 42 | |
| 43 | /** |
| 44 | * Get cached version of the file |
| 45 | * |
| 46 | * @param string $inputFile |
| 47 | * Path to file |
| 48 | * @param string $outputFile |
| 49 | * Path to file |
| 50 | * @param string[] $options |
| 51 | * Options |
| 52 | * |
| 53 | * @return string |
| 54 | */ |
| 55 | public function getCached(string $inputFile, string $outputFile, array $options): string; |
| 56 | |
| 57 | /** |
| 58 | * Set cached version of the file |
| 59 | * |
| 60 | * @param string $inputFile |
| 61 | * Path to file |
| 62 | * @param string $outputFile |
| 63 | * Path to file |
| 64 | * @param string[] $options |
| 65 | * Options |
| 66 | * |
| 67 | * @return void |
| 68 | */ |
| 69 | public function setCache(string $inputFile, string $outputFile, string $options): void; |
| 70 | } |