c04faf32cdb6ad2dcad4479f34b3ecb6efa99ce4
[Packages/TYPO3.CMS.git] / t3lib / cache / backend / class.t3lib_cache_backend_nullbackend.php
1 <?php
2 /***************************************************************
3 * Copyright notice
4 *
5 * (c) 2009-2011 Ingo Renner <ingo@typo3.org>
6 * All rights reserved
7 *
8 * This script is part of the TYPO3 project. The TYPO3 project is
9 * free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * The GNU General Public License can be found at
15 * http://www.gnu.org/copyleft/gpl.html.
16 *
17 * This script is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
21 *
22 * This copyright notice MUST APPEAR in all copies of the script!
23 ***************************************************************/
24
25
26 /**
27 * A caching backend which forgets everything immediately
28 *
29 * This file is a backport from FLOW3
30 *
31 * @package TYPO3
32 * @subpackage t3lib_cache
33 * @api
34 * @version $Id$
35 */
36 class t3lib_cache_backend_NullBackend extends t3lib_cache_backend_AbstractBackend {
37
38 /**
39 * Acts as if it would save data
40 *
41 * @param string ignored
42 * @param string ignored
43 * @param array ignored
44 * @param integer ignored
45 * @return void
46 * @author Robert Lemke <robert@typo3.org>
47 */
48 public function set($entryIdentifier, $data, array $tags = array(), $lifetime = NULL) {
49 }
50
51 /**
52 * Returns False
53 *
54 * @param string ignored
55 * @return boolean FALSE
56 * @author Robert Lemke <robert@typo3.org>
57 */
58 public function get($entryIdentifier) {
59 return FALSE;
60 }
61
62 /**
63 * Returns False
64 *
65 * @param string ignored
66 * @return boolean FALSE
67 * @author Robert Lemke <robert@typo3.org>
68 */
69 public function has($entryIdentifier) {
70 return FALSE;
71 }
72
73 /**
74 * Does nothing
75 *
76 * @param string ignored
77 * @return boolean FALSE
78 * @author Robert Lemke <robert@typo3.org>
79 */
80 public function remove($entryIdentifier) {
81 return FALSE;
82 }
83
84 /**
85 * Returns an empty array
86 *
87 * @param string ignored
88 * @return array An empty array
89 * @author Robert Lemke <robert@typo3.org>
90 */
91 public function findIdentifiersByTag($tag) {
92 return array();
93 }
94
95 /**
96 * Returns an empty array
97 *
98 * @param string ignored
99 * @return array An empty array
100 * @author Ingo Renner <ingo@typo3.org>
101 */
102 public function findIdentifiersByTags(array $tags) {
103 return array();
104 }
105
106 /**
107 * Does nothing
108 *
109 * @return void
110 * @author Robert Lemke <robert@typo3.org>
111 */
112 public function flush() {
113 }
114
115 /**
116 * Does nothing
117 *
118 * @param string ignored
119 * @return void
120 * @author Robert Lemke <robert@typo3.org>
121 */
122 public function flushByTag($tag) {
123 }
124
125 /**
126 * Does nothing
127 *
128 * @param array ignored
129 * @return void
130 * @author Ingo Renner <ingo@typo3.org>
131 */
132 public function flushByTags(array $tags) {
133 }
134
135 /**
136 * Does nothing
137 *
138 * @return void
139 * @author Karsten Dambekalns <karsten@typo3.org>
140 */
141 public function collectGarbage() {
142 }
143 }
144
145
146 if (defined('TYPO3_MODE') && isset($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['t3lib/cache/backend/class.t3lib_cache_backend_nullbackend.php'])) {
147 include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['t3lib/cache/backend/class.t3lib_cache_backend_nullbackend.php']);
148 }
149
150 ?>