Commit d458197e authored by jwage's avatar jwage

[2.0] Another step towards finishing namespace refactoring

parent 43b67919
<?php
/*
* $Id: Configurable.php 4523 2008-06-15 15:56:28Z romanb $
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
#namespace Doctrine::Common;
/**
* Doctrine_Configurable
*
* @license http://www.opensource.org/licenses/lgpl-license.php LGPL
* @link www.phpdoctrine.org
* @since 2.0
* @version $Revision: 4523 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
* @author Roman Borschel <roman@code-factory.org>
*/
interface Doctrine_Common_Configurable
{
public function getAttribute($name);
public function setAttribute($name, $value);
public function hasAttribute($name);
}
\ No newline at end of file
......@@ -284,7 +284,7 @@ class Connection
/**
* Updates table row(s) with specified data
*
* @throws Doctrine_Connection_Exception if something went wrong at the database level
* @throws Doctrine\DBAL\ConnectionException if something went wrong at the database level
* @param string $table The table to insert data into
* @param array $values An associateve array containing column-value pairs.
* @return mixed boolean false if empty value array was given,
......@@ -509,7 +509,7 @@ class Connection
* @param string $query sql query
* @param array $params query parameters
*
* @return PDOStatement|Doctrine_Adapter_Statement
* @return PDOStatement
*/
public function execute($query, array $params = array())
{
......@@ -536,7 +536,7 @@ class Connection
* @param string $query sql query
* @param array $params query parameters
*
* @return PDOStatement|Doctrine_Adapter_Statement
* @return PDOStatement
* @todo Rename to executeUpdate().
*/
public function exec($query, array $params = array()) {
......@@ -562,7 +562,7 @@ class Connection
/**
* Wraps the given exception into a driver-specific exception and rethrows it.
*
* @throws Doctrine_Connection_Exception
* @throws Doctrine\DBAL\ConnectionException
*/
public function rethrowException(Exception $e, $invoker)
{
......@@ -711,7 +711,7 @@ class Connection
* eventlistener methods
*
* @param string $savepoint Name of a savepoint to rollback to.
* @throws Doctrine_Transaction_Exception If the rollback operation fails at database level.
* @throws Doctrine\DBAL\ConnectionException If the rollback operation fails at database level.
* @return boolean FALSE if rollback couldn't be performed, TRUE otherwise.
*/
public function rollback()
......@@ -772,4 +772,4 @@ class Connection
}
return $this->_schemaManager;
}
}
}
\ No newline at end of file
......@@ -20,7 +20,7 @@ interface Driver
* @return Doctrine::DBAL::Connection The database connection.
*/
public function connect(array $params, $username = null, $password = null, array $driverOptions = array());
/**
* Gets the DatabasePlatform instance that provides all the metadata about
* the platform this driver connects to.
......@@ -28,7 +28,7 @@ interface Driver
* @return Doctrine::DBAL::DatabasePlatform The database platform.
*/
public function getDatabasePlatform();
/**
* Gets the SchemaManager that can be used to inspect and change the underlying
* database schema of the platform this driver connects to.
......@@ -36,5 +36,4 @@ interface Driver
* @return Doctrine\DBAL\SchemaManager
*/
public function getSchemaManager(Connection $conn);
}
}
\ No newline at end of file
......@@ -19,4 +19,4 @@ class PDOConnection extends PDO implements \Doctrine\DBAL\Driver\Connection
$this->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$this->setAttribute(PDO::ATTR_CASE, PDO::CASE_LOWER);
}
}
}
\ No newline at end of file
......@@ -7,7 +7,7 @@ namespace Doctrine\DBAL\Driver\PDOMsSql;
*
* @since 2.0
*/
class Connection extends PDO implements \Doctrine\DBAL\Driver\Connection
class Connection extends PDO implements \Doctrine\DBAL\Driver\PDOConnection
{
/**
* Performs the rollback.
......@@ -18,7 +18,7 @@ class Connection extends PDO implements \Doctrine\DBAL\Driver\Connection
{
$this->exec('ROLLBACK TRANSACTION');
}
/**
* Performs the commit.
*
......@@ -28,7 +28,7 @@ class Connection extends PDO implements \Doctrine\DBAL\Driver\Connection
{
$this->exec('COMMIT TRANSACTION');
}
/**
* Begins a database transaction.
*
......@@ -38,5 +38,4 @@ class Connection extends PDO implements \Doctrine\DBAL\Driver\Connection
{
$this->exec('BEGIN TRANSACTION');
}
}
}
\ No newline at end of file
......@@ -4,16 +4,16 @@ namespace Doctrine\DBAL\Driver\PDOMsSql;
class Driver implements \Doctrine\DBAL\Driver
{
public function connect(array $params, $username = null, $password = null, array $driverOptions = array())
{
return new Connection(
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions);
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions
);
}
/**
* Constructs the MySql PDO DSN.
*
......@@ -25,16 +25,14 @@ class Driver implements \Doctrine\DBAL\Driver
{
//TODO
}
public function getDatabasePlatform()
{
return new Doctrine_DatabasePlatform_MySqlPlatform();
return new \Doctrine\DBAL\Platforms\MsSqlPlatform();
}
public function getSchemaManager(Doctrine_Connection $conn)
public function getSchemaManager(\Doctrine\DBAL\Connection $conn)
{
return new Doctrine_Schema_MySqlSchemaManager($conn);
return new \Doctrine\DBAL\Schema\MsSqlSchemaManager($conn);
}
}
}
\ No newline at end of file
......@@ -40,14 +40,15 @@ class Driver implements \Doctrine\DBAL\Driver
public function connect(array $params, $username = null, $password = null, array $driverOptions = array())
{
$conn = new \Doctrine\DBAL\Driver\PDOConnection(
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions);
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions
);
$conn->setAttribute(\PDO::ATTR_AUTOCOMMIT, false);
return $conn;
}
/**
* Constructs the MySql PDO DSN.
*
......@@ -73,16 +74,14 @@ class Driver implements \Doctrine\DBAL\Driver
return $dsn;
}
public function getDatabasePlatform()
{
return new \Doctrine\DBAL\Platforms\MySqlPlatform();
}
public function getSchemaManager(\Doctrine\DBAL\Connection $conn)
{
return new \Doctrine\DBAL\Schema\MySqlSchemaManager($conn);
}
}
}
\ No newline at end of file
......@@ -2,18 +2,20 @@
namespace Doctrine\DBAL\Driver\PDOOracle;
use Doctrine\DBAL\Platforms;
class Driver implements \Doctrine\DBAL\Driver
{
public function connect(array $params, $username = null, $password = null, array $driverOptions = array())
{
return new \Doctrine\DBAL\Driver\PDOConnection(
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions);
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions
);
}
/**
* Constructs the Oracle PDO DSN.
*
......@@ -23,16 +25,14 @@ class Driver implements \Doctrine\DBAL\Driver
{
//TODO
}
public function getDatabasePlatform()
{
return new \Doctrine\DBAL\Platforms\OraclePlatform();
}
public function getSchemaManager(\Doctrine\DBAL\Connection $conn)
{
return new \Doctrine\DBAL\Schema\OracleSchemaManager($conn);
}
}
}
\ No newline at end of file
<?php
#namespace Doctrine::DBAL::Driver::PDOPgSql;
namespace Doctrine\DBAL\Driver\PDOPgSql;
use Doctrine\DBAL\Platforms;
/**
* Driver that connects through pdo_pgsql.
*
* @since 2.0
*/
class Doctrine_DBAL_Driver_PDOPgSql_Driver implements Doctrine_DBAL_Driver
class Driver implements \Doctrine\DBAL\Driver
{
public function connect(array $params, $username = null, $password = null, array $driverOptions = array())
{
return new Doctrine_DBAL_Driver_PDOConnection(
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions);
return new \Doctrine\DBAL\Driver\PDOConnection(
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions
);
}
/**
* Constructs the Postgres PDO DSN.
*
......@@ -28,17 +30,14 @@ class Doctrine_DBAL_Driver_PDOPgSql_Driver implements Doctrine_DBAL_Driver
{
//TODO
}
public function getDatabasePlatform()
{
return new Doctrine_DBAL_Platforms_PostgreSqlPlatform();
return new \Doctrine\DBAL\Platforms\PostgreSqlPlatform();
}
public function getSchemaManager(Doctrine_DBAL_Connection $conn)
public function getSchemaManager(\Doctrine\DBAL\Connection $conn)
{
return new Doctrine_DBAL_Schema_PostgreSqlSchemaManager($conn);
return new \Doctrine\DBAL\Schema\PostgreSqlSchemaManager($conn);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -2,8 +2,6 @@
namespace Doctrine\DBAL\Driver\PDOSqlite;
#use Doctrine::DBAL::Driver;
/**
* The PDO Sqlite driver.
*
......@@ -23,12 +21,13 @@ class Driver implements \Doctrine\DBAL\Driver
public function connect(array $params, $username = null, $password = null, array $driverOptions = array())
{
return new \Doctrine\DBAL\Driver\PDOConnection(
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions);
$this->_constructPdoDsn($params),
$username,
$password,
$driverOptions
);
}
/**
* Constructs the Sqlite PDO DSN.
*
......@@ -46,7 +45,7 @@ class Driver implements \Doctrine\DBAL\Driver
return $dsn;
}
/**
* Gets the database platform that is relevant for this driver.
*/
......@@ -54,7 +53,7 @@ class Driver implements \Doctrine\DBAL\Driver
{
return new \Doctrine\DBAL\Platforms\SqlitePlatform();
}
/**
* Gets the schema manager that is relevant for this driver.
*
......@@ -65,7 +64,4 @@ class Driver implements \Doctrine\DBAL\Driver
{
return new \Doctrine\DBAL\Schema\SqliteSchemaManager($conn);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -5,4 +5,4 @@ namespace Doctrine\DBAL\Driver;
class PDOStatement extends \PDOStatement implements \Doctrine\DBAL\Driver\Statement
{
private function __construct() {}
}
}
\ No newline at end of file
......@@ -67,9 +67,9 @@ interface Statement
/**
* bindParam
* Binds a PHP variable to a corresponding named or question mark placeholder in the
* SQL statement that was use to prepare the statement. Unlike Doctrine_Adapter_Statement_Interface->bindValue(),
* SQL statement that was use to prepare the statement. Unlike PDOStatement->bindValue(),
* the variable is bound as a reference and will only be evaluated at the time
* that Doctrine_Adapter_Statement_Interface->execute() is called.
* that PDOStatement->execute() is called.
*
* Most parameters are input parameters, that is, parameters that are
* used in a read-only fashion to build up the query. Some drivers support the invocation
......@@ -106,7 +106,7 @@ interface Statement
* Returns the number of columns in the result set
*
* @return integer Returns the number of columns in the result set represented
* by the Doctrine_Adapter_Statement_Interface object. If there is no result set,
* by the PDOStatement object. If there is no result set,
* this method should return 0.
*/
public function columnCount();
......@@ -157,18 +157,18 @@ interface Statement
* this value determines which row will be returned to the caller.
* This value must be one of the Query::HYDRATE_ORI_* constants, defaulting to
* Query::HYDRATE_ORI_NEXT. To request a scrollable cursor for your
* Doctrine_Adapter_Statement_Interface object,
* PDOStatement object,
* you must set the PDO::ATTR_CURSOR attribute to Doctrine::CURSOR_SCROLL when you
* prepare the SQL statement with Doctrine_Adapter_Interface->prepare().
*
* @param integer $cursorOffset For a Doctrine_Adapter_Statement_Interface object representing a scrollable cursor for which the
* @param integer $cursorOffset For a PDOStatement object representing a scrollable cursor for which the
* $cursorOrientation parameter is set to Query::HYDRATE_ORI_ABS, this value specifies
* the absolute number of the row in the result set that shall be fetched.
*
* For a Doctrine_Adapter_Statement_Interface object representing a scrollable cursor for
* For a PDOStatement object representing a scrollable cursor for
* which the $cursorOrientation parameter is set to Query::HYDRATE_ORI_REL, this value
* specifies the row to fetch relative to the cursor position before
* Doctrine_Adapter_Statement_Interface->fetch() was called.
* PDOStatement->fetch() was called.
*
* @return mixed
*/
......@@ -197,7 +197,7 @@ interface Statement
* result set or FALSE if there are no more rows.
*
* @param integer $columnIndex 0-indexed number of the column you wish to retrieve from the row. If no
* value is supplied, Doctrine_Adapter_Statement_Interface->fetchColumn()
* value is supplied, PDOStatement->fetchColumn()
* fetches the first column.
*
* @return string returns a single column in the next row of a result set.
......@@ -209,7 +209,7 @@ interface Statement
* Fetches the next row and returns it as an object.
*
* Fetches the next row and returns it as an object. This function is an alternative to
* Doctrine_Adapter_Statement_Interface->fetch() with Query::HYDRATE_CLASS or Query::HYDRATE_OBJ style.
* PDOStatement->fetch() with Query::HYDRATE_CLASS or Query::HYDRATE_OBJ style.
*
* @param string $className Name of the created class, defaults to stdClass.
* @param array $args Elements of this array are passed to the constructor.
......@@ -292,4 +292,4 @@ interface Statement
* @return boolean Returns 1 on success or FALSE on failure.
*/
public function setFetchMode($mode, $arg1);
}
}
\ No newline at end of file
......@@ -48,7 +48,7 @@ final class DriverManager
/** Private constructor. This class cannot be instantiated. */
private function __construct() {}
/**
* Creates a connection object based on the specified parameters.
* This method returns a Doctrine\DBAL\Connection which wraps the underlying
......@@ -128,7 +128,7 @@ final class DriverManager
return new $wrapperClass($params, $driver, $config, $eventManager);
}
/**
* Checks the list of parameters.
*
......@@ -150,5 +150,4 @@ final class DriverManager
throw Exceptions\DBALException::unknownDriver($params['driver']);
}
}
}
}
\ No newline at end of file
......@@ -1953,6 +1953,4 @@ abstract class AbstractPlatform
* @params array $field
*/
abstract public function getVarcharDeclarationSql(array $field);
}
}
\ No newline at end of file
......@@ -4,11 +4,8 @@ namespace Doctrine\DBAL\Platforms;
class Db2Platform extends AbstractPlatform
{
public function getSequenceNextValSql($sequenceName) {
return 'SELECT NEXTVAL FOR ' . $this->quoteIdentifier($sequenceName)
. ' FROM SYSIBM.SYSDUMMY1';
}
}
}
\ No newline at end of file
......@@ -9,7 +9,6 @@ namespace Doctrine\DBAL\Platforms;
*/
class FirebirdPlatform extends AbstractPlatform
{
/**
* Constructor.
*/
......@@ -289,7 +288,4 @@ class FirebirdPlatform extends AbstractPlatform
{
return 'SET TRANSACTION ISOLATION LEVEL ' . $this->_getTransactionIsolationLevelSql($level);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -9,7 +9,6 @@ namespace Doctrine\DBAL\Platforms;
*/
class InformixPlatform extends AbstractPlatform
{
public function __construct()
{
parent::__construct();
......@@ -92,7 +91,4 @@ class InformixPlatform extends AbstractPlatform
}
throw \Doctrine\Common\DoctrineException::updateMe('Unknown field type \'' . $field['type'] . '\'.');
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -5,5 +5,4 @@ class MockPlatform extends AbstractPlatform
{
public function getNativeDeclaration(array $field) {}
public function getPortableDeclaration(array $field) {}
}
}
\ No newline at end of file
......@@ -322,6 +322,4 @@ class MsSqlPlatform extends AbstractPlatform
return 'SET TRANSACTION ISOLATION LEVEL ' . $this->_getTransactionIsolationLevelSql($level);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -1259,6 +1259,4 @@ class MySqlPlatform extends AbstractPlatform
{
return 'SET SESSION TRANSACTION ISOLATION LEVEL ' . $this->_getTransactionIsolationLevelSql($level);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -375,6 +375,4 @@ class OraclePlatform extends AbstractPlatform
return parent::_getTransactionIsolationLevelSql($level);
}
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -833,7 +833,7 @@ class PostgreSqlPlatform extends AbstractPlatform
/**
* return RDBMS specific create sequence statement
*
* @throws Doctrine_Connection_Exception if something fails at database level
* @throws Doctrine\DBAL\ConnectionException if something fails at database level
* @param string $seqName name of the sequence to be created
* @param string $start start value of the sequence; default is 1
* @param array $options An associative array of table options:
......@@ -1001,6 +1001,4 @@ class PostgreSqlPlatform extends AbstractPlatform
return 'SET SESSION CHARACTERISTICS AS TRANSACTION ISOLATION LEVEL '
. $this->_getTransactionIsolationLevelSql($level);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -29,7 +29,6 @@ namespace Doctrine\DBAL\Platforms;
*/
class SqlitePlatform extends AbstractPlatform
{
/**
* the constructor
*/
......@@ -564,5 +563,4 @@ class SqlitePlatform extends AbstractPlatform
{
return false;
}
}
}
\ No newline at end of file
......@@ -228,7 +228,7 @@ abstract class AbstractSchemaManager
* drop existing sequence
* (this method is implemented by the drivers)
*
* @throws Doctrine_Connection_Exception if something fails at database level
* @throws Doctrine\DBAL\ConnectionException if something fails at database level
* @param string $sequenceName name of the sequence to be dropped
* @return void
*/
......@@ -285,7 +285,7 @@ abstract class AbstractSchemaManager
/**
* create sequence
*
* @throws Doctrine_Connection_Exception if something fails at database level
* @throws Doctrine\DBAL\ConnectionException if something fails at database level
* @param string $seqName name of the sequence to be created
* @param string $start start value of the sequence; default is 1
* @param array $options An associative array of table options:
......@@ -476,6 +476,4 @@ abstract class AbstractSchemaManager
$this->_conn->execute($sql);
}
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -614,10 +614,10 @@ class FirebirdSchemaManager extends AbstractSchemaManager
$this->_conn->exec('SET GENERATOR ' . $sequenceName . ' TO ' . ($start-1));
return true;
} catch (Doctrine_Connection_Exception $e) {
} catch (Doctrine\DBAL\ConnectionException $e) {
try {
$this->dropSequence($seqName);
} catch(Doctrine_Connection_Exception $e) {
} catch(Doctrine\DBAL\ConnectionException $e) {
throw \Doctrine\Common\DoctrineException::updateMe('Could not drop inconsistent sequence table');
}
}
......@@ -638,7 +638,4 @@ class FirebirdSchemaManager extends AbstractSchemaManager
return $query;
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -34,28 +34,23 @@ namespace Doctrine\DBAL\Schema;
class InformixSchemaManager extends AbstractSchemaManager
{
protected $sql = array(
'listTables' => "SELECT tabname,tabtype FROM systables WHERE tabtype IN ('T','V') AND owner != 'informix'",
'listColumns' => "SELECT c.colname, c.coltype, c.collength, d.default, c.colno
FROM syscolumns c, systables t,outer sysdefaults d
WHERE c.tabid = t.tabid AND d.tabid = t.tabid AND d.colno = c.colno
AND tabname='%s' ORDER BY c.colno",
'listPk' => "SELECT part1, part2, part3, part4, part5, part6, part7, part8 FROM
systables t, sysconstraints s, sysindexes i WHERE t.tabname='%s'
AND s.tabid=t.tabid AND s.constrtype='P'
AND i.idxname=s.idxname",
'listForeignKeys' => "SELECT tr.tabname,updrule,delrule,
i.part1 o1,i2.part1 d1,i.part2 o2,i2.part2 d2,i.part3 o3,i2.part3 d3,i.part4 o4,i2.part4 d4,
i.part5 o5,i2.part5 d5,i.part6 o6,i2.part6 d6,i.part7 o7,i2.part7 d7,i.part8 o8,i2.part8 d8
from systables t,sysconstraints s,sysindexes i,
sysreferences r,systables tr,sysconstraints s2,sysindexes i2
where t.tabname='%s'
and s.tabid=t.tabid and s.constrtype='R' and r.constrid=s.constrid
and i.idxname=s.idxname and tr.tabid=r.ptabid
and s2.constrid=r.primary and i2.idxname=s2.idxname",
);
}
'listTables' => "SELECT tabname,tabtype FROM systables WHERE tabtype IN ('T','V') AND owner != 'informix'",
'listColumns' => "SELECT c.colname, c.coltype, c.collength, d.default, c.colno
FROM syscolumns c, systables t,outer sysdefaults d
WHERE c.tabid = t.tabid AND d.tabid = t.tabid AND d.colno = c.colno
AND tabname='%s' ORDER BY c.colno",
'listPk' => "SELECT part1, part2, part3, part4, part5, part6, part7, part8 FROM
systables t, sysconstraints s, sysindexes i WHERE t.tabname='%s'
AND s.tabid=t.tabid AND s.constrtype='P'
AND i.idxname=s.idxname",
'listForeignKeys' => "SELECT tr.tabname,updrule,delrule,
i.part1 o1,i2.part1 d1,i.part2 o2,i2.part2 d2,i.part3 o3,i2.part3 d3,i.part4 o4,i2.part4 d4,
i.part5 o5,i2.part5 d5,i.part6 o6,i2.part6 d6,i.part7 o7,i2.part7 d7,i.part8 o8,i2.part8 d8
from systables t,sysconstraints s,sysindexes i,
sysreferences r,systables tr,sysconstraints s2,sysindexes i2
where t.tabname='%s'
and s.tabid=t.tabid and s.constrtype='R' and r.constrid=s.constrid
and i.idxname=s.idxname and tr.tabid=r.ptabid
and s2.constrid=r.primary and i2.idxname=s2.idxname",
);
}
\ No newline at end of file
......@@ -417,7 +417,4 @@ class MsSqlSchemaManager extends AbstractSchemaManager
return $this->conn->fetchColumn($query);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -279,7 +279,7 @@ class MySqlSchemaManager extends AbstractSchemaManager
}
$res = $this->_conn->exec($query);
} catch(Doctrine_Connection_Exception $e) {
} catch(Doctrine\DBAL\ConnectionException $e) {
throw \Doctrine\Common\DoctrineException::updateMe('could not create sequence table');
}
......@@ -295,7 +295,7 @@ class MySqlSchemaManager extends AbstractSchemaManager
// Handle error
try {
$res = $this->_conn->exec('DROP TABLE ' . $sequenceName);
} catch(Doctrine_Connection_Exception $e) {
} catch(Doctrine\DBAL\ConnectionException $e) {
throw \Doctrine\Common\DoctrineException::updateMe('could not drop inconsistent sequence table');
}
......@@ -316,7 +316,4 @@ class MySqlSchemaManager extends AbstractSchemaManager
$name = $this->_conn->quoteIdentifier($name);
return $this->_conn->exec('ALTER TABLE ' . $table . ' DROP FOREIGN KEY ' . $name);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -704,7 +704,4 @@ END;
$query = 'SELECT view_name FROM sys.user_views';
return $this->_conn->fetchColumn($query);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -118,7 +118,7 @@ class PostgreSqlSchemaManager extends AbstractSchemaManager
* @param boolean $check indicates whether the function should just check if the DBMS driver
* can perform the requested table alterations if the value is true or
* actually perform them otherwise.
* @throws Doctrine_Connection_Exception
* @throws Doctrine\DBAL\ConnectionException
* @return boolean
*/
public function alterTable($name, array $changes, $check = false)
......@@ -260,6 +260,4 @@ class PostgreSqlSchemaManager extends AbstractSchemaManager
{
return $this->_conn->fetchColumn($query);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -428,12 +428,12 @@ class SqliteSchemaManager extends AbstractSchemaManager
try {
$this->_conn->exec('INSERT INTO ' . $sequenceName . ' (' . $seqcolName . ') VALUES (' . ($start-1) . ')');
return true;
} catch(Doctrine_Connection_Exception $e) {
} catch(Doctrine\DBAL\ConnectionException $e) {
// Handle error
try {
$result = $db->exec('DROP TABLE ' . $sequenceName);
} catch(Doctrine_Connection_Exception $e) {
} catch(Doctrine\DBAL\ConnectionException $e) {
throw \Doctrine\Common\DoctrineException::updateMe('could not drop inconsistent sequence table');
}
}
......@@ -587,5 +587,4 @@ class SqliteSchemaManager extends AbstractSchemaManager
$name = $this->_conn->quoteIdentifier($name, true);
return $name . ' ' . $type . $unsigned . $default . $notnull . $autoinc;
}
}
}
\ No newline at end of file
......@@ -125,9 +125,9 @@ class Statement
/**
* Binds a PHP variable to a corresponding named or question mark placeholder in the
* SQL statement that was use to prepare the statement. Unlike Doctrine_Adapter_Statement_Interface->bindValue(),
* SQL statement that was use to prepare the statement. Unlike PDOStatement->bindValue(),
* the variable is bound as a reference and will only be evaluated at the time
* that Doctrine_Adapter_Statement_Interface->execute() is called.
* that PDOStatement->execute() is called.
*
* Most parameters are input parameters, that is, parameters that are
* used in a read-only fashion to build up the query. Some drivers support the invocation
......@@ -172,7 +172,7 @@ class Statement
* Returns the number of columns in the result set
*
* @return integer Returns the number of columns in the result set represented
* by the Doctrine_Adapter_Statement_Interface object. If there is no result set,
* by the PDOStatement object. If there is no result set,
* this method should return 0.
*/
public function columnCount()
......@@ -250,18 +250,18 @@ class Statement
* this value determines which row will be returned to the caller.
* This value must be one of the Query::HYDRATE_ORI_* constants, defaulting to
* Query::HYDRATE_ORI_NEXT. To request a scrollable cursor for your
* Doctrine_Adapter_Statement_Interface object,
* PDOStatement object,
* you must set the PDO::ATTR_CURSOR attribute to Doctrine::CURSOR_SCROLL when you
* prepare the SQL statement with Doctrine_Adapter_Interface->prepare().
*
* @param integer $cursorOffset For a Doctrine_Adapter_Statement_Interface object representing a scrollable cursor for which the
* @param integer $cursorOffset For a PDOStatement object representing a scrollable cursor for which the
* $cursorOrientation parameter is set to Query::HYDRATE_ORI_ABS, this value specifies
* the absolute number of the row in the result set that shall be fetched.
*
* For a Doctrine_Adapter_Statement_Interface object representing a scrollable cursor for
* For a PDOStatement object representing a scrollable cursor for
* which the $cursorOrientation parameter is set to Query::HYDRATE_ORI_REL, this value
* specifies the row to fetch relative to the cursor position before
* Doctrine_Adapter_Statement_Interface->fetch() was called.
* PDOStatement->fetch() was called.
*
* @return mixed
*/
......@@ -323,7 +323,7 @@ class Statement
* result set or FALSE if there are no more rows.
*
* @param integer $columnIndex 0-indexed number of the column you wish to retrieve from the row. If no
* value is supplied, Doctrine_Adapter_Statement_Interface->fetchColumn()
* value is supplied, PDOStatement->fetchColumn()
* fetches the first column.
*
* @return string returns a single column in the next row of a result set.
......@@ -337,7 +337,7 @@ class Statement
* Fetches the next row and returns it as an object.
*
* Fetches the next row and returns it as an object. This function is an alternative to
* Doctrine_Adapter_Statement_Interface->fetch() with Query::HYDRATE_CLASS or Query::HYDRATE_OBJ style.
* PDOStatement->fetch() with Query::HYDRATE_CLASS or Query::HYDRATE_OBJ style.
*
* @param string $className Name of the created class, defaults to stdClass.
* @param array $args Elements of this array are passed to the constructor.
......@@ -435,4 +435,4 @@ class Statement
{
return $this->_stmt->setFetchMode($mode, $arg1, $arg2);
}
}
}
\ No newline at end of file
......@@ -9,11 +9,8 @@ namespace Doctrine\DBAL\Types;
*/
class ArrayType extends Type
{
public function getName()
{
return 'Array';
}
}
}
\ No newline at end of file
......@@ -10,5 +10,4 @@ namespace Doctrine\DBAL\Types;
class BigIntType extends Type
{
//put your code here
}
}
\ No newline at end of file
......@@ -30,5 +30,4 @@ class BooleanType extends Type
{
return (bool)$value;
}
}
}
\ No newline at end of file
......@@ -10,5 +10,4 @@ namespace Doctrine\DBAL\Types;
class CharType
{
//put your code here
}
}
\ No newline at end of file
......@@ -32,6 +32,4 @@ class DateTimeType extends Type
{
return new DateTime($value);
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -9,5 +9,4 @@ namespace Doctrine\DBAL\Types;
class DecimalType extends Type
{
}
}
\ No newline at end of file
......@@ -8,7 +8,6 @@ namespace Doctrine\DBAL\Types;
*/
class IntegerType extends Type
{
public function getName()
{
return "Integer";
......
......@@ -10,5 +10,4 @@ namespace Doctrine\DBAL\Types;
class MediumIntType
{
//put your code here
}
}
\ No newline at end of file
......@@ -10,5 +10,4 @@ namespace Doctrine\DBAL\Types;
class SmallIntType
{
//put your code here
}
}
\ No newline at end of file
......@@ -14,6 +14,4 @@ class TextType extends Type
{
return $platform->getClobDeclarationSql($fieldDeclaration);
}
}
}
\ No newline at end of file
......@@ -10,5 +10,4 @@ namespace Doctrine\DBAL\Types;
class TinyIntType
{
//put your code here
}
}
\ No newline at end of file
......@@ -2,7 +2,7 @@
namespace Doctrine\DBAL\Types;
#use Doctrine\DBAL\Platforms\AbstractDatabasePlatform;
use Doctrine\DBAL\Platforms\AbstractPlatform;
abstract class Type
{
......@@ -90,5 +90,4 @@ abstract class Type
}
self::$_typesMap[$name] = $className;
}
}
}
\ No newline at end of file
......@@ -22,6 +22,8 @@ class VarcharType extends Type
}
/** @override */
public function getName() { return 'Varchar'; }
}
public function getName()
{
return 'Varchar';
}
}
\ No newline at end of file
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
#namespace Doctrine::ORM::Exceptions;
/**
* Doctrine_Exception
*
* @package Doctrine
* @subpackage Exception
* @license http://www.opensource.org/licenses/lgpl-license.php LGPL
* @link www.phpdoctrine.org
* @since 1.0
* @version $Revision$
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
* @author Roman Borschel <roman@code-factory.org>
* @todo Rename to DoctrineException
*/
class Doctrine_Exception extends Exception
{
private $_innerException;
public function __construct($message = "", Doctrine_Exception $innerException = null)
{
parent::__construct($message);
$this->_innerException = $innerException;
}
public function getInnerException()
{
return $this->_innerException;
}
public static function notYetImplemented($method, $class)
{
return new self("The method '$method' is not implemented in the class '$class'.");
}
}
......@@ -74,4 +74,4 @@ class ApcCache implements Cache
{
return apc_delete($id);
}
}
}
\ No newline at end of file
......@@ -89,4 +89,4 @@ class ArrayCache implements Cache
{
return count($this->data);
}
}
}
\ No newline at end of file
......@@ -68,4 +68,4 @@ interface Cache
* @return boolean true if no problem
*/
public function delete($id);
}
}
\ No newline at end of file
......@@ -178,4 +178,4 @@ class DbCache implements Cache, \Countable
$this->getConnection()->export->createTable($name, $fields, $options);
}
}
}
\ No newline at end of file
......@@ -98,4 +98,4 @@ class MemcacheCache implements Cache
{
return $this->_memcache->delete($id);
}
}
}
\ No newline at end of file
......@@ -37,6 +37,4 @@ final class Events
const postDelete = 'postDelete';
const preSave = 'preSave';
const postSave = 'postSave';
}
}
\ No newline at end of file
......@@ -31,8 +31,8 @@ abstract class AbstractIdGenerator
*
* @return boolean
*/
public function isPostInsertGenerator() {
public function isPostInsertGenerator()
{
return false;
}
}
}
\ No newline at end of file
......@@ -66,5 +66,4 @@ class Assigned extends AbstractIdGenerator
return $identifier;
}
}
}
\ No newline at end of file
......@@ -20,8 +20,8 @@ class IdentityGenerator extends AbstractIdGenerator
* @return boolean
* @override
*/
public function isPostInsertGenerator() {
public function isPostInsertGenerator()
{
return true;
}
}
}
\ No newline at end of file
......@@ -23,5 +23,4 @@ class SequenceGenerator extends AbstractIdGenerator
$sql = $conn->getDatabasePlatform()->getSequenceNextValSql($this->_sequenceName);
return $conn->fetchOne($sql);
}
}
}
\ No newline at end of file
......@@ -21,6 +21,4 @@ class SequenceIdentityGenerator extends IdentityGenerator
{
return $this->_em->getConnection()->lastInsertId($this->_sequenceName);
}
}
}
\ No newline at end of file
......@@ -9,11 +9,8 @@ namespace Doctrine\ORM\Id;
*/
class TableGenerator extends AbstractIdGenerator
{
public function generate($entity)
{
throw \Doctrine\Common\DoctrineException::updateMe("Not implemented");
}
}
}
\ No newline at end of file
<?php
/*
* $Id: Exception.php 3882 2008-02-22 18:11:35Z jwage $
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
/**
* class Doctrine_Import_Exception
*
* @package Doctrine
* @subpackage Import
* @link www.phpdoctrine.org
* @license http://www.opensource.org/licenses/lgpl-license.php LGPL
* @since 1.0
* @version $Revision: 3882 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
*/
class Doctrine_Import_Exception extends Doctrine_Exception
{ }
\ No newline at end of file
......@@ -19,6 +19,8 @@
* <http://www.phpdoctrine.org>.
*/
namespace Doctrine\ORM\Import\Reader;
/**
* class Doctrine_Import_Reader
* Is responsible of reading a database definitions from a source and costructing a
......@@ -32,21 +34,7 @@
* @version $Revision: 3882 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
*/
abstract class Doctrine_Import_Reader
abstract class AbstractRader
{
/** Aggregations: */
/** Compositions: */
/*** Attributes: ***/
/**
*
* @return Doctrine_Schema
* @abstract
* @access public
*/
abstract public function read( );
abstract public function read();
}
\ No newline at end of file
......@@ -19,6 +19,8 @@
* <http://www.phpdoctrine.org>.
*/
namespace Doctrine\ORM\Import\Reader;
/**
* class Doctrine_Import_Reader_Db
* Reads a database using the given PDO connection and constructs a database
......@@ -32,14 +34,8 @@
* @version $Revision: 3882 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
*/
class Doctrine_Import_Reader_Db extends Doctrine_Import_Reader
class Db extends AbstractReader
{
/** Aggregations: */
/** Compositions: */
/*** Attributes: ***/
/**
* @access private
*/
......
<?php
/*
* $Id: Exception.php 3882 2008-02-22 18:11:35Z jwage $
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
/**
* class Doctrine_Import_Reader_Exception
*
* @package Doctrine
* @subpackage Import
* @link www.phpdoctrine.org
* @license http://www.opensource.org/licenses/lgpl-license.php LGPL
* @since 1.0
* @version $Revision: 3882 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
*/
class Doctrine_Import_Reader_Exception
{
/** Aggregations: */
/** Compositions: */
/*** Attributes: ***/
}
\ No newline at end of file
......@@ -18,7 +18,9 @@
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
Doctrine::autoload('Doctrine_Import_Reader');
namespace Doctrine\ORM\Import\Reader;
/**
* class Doctrine_Import_Reader_Xml_Propel
*
......@@ -30,15 +32,8 @@ Doctrine::autoload('Doctrine_Import_Reader');
* @version $Revision: 3882 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
*/
class Doctrine_Import_Reader_Xml_Propel extends Doctrine_Import_Reader
class Propel extends AbstractReader
{
/** Aggregations: */
/** Compositions: */
/*** Attributes: ***/
/**
* @access private
*/
......
......@@ -145,6 +145,4 @@ class CommitOrderCalculator
{
array_unshift($this->_sorted, $node->getClass());
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -161,5 +161,4 @@ class CommitOrderNode
{
$this->_relatedNodes[] = $node;
}
}
}
\ No newline at end of file
......@@ -362,4 +362,4 @@ abstract class AbstractHydrator
{
$this->_isResultMixed = $bool;
}
}
}
\ No newline at end of file
......@@ -208,5 +208,4 @@ class ArrayHydrator extends AbstractHydrator
{
return array();
}
}
}
\ No newline at end of file
<?php
/*
* $Id: Exception.php 1080 2007-02-10 18:17:08Z romanb $
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
/**
* Doctrine_Hydrator_Exception
*
* @package Doctrine
* @subpackage Hydrate
* @license http://www.opensource.org/licenses/lgpl-license.php LGPL
* @link www.phpdoctrine.org
* @since 1.0
* @version $Revision: 1080 $
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
*/
class Doctrine_Hydrator_Exception extends Doctrine_Exception
{
public static function nonUniqueKeyMapping()
{
return new self("Hydration failed. Found non-unique key mapping.");
}
public static function nonExistantFieldUsedAsIndex($field)
{
return new self("Hydration failed. Found a non-existent field '$field'.");
}
public static function nonUniqueResult()
{
return new self("Hydration failed. Non-unique result returned.");
}
}
\ No newline at end of file
......@@ -4,11 +4,8 @@ namespace Doctrine\ORM\Internal\Hydration;
class HydrationException extends \Doctrine\Common\DoctrineException
{
public static function nonUniqueResult()
{
return new self("The result returned by the query was not unique.");
}
}
}
\ No newline at end of file
......@@ -46,5 +46,4 @@ class IterableResult
{
return $this->_hydrator->hydrateRow();
}
}
}
\ No newline at end of file
......@@ -395,5 +395,4 @@ class ObjectHydrator extends AbstractHydrator
{
return new \Doctrine\Common\Collections\Collection;
}
}
}
\ No newline at end of file
......@@ -36,5 +36,4 @@ class ScalarHydrator extends AbstractHydrator
{
return array();
}
}
}
\ No newline at end of file
......@@ -33,5 +33,4 @@ class SingleScalarHydrator extends AbstractHydrator
{
return array();
}
}
}
\ No newline at end of file
......@@ -339,5 +339,4 @@ abstract class AssociationMapping
}
abstract public function lazyLoadFor($entity, $entityManager);
}
}
\ No newline at end of file
......@@ -1476,5 +1476,4 @@ final class ClassMetadata
{
return __CLASS__ . '@' . spl_object_hash($this);
}
}
}
\ No newline at end of file
......@@ -205,7 +205,4 @@ class ClassMetadataFactory
}
}
}
}
}
\ No newline at end of file
......@@ -173,4 +173,4 @@ class AnnotationDriver
return strpos($docComment, '@DoctrineEntity') === false &&
strpos($docComment, '@DoctrineMappedSuperclass') === false;
}
}
}
\ No newline at end of file
......@@ -83,4 +83,4 @@ final class DoctrineJoinTable extends \Addendum\Annotation {
public $schema;
public $joinColumns;
public $inverseJoinColumns;
}
}
\ No newline at end of file
......@@ -141,5 +141,4 @@ class ManyToManyMapping extends AssociationMapping
{
return true;
}
}
}
\ No newline at end of file
......@@ -83,6 +83,4 @@ class MappingException extends \Doctrine\Common\DoctrineException
{
return new self("The mapping of field '$fieldName' is invalid.");
}
}
?>
\ No newline at end of file
}
\ No newline at end of file
......@@ -112,6 +112,4 @@ class OneToManyMapping extends AssociationMapping
{
}
}
}
\ No newline at end of file
......@@ -163,6 +163,4 @@ class OneToOneMapping extends AssociationMapping
}
$sourceClass->getReflectionProperty($this->_sourceFieldName)->setValue($entity, $otherEntity);
}
}
}
\ No newline at end of file
......@@ -395,4 +395,4 @@ final class PersistentCollection extends \Doctrine\Common\Collections\Collection
{
$this->_isDirty = $dirty;
}
}
}
\ No newline at end of file
......@@ -160,5 +160,4 @@ abstract class AbstractCollectionPersister
* @param mixed $element
*/
abstract protected function _getInsertRowSqlParameters(PersistentCollection $coll, $element);
}
}
\ No newline at end of file
......@@ -237,4 +237,4 @@ abstract class AbstractEntityPersister
$result[$discColumn['name']] = array_search($this->_entityName, $discMap);
}
}
}
}
\ No newline at end of file
......@@ -29,5 +29,4 @@ namespace Doctrine\ORM\Persisters;
class ElementCollectionPersister extends AbstractCollectionPersister
{
//put your code here
}
}
\ No newline at end of file
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the LGPL. For more information, see
* <http://www.phpdoctrine.org>.
*/
#namespace Doctrine::ORM;
/**
* Doctrine_EntityPersister_Exception
*
* @package Doctrine
* @subpackage Entity
* @author Konsta Vesterinen <kvesteri@cc.hut.fi>
* @author Roman Borschel <roman@code-factory.org>
* @license http://www.opensource.org/licenses/lgpl-license.php LGPL
* @link www.phpdoctrine.org
* @since 2.0
* @version $Revision$
*/
class Doctrine_EntityPersister_Exception extends Doctrine_Exception
{
}
\ No newline at end of file
......@@ -277,5 +277,4 @@ class JoinedSubclassPersister extends AbstractEntityPersister
return $dataSet;
}
}
}
\ No newline at end of file
......@@ -126,5 +126,4 @@ class ManyToManyPersister extends AbstractCollectionPersister
// rely on a specific ordering of the columns.
return $this->_uow->getEntityIdentifier($coll->getOwner());
}
}
}
\ No newline at end of file
......@@ -73,6 +73,4 @@ class OneToManyPersister extends AbstractCollectionPersister
{
return;
}
}
}
\ No newline at end of file
<?php
?>
\ No newline at end of file
namespace Doctrine\ORM\Persisters;
class SingleTablePersister extends AbstractEntityPersister
{
}
\ No newline at end of file
<?php
?>
\ No newline at end of file
namespace Doctrine\ORM\Persisters;
class UnionSubclassPersister extends AbstractEntityPersister
{
}
\ No newline at end of file
......@@ -587,4 +587,4 @@ class Query extends AbstractQuery
$this->_execute($params, $hydrationMode), $this->_parserResult
);
}
}
}
\ No newline at end of file
......@@ -38,5 +38,4 @@ class AggregateExpression extends Node
{
return $this->_functionName;
}
}
}
\ No newline at end of file
......@@ -18,13 +18,17 @@ class ArithmeticExpression extends Node
public function setSimpleArithmeticExpression($simpleArithmeticExpr)
{
if ($this->_subselect) throw \Doctrine\Common\DoctrineException::updateMe();
if ($this->_subselect) {
throw \Doctrine\Common\DoctrineException::updateMe();
}
$this->_simpleArithmeticExpression = $simpleArithmeticExpr;
}
public function setSubselect($subselect)
{
if ($this->_simpleArithmeticExpression) throw \Doctrine\Common\DoctrineException::updateMe();
if ($this->_simpleArithmeticExpression){
throw \Doctrine\Common\DoctrineException::updateMe();
}
$this->_subselect = $subselect;
}
......@@ -40,12 +44,11 @@ class ArithmeticExpression extends Node
public function isSimpleArithmeticExpression()
{
return (bool)$this->_simpleArithmeticExpression;
return (bool) $this->_simpleArithmeticExpression;
}
public function isSubselect()
{
return (bool)$this->_subselect;
return (bool) $this->_subselect;
}
}
}
\ No newline at end of file
......@@ -38,5 +38,4 @@ class ArithmeticFactor extends Node
{
return $this->_nSigned;
}
}
}
\ No newline at end of file
......@@ -24,5 +24,4 @@ class ArithmeticTerm extends Node
{
return $this->_factors;
}
}
}
\ No newline at end of file
......@@ -43,5 +43,4 @@ class ComparisonExpression extends Node
{
return $this->_operator;
}
}
}
\ No newline at end of file
......@@ -35,5 +35,4 @@ namespace Doctrine\ORM\Query\AST;
*/
class ComparisonOperator extends Node
{
}
}
\ No newline at end of file
......@@ -24,5 +24,4 @@ class ConditionalExpression extends Node
{
return $this->_conditionalTerms;
}
}
}
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment