1: <?php
2:
3: /**
4: * This file is part of the Nette Framework (https://nette.org)
5: *
6: * Copyright (c) 2004 David Grudl (http://davidgrudl.com)
7: *
8: * For the full copyright and license information, please view
9: * the file license.txt that was distributed with this source code.
10: * @package Nette\Templates
11: */
12:
13:
14:
15: /**
16: * Template cache storage.
17: *
18: * @author David Grudl
19: * @package Nette\Templates
20: */
21: class NTemplateCacheStorage extends NFileStorage
22: {
23:
24: /**
25: * Reads cache data from disk.
26: * @param array
27: * @return mixed
28: */
29: protected function readData($meta)
30: {
31: return array(
32: 'file' => $meta[self::FILE],
33: 'handle' => $meta[self::HANDLE],
34: );
35: }
36:
37:
38:
39: /**
40: * Returns file name.
41: * @param string
42: * @return string
43: */
44: protected function getCacheFile($key)
45: {
46: return parent::getCacheFile($key) . '.php';
47: }
48:
49: }
50: