forked from wanze/TemplateEngineFactory
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTemplateEngineCache.php
More file actions
57 lines (46 loc) · 1.09 KB
/
TemplateEngineCache.php
File metadata and controls
57 lines (46 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
<?php
/**
* TemplateEngineCache
*
* Template engines extending from class 'TemplateEngine' that support caching must implement the methods
* from this interface. The TemplateEngineFactory module takes care of clearing the cache whenever pages
* are modified or deleted.
*
* @author Stefan Wanzenried <stefan.wanzenried@gmail.com>
*
* ProcessWire 2.x
* Copyright (C) 2014 by Ryan Cramer
* Licensed under GNU/GPL v2, see LICENSE.TXT
*
* http://processwire.com
*
*/
interface TemplateEngineCache {
/**
* Get cached output of template or null if no cache exists
*
* @return string|null
*/
public function getCache();
/**
* Cache output of current template
*
*/
public function storeCache();
/**
* Clear cache of current template
*
*/
public function clearCache();
/**
* Clear cache completely, also cache of all other templates
*
*/
public function clearAllCache();
/**
* Returns true if a cache exists for the template
*
* @return bool
*/
public function isCached();
}