summaryrefslogtreecommitdiff
path: root/classes/cache/adapter.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2023-10-25 12:55:09 +0300
committerAndrew Dolgov <[email protected]>2023-10-25 12:55:09 +0300
commit865ecc87963dc3b26e66296616eef2a1cc41ac3f (patch)
treebf2ecd8a391103bdb2c8b70cd33c47467310754b /classes/cache/adapter.php
parent0a5507d3bd79d04c860455664f919bf8e7274fda (diff)
move to psr-4 autoloader
Diffstat (limited to 'classes/cache/adapter.php')
-rw-r--r--classes/cache/adapter.php36
1 files changed, 0 insertions, 36 deletions
diff --git a/classes/cache/adapter.php b/classes/cache/adapter.php
deleted file mode 100644
index fecfc7667..000000000
--- a/classes/cache/adapter.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-interface Cache_Adapter {
- public function set_dir(string $dir) : void;
- public function get_dir(): string;
- public function make_dir(): bool;
- public function is_writable(?string $filename = null): bool;
- public function exists(string $filename): bool;
- /**
- * @return int|false -1 if the file doesn't exist, false if an error occurred, size in bytes otherwise
- */
- public function get_size(string $filename);
- /**
- * @return int|false -1 if the file doesn't exist, false if an error occurred, timestamp otherwise
- */
- public function get_mtime(string $filename);
- /**
- * @param mixed $data
- *
- * @return int|false Bytes written or false if an error occurred.
- */
- public function put(string $filename, $data);
- public function get(string $filename): ?string;
- public function get_full_path(string $filename): string;
- public function remove(string $filename) : bool;
- /**
- * @return false|null|string false if detection failed, null if the file doesn't exist, string mime content type otherwise
- */
- public function get_mime_type(string $filename);
- /**
- * @return bool|int false if the file doesn't exist (or unreadable) or isn't audio/video, true if a plugin handled, otherwise int of bytes sent
- */
- public function send(string $filename);
-
- /** Catchall function to expire all subfolders/prefixes in the cache, invoked on the backend */
- public function expire_all(): void;
-}