1: <?php
2:
3: namespace RedBeanPHP;
4:
5: /**
6: * Database Cursor Interface.
7: * Represents a simple database cursor.
8: * Cursors make it possible to create lightweight BeanCollections.
9: *
10: * @file RedBeanPHP/Cursor.php
11: * @author Gabor de Mooij and the RedBeanPHP Community
12: * @license BSD/GPLv2
13: *
14: * @copyright
15: * copyright (c) G.J.G.T. (Gabor) de Mooij and the RedBeanPHP Community
16: * This source file is subject to the BSD/GPLv2 License that is bundled
17: * with this source code in the file license.txt.
18: */
19: interface Cursor
20: {
21: /**
22: * Retrieves the next row from the result set.
23: *
24: * @return array
25: */
26: public function getNextItem();
27:
28: /**
29: * Closes the database cursor.
30: * Some databases require a cursor to be closed before executing
31: * another statement/opening a new cursor.
32: *
33: * @return void
34: */
35: public function close();
36: }
37: