Commit 32b1a4f8 authored by Steve Müller's avatar Steve Müller

Merge pull request #841 from BenMorel/docfix

Documentation & code styling fixes
parents 41e718ea 91f1b30a
......@@ -1104,7 +1104,7 @@ class Connection implements DriverConnection
$func($this);
$this->commit();
} catch (Exception $e) {
$this->rollback();
$this->rollBack();
throw $e;
}
}
......@@ -1268,7 +1268,7 @@ class Connection implements DriverConnection
$logger->startQuery('"ROLLBACK"');
}
$this->_transactionNestingLevel = 0;
$this->_conn->rollback();
$this->_conn->rollBack();
$this->_isRollbackOnly = false;
if ($logger) {
$logger->stopQuery();
......
......@@ -29,7 +29,7 @@ use Doctrine\DBAL\Driver\PDOConnection;
class Connection extends PDOConnection implements \Doctrine\DBAL\Driver\Connection
{
/**
* @override
* {@inheritDoc}
*/
public function quote($value, $type=\PDO::PARAM_STR)
{
......
......@@ -218,9 +218,10 @@ final class DriverManager
*
* @param array $params The list of parameters.
*
* @param array A modified list of parameters with info from a database
* @return array A modified list of parameters with info from a database
* URL extracted into indidivual parameter parts.
*
* @throws DBALException
*/
private static function parseDatabaseUrl(array $params)
{
......
......@@ -156,7 +156,7 @@ class TableGenerator
$this->conn->commit();
} catch (\Exception $e) {
$this->conn->rollback();
$this->conn->rollBack();
throw new \Doctrine\DBAL\DBALException("Error occurred while generating ID with TableGenerator, aborted generation: " . $e->getMessage(), 0, $e);
}
......
......@@ -20,7 +20,6 @@
namespace Doctrine\DBAL\Platforms;
use Doctrine\DBAL\DBALException;
use Doctrine\DBAL\Schema\Column;
use Doctrine\DBAL\Schema\ColumnDiff;
use Doctrine\DBAL\Schema\Identifier;
use Doctrine\DBAL\Schema\Index;
......
......@@ -49,6 +49,12 @@ class MySqlPlatform extends AbstractPlatform
/**
* Adds MySQL-specific LIMIT clause to the query
* 18446744073709551615 is 2^64-1 maximum of unsigned BIGINT the biggest limit possible
*
* @param string $query
* @param integer $limit
* @param integer $offset
*
* @return string
*/
protected function doModifyLimitQuery($query, $limit, $offset)
{
......@@ -346,6 +352,9 @@ class MySqlPlatform extends AbstractPlatform
return true;
}
/**
* {@inheritDoc}
*/
public function getListTablesSQL()
{
return "SHOW FULL TABLES WHERE Table_type = 'BASE TABLE'";
......
......@@ -517,7 +517,7 @@ class PostgreSqlPlatform extends AbstractPlatform
}
if ($columnDiff->hasChanged('notnull')) {
$query = 'ALTER ' . $oldColumnName . ' ' . ($column->getNotNull() ? 'SET' : 'DROP') . ' NOT NULL';
$query = 'ALTER ' . $oldColumnName . ' ' . ($column->getNotnull() ? 'SET' : 'DROP') . ' NOT NULL';
$sql[] = 'ALTER TABLE ' . $diff->getName($this)->getQuotedName($this) . ' ' . $query;
}
......
......@@ -1302,6 +1302,8 @@ class QueryBuilder
* @param array $knownAliases
*
* @return string
*
* @throws QueryException
*/
private function getSQLForJoins($fromAlias, array &$knownAliases)
{
......
......@@ -313,6 +313,8 @@ class Schema extends AbstractAsset
* @param string $namespaceName The name of the namespace to create.
*
* @return \Doctrine\DBAL\Schema\Schema This schema instance.
*
* @throws SchemaException
*/
public function createNamespace($namespaceName)
{
......
......@@ -418,6 +418,12 @@ class SqliteSchemaManager extends AbstractSchemaManager
return $tableDiff;
}
/**
* @param string $column
* @param string $sql
*
* @return string|false
*/
private function parseColumnCollationFromSQL($column, $sql)
{
if (preg_match(
......
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