|
1 <?php |
|
2 /** |
|
3 * Zend Framework |
|
4 * |
|
5 * LICENSE |
|
6 * |
|
7 * This source file is subject to the new BSD license that is bundled |
|
8 * with this package in the file LICENSE.txt. |
|
9 * It is also available through the world-wide-web at this URL: |
|
10 * http://framework.zend.com/license/new-bsd |
|
11 * If you did not receive a copy of the license and are unable to |
|
12 * obtain it through the world-wide-web, please send an email |
|
13 * to license@zend.com so we can send you a copy immediately. |
|
14 * |
|
15 * @category Zend |
|
16 * @package Zend_Auth |
|
17 * @subpackage Storage |
|
18 * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) |
|
19 * @license http://framework.zend.com/license/new-bsd New BSD License |
|
20 * @version $Id: Interface.php 20096 2010-01-06 02:05:09Z bkarwin $ |
|
21 */ |
|
22 |
|
23 /** |
|
24 * @category Zend |
|
25 * @package Zend_Auth |
|
26 * @subpackage Storage |
|
27 * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com) |
|
28 * @license http://framework.zend.com/license/new-bsd New BSD License |
|
29 */ |
|
30 interface Zend_Auth_Storage_Interface |
|
31 { |
|
32 /** |
|
33 * Returns true if and only if storage is empty |
|
34 * |
|
35 * @throws Zend_Auth_Storage_Exception If it is impossible to determine whether storage is empty |
|
36 * @return boolean |
|
37 */ |
|
38 public function isEmpty(); |
|
39 |
|
40 /** |
|
41 * Returns the contents of storage |
|
42 * |
|
43 * Behavior is undefined when storage is empty. |
|
44 * |
|
45 * @throws Zend_Auth_Storage_Exception If reading contents from storage is impossible |
|
46 * @return mixed |
|
47 */ |
|
48 public function read(); |
|
49 |
|
50 /** |
|
51 * Writes $contents to storage |
|
52 * |
|
53 * @param mixed $contents |
|
54 * @throws Zend_Auth_Storage_Exception If writing $contents to storage is impossible |
|
55 * @return void |
|
56 */ |
|
57 public function write($contents); |
|
58 |
|
59 /** |
|
60 * Clears contents from storage |
|
61 * |
|
62 * @throws Zend_Auth_Storage_Exception If clearing contents from storage is impossible |
|
63 * @return void |
|
64 */ |
|
65 public function clear(); |
|
66 } |