summaryrefslogtreecommitdiff
path: root/classes/cache/Cache_interface.php
diff options
context:
space:
mode:
Diffstat (limited to 'classes/cache/Cache_interface.php')
-rw-r--r--classes/cache/Cache_interface.php34
1 files changed, 0 insertions, 34 deletions
diff --git a/classes/cache/Cache_interface.php b/classes/cache/Cache_interface.php
deleted file mode 100644
index 7c49789..0000000
--- a/classes/cache/Cache_interface.php
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
-
-/** Cache interface
- * ---
- * Interface to save results of expensive data-extraction proccess,
- * in a fast-accessed medium (ussually RAM or NVME SSD units)
- */
-interface Cache_interface
-{
- /** Cache::set($key, $data, $ttl) : void
- *
- * @param $key (string): reference label
- * @param $data (mixed): actual data (avoid storing true|false)
- * @param $ttl (int): time to live (seconds)
- */
- public function set(string $key, $data, int $ttl);
-
-
- /** Cache::get($key) : mixed
- *
- * @param $key (string)
- * @return mixed: fetched $data -or- false on failure
- */
- public function get(string $key);
-
-
- /** Cache::flush( $olderThan ) : void
- *
- * clear cache older than $olderThan
- * @param $olderThan (int) in seconds
- */
- public function flush(int $olderThan = 0);
-
-} \ No newline at end of file