|
TYPO3 API
SVNRelease
|
00001 <?php 00002 /*************************************************************** 00003 * Copyright notice 00004 * 00005 * (c) 2009 Jochen Rau <jochen.rau@typoplanet.de> 00006 * All rights reserved 00007 * 00008 * This class is a backport of the corresponding class of FLOW3. 00009 * All credits go to the v5 team. 00010 * 00011 * This script is part of the TYPO3 project. The TYPO3 project is 00012 * free software; you can redistribute it and/or modify 00013 * it under the terms of the GNU General Public License as published by 00014 * the Free Software Foundation; either version 2 of the License, or 00015 * (at your option) any later version. 00016 * 00017 * The GNU General Public License can be found at 00018 * http://www.gnu.org/copyleft/gpl.html. 00019 * 00020 * This script is distributed in the hope that it will be useful, 00021 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00022 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00023 * GNU General Public License for more details. 00024 * 00025 * This copyright notice MUST APPEAR in all copies of the script! 00026 ***************************************************************/ 00027 00028 /** 00029 * A statement acting as a constraint. 00030 * 00031 * @package Extbase 00032 * @subpackage Persistence\QOM 00033 * @version $Id: Statement.php 1993 2010-03-09 21:44:20Z jocrau $ 00034 * @scope prototype 00035 */ 00036 class Tx_Extbase_Persistence_QOM_Statement { 00037 00038 /** 00039 * constants determining the language of the query 00040 */ 00041 const TYPO3_SQL_MYSQL = 'TYPO3-SQL-MYSQL'; 00042 00043 /** 00044 * @var string 00045 */ 00046 protected $statement; 00047 00048 /** 00049 * @var array 00050 */ 00051 protected $boundVariables = array(); 00052 00053 /** 00054 * @var string 00055 */ 00056 protected $language; 00057 00058 /** 00059 * Constructs the Statement instance 00060 * 00061 * @param string $statement The statement 00062 * @param array $boundVariables An array of variables to bind to the statement 00063 * @param string $language The query language. One of the above constants. 00064 */ 00065 public function __construct($statement, array $boundVariables = array(), $language = self::TYPO3_SQL_MYSQL) { 00066 $this->statement = $statement; 00067 $this->boundVariables = $boundVariables; 00068 $this->language = $language; 00069 } 00070 00071 /** 00072 * Gets the statement. 00073 * 00074 * @return the statement; non-null 00075 */ 00076 public function getStatement() { 00077 return $this->statement; 00078 } 00079 00080 /** 00081 * Gets the bound variables 00082 * 00083 * @return array $boundVariables 00084 */ 00085 public function getBoundVariables() { 00086 return $this->boundVariables; 00087 } 00088 00089 /** 00090 * Gets the language. 00091 * 00092 * @return string The language; one of self:: 00093 */ 00094 public function getLanguage() { 00095 return $this->language; 00096 } 00097 00098 } 00099 00100 ?>
1.8.0