[TASK] Move and Namespace classes
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / Classes / Database / PreProcessQueryHookInterface.php
1 <?php
2 namespace TYPO3\CMS\Core\Database;
3
4 /***************************************************************
5 * Copyright notice
6 *
7 * (c) 2011 Xavier Perseguers <typo3@perseguers.ch>
8 * All rights reserved
9 *
10 * This script is part of the TYPO3 project. The TYPO3 project is
11 * free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2 of the License, or
14 * (at your option) any later version.
15 *
16 * The GNU General Public License can be found at
17 * http://www.gnu.org/copyleft/gpl.html.
18 * A copy is found in the textfile GPL.txt and important notices to the license
19 * from the author is found in LICENSE.txt distributed with these scripts.
20 *
21 *
22 * This script is distributed in the hope that it will be useful,
23 * but WITHOUT ANY WARRANTY; without even the implied warranty of
24 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 * GNU General Public License for more details.
26 *
27 * This copyright notice MUST APPEAR in all copies of the script!
28 ***************************************************************/
29 /**
30 * Interface for classes which hook into t3lib_DB and do additional processing
31 * before a query has been executed.
32 *
33 * @author Xavier Perseguers <typo3@perseguers.ch>
34 * @package TYPO3
35 * @subpackage t3lib
36 */
37 interface PreProcessQueryHookInterface
38 {
39 /**
40 * Pre-processor for the INSERTquery method.
41 *
42 * @param string $table Database table name
43 * @param array $fieldsValues Field values as key => value pairs
44 * @param string/array $noQuoteFields List/array of keys NOT to quote
45 * @param \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject
46 * @return void
47 */
48 public function INSERTquery_preProcessAction(&$table, array &$fieldsValues, &$noQuoteFields, \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject);
49
50 /**
51 * Pre-processor for the INSERTmultipleRows method.
52 * BEWARE: When using DBAL, this hook will not be called at all. Instead,
53 * INSERTquery_preProcessAction() will be invoked for each row.
54 *
55 * @param string $table Database table name
56 * @param array $fields Field names
57 * @param array $rows Table rows
58 * @param string/array $noQuoteFields List/array of keys NOT to quote
59 * @param \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject
60 * @return void
61 */
62 public function INSERTmultipleRows_preProcessAction(&$table, array &$fields, array &$rows, &$noQuoteFields, \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject);
63
64 /**
65 * Pre-processor for the UPDATEquery method.
66 *
67 * @param string $table Database table name
68 * @param string $where WHERE clause
69 * @param array $fieldsValues Field values as key => value pairs
70 * @param string/array $noQuoteFields List/array of keys NOT to quote
71 * @param \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject
72 * @return void
73 */
74 public function UPDATEquery_preProcessAction(&$table, &$where, array &$fieldsValues, &$noQuoteFields, \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject);
75
76 /**
77 * Pre-processor for the DELETEquery method.
78 *
79 * @param string $table Database table name
80 * @param string $where WHERE clause
81 * @param \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject
82 * @return void
83 */
84 public function DELETEquery_preProcessAction(&$table, &$where, \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject);
85
86 /**
87 * Pre-processor for the TRUNCATEquery method.
88 *
89 * @param string $table Database table name
90 * @param \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject
91 * @return void
92 */
93 public function TRUNCATEquery_preProcessAction(&$table, \TYPO3\CMS\Core\Database\DatabaseConnection $parentObject);
94
95 }
96
97 ?>