Blame view

src/vendor/1.2.5/Phalcon/Db/ResultInterface.php 2.06 KB
ef60cd4d   Administrator   first commit
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
  <?php 
  
  namespace Phalcon\Db {
  
  	/**
  	 * Phalcon\Db\ResultInterface initializer
  	 */
  	
  	interface ResultInterface {
  
  		/**
  		 * \Phalcon\Db\Result\Pdo constructor
  		 *
  		 * @param \Phalcon\Db\AdapterInterface $connection
  		 * @param string $sqlStatement
  		 * @param array $bindParams
  		 * @param array $bindTypes
  		 * @param \PDOStatement $result
  		 */
  		public function __construct($connection, $result, $sqlStatement=null, $bindParams=null, $bindTypes=null);
  
  
  		/**
  		 * Allows to executes the statement again. Some database systems don't support scrollable cursors,
  		 * So, as cursors are forward only, we need to execute the cursor again to fetch rows from the begining
  		 *
  		 * @return boolean
  		 */
  		public function execute();
  
  
  		/**
  		 * Fetches an array/object of strings that corresponds to the fetched row, or FALSE if there are no more rows.
  		 * This method is affected by the active fetch flag set using \Phalcon\Db\Result\Pdo::setFetchMode
  		 *
  		 * @return mixed
  		 */
  		public function fetch();
  
  
  		/**
  		 * Returns an array of strings that corresponds to the fetched row, or FALSE if there are no more rows.
  		 * This method is affected by the active fetch flag set using \Phalcon\Db\Result\Pdo::setFetchMode
  		 *
  		 * @return mixed
  		 */
  		public function fetchArray();
  
  
  		/**
  		 * Returns an array of arrays containing all the records in the result
  		 * This method is affected by the active fetch flag set using \Phalcon\Db\Result\Pdo::setFetchMode
  		 *
  		 * @return array
  		 */
  		public function fetchAll();
  
  
  		/**
  		 * Gets number of rows returned by a resulset
  		 *
  		 * @return int
  		 */
  		public function numRows();
  
  
  		/**
  		 * Moves internal resulset cursor to another position letting us to fetch a certain row
  		 *
  		 * @param int $number
  		 */
  		public function dataSeek($number);
  
  
  		/**
  		 * Changes the fetching mode affecting \Phalcon\Db\Result\Pdo::fetch()
  		 *
  		 * @param int $fetchMode
  		 */
  		public function setFetchMode($fetchMode);
  
  
  		/**
  		 * Gets the internal PDO result object
  		 *
  		 * @return \PDOStatement
  		 */
  		public function getInternalResult();
  
  	}
  }