2323 * Interface for Doctrine adapter statements.
2424 *
2525 * @author Konsta Vesterinen <[email protected] > 26- * @license http://www.opensource.org/licenses/lgpl-license.php LGPL
2726 *
2827 * @see www.doctrine-project.org
29- * @since 1.0
30- *
31- * @version $Revision: 7490 $
3228 */
3329interface Doctrine_Adapter_Statement_Interface
3430{
3531 /**
3632 * Bind a column to a PHP variable.
3733 *
38- * @param mixed $column Number of the column (1-indexed) or name of the column in the result set.
39- * If using the column name, be aware that the name should match
40- * the case of the column, as returned by the driver.
41- * @param string $param name of the PHP variable to which the column will be bound
42- * @param int $type data type of the parameter, specified by the Doctrine_Core::PARAM_* constants
43- *
44- * @return bool Returns TRUE on success or FALSE on failure
34+ * @param mixed $column Number of the column (1-indexed) or name of the column in the result set.
35+ * If using the column name, be aware that the name should match
36+ * the case of the column, as returned by the driver.
37+ * @param string $param name of the PHP variable to which the column will be bound
38+ * @param int $type data type of the parameter, specified by the Doctrine_Core::PARAM_* constants
39+ * @return bool Returns TRUE on success or FALSE on failure
4540 */
4641 public function bindColumn ($ column , $ param , $ type = null );
4742
4843 /**
4944 * Binds a value to a corresponding named or question mark
5045 * placeholder in the SQL statement that was use to prepare the statement.
5146 *
52- * @param mixed $param Parameter identifier. For a prepared statement using named placeholders,
53- * this will be a parameter name of the form :name. For a prepared statement
54- * using question mark placeholders, this will be the 1-indexed position of the parameter
55- * @param mixed $value the value to bind to the parameter
56- * @param int $type explicit data type for the parameter using the Doctrine_Core::PARAM_* constants
57- *
58- * @return bool returns TRUE on success or FALSE on failure
47+ * @param mixed $param Parameter identifier. For a prepared statement using named placeholders,
48+ * this will be a parameter name of the form :name. For a prepared statement
49+ * using question mark placeholders, this will be the 1-indexed position of the parameter
50+ * @param mixed $value the value to bind to the parameter
51+ * @param int $type explicit data type for the parameter using the Doctrine_Core::PARAM_* constants
52+ * @return bool returns TRUE on success or FALSE on failure
5953 */
6054 public function bindValue ($ param , $ value , $ type = null );
6155
@@ -70,14 +64,13 @@ public function bindValue($param, $value, $type = null);
7064 * of stored procedures that return data as output parameters, and some also as input/output
7165 * parameters that both send in data and are updated to receive it.
7266 *
73- * @param mixed $variable name of the PHP variable to bind to the SQL statement parameter
74- * @param int $type Explicit data type for the parameter using the Doctrine_Core::PARAM_* constants. To return
75- * an INOUT parameter from a stored procedure, use the bitwise OR operator to set the
76- * Doctrine_Core::PARAM_INPUT_OUTPUT bits for the data_type parameter.
77- * @param int $length Length of the data type. To indicate that a parameter is an OUT parameter
78- * from a stored procedure, you must explicitly set the length.
79- *
80- * @return bool returns TRUE on success or FALSE on failure
67+ * @param mixed $variable name of the PHP variable to bind to the SQL statement parameter
68+ * @param int $type Explicit data type for the parameter using the Doctrine_Core::PARAM_* constants. To return
69+ * an INOUT parameter from a stored procedure, use the bitwise OR operator to set the
70+ * Doctrine_Core::PARAM_INPUT_OUTPUT bits for the data_type parameter.
71+ * @param int $length Length of the data type. To indicate that a parameter is an OUT parameter
72+ * from a stored procedure, you must explicitly set the length.
73+ * @return bool returns TRUE on success or FALSE on failure
8174 */
8275 public function bindParam ($ column , &$ variable , $ type = null , $ length = null , $ driverOptions = array ());
8376
@@ -124,10 +117,9 @@ public function errorInfo();
124117 * if any, of their associated parameter markers or pass an array of input-only
125118 * parameter values
126119 *
127- * @param array $params an array of values with as many elements as there are
128- * bound parameters in the SQL statement being executed
129- *
130- * @return bool returns TRUE on success or FALSE on failure
120+ * @param array $params an array of values with as many elements as there are
121+ * bound parameters in the SQL statement being executed
122+ * @return bool returns TRUE on success or FALSE on failure
131123 */
132124 public function execute ($ params = null );
133125
@@ -164,10 +156,9 @@ public function fetch(
164156 /**
165157 * Returns an array containing all of the result set rows.
166158 *
167- * @param int $fetchStyle Controls how the next row will be returned to the caller.
168- * This value must be one of the Doctrine_Core::FETCH_* constants,
169- * defaulting to Doctrine_Core::FETCH_BOTH
170- *
159+ * @param int $fetchStyle Controls how the next row will be returned to the caller.
160+ * This value must be one of the Doctrine_Core::FETCH_* constants,
161+ * defaulting to Doctrine_Core::FETCH_BOTH
171162 * @return array
172163 */
173164 public function fetchAll ($ fetchStyle = Doctrine_Core::FETCH_BOTH );
@@ -176,10 +167,9 @@ public function fetchAll($fetchStyle = Doctrine_Core::FETCH_BOTH);
176167 * Returns a single column from the next row of a
177168 * result set or FALSE if there are no more rows.
178169 *
179- * @param int $columnIndex 0-indexed number of the column you wish to retrieve from the row. If no
180- * value is supplied, Doctrine_Adapter_Statement_Interface->fetchColumn()
181- * fetches the first column.
182- *
170+ * @param int $columnIndex 0-indexed number of the column you wish to retrieve from the row. If no
171+ * value is supplied, Doctrine_Adapter_Statement_Interface->fetchColumn()
172+ * fetches the first column.
183173 * @return string returns a single column in the next row of a result set
184174 */
185175 public function fetchColumn ($ columnIndex = 0 );
@@ -190,11 +180,10 @@ public function fetchColumn($columnIndex = 0);
190180 * Fetches the next row and returns it as an object. This function is an alternative to
191181 * Doctrine_Adapter_Statement_Interface->fetch() with Doctrine_Core::FETCH_CLASS or Doctrine_Core::FETCH_OBJ style.
192182 *
193- * @param string $className name of the created class, defaults to stdClass
194- * @param array $args elements of this array are passed to the constructor
195- *
196- * @return mixed an instance of the required class with property names that correspond
197- * to the column names or FALSE in case of an error
183+ * @param string $className name of the created class, defaults to stdClass
184+ * @param array $args elements of this array are passed to the constructor
185+ * @return mixed an instance of the required class with property names that correspond
186+ * to the column names or FALSE in case of an error
198187 */
199188 public function fetchObject ($ className = 'stdClass ' , $ args = array ());
200189
@@ -212,8 +201,7 @@ public function getAttribute($attribute);
212201 /**
213202 * Returns metadata for a column in a result set.
214203 *
215- * @param int $column the 0-indexed column in the result set
216- *
204+ * @param int $column the 0-indexed column in the result set
217205 * @return array Associative meta data array with the following structure:
218206 *
219207 * native_type The PHP native type used to represent the column value.
@@ -254,21 +242,19 @@ public function rowCount();
254242 /**
255243 * Set a statement attribute.
256244 *
257- * @param int $attribute
258- * @param mixed $value the value of given attribute
259- *
260- * @return bool returns TRUE on success or FALSE on failure
245+ * @param int $attribute
246+ * @param mixed $value the value of given attribute
247+ * @return bool returns TRUE on success or FALSE on failure
261248 */
262249 public function setAttribute ($ attribute , $ value );
263250
264251 /**
265252 * Set the default fetch mode for this statement.
266253 *
267- * @param int $mode the fetch mode must be one of the Doctrine_Core::FETCH_* constants
268- * @param mixed|null $arg1
269- * @param mixed|null $arg2
270- *
271- * @return bool returns 1 on success or FALSE on failure
254+ * @param int $mode the fetch mode must be one of the Doctrine_Core::FETCH_* constants
255+ * @param mixed|null $arg1
256+ * @param mixed|null $arg2
257+ * @return bool returns 1 on success or FALSE on failure
272258 */
273259 public function setFetchMode ($ mode , $ arg1 = null , $ arg2 = null );
274260}
0 commit comments