1
0
mirror of synced 2025-01-18 22:41:43 +03:00

Merge pull request #362 from odolbeau/cs

Correct some mistakes (tabs & trailing spaces)
This commit is contained in:
Guilherme Blanco 2012-06-14 22:43:18 -07:00
commit 27b4f58b66
9 changed files with 9 additions and 15 deletions

View File

@ -81,7 +81,7 @@ class PreUpdateEventArgs extends LifecycleEventArgs
*/
public function getOldValue($field)
{
$this->assertValidField($field);
$this->assertValidField($field);
return $this->entityChangeSet[$field][0];
}
@ -119,7 +119,7 @@ class PreUpdateEventArgs extends LifecycleEventArgs
*/
private function assertValidField($field)
{
if ( ! isset($this->entityChangeSet[$field])) {
if ( ! isset($this->entityChangeSet[$field])) {
throw new \InvalidArgumentException(sprintf(
'Field "%s" is not a valid field of the entity "%s" in PreUpdateEventArgs.',
$field,

View File

@ -20,7 +20,6 @@
namespace Doctrine\ORM\Id;
use Doctrine\ORM\EntityManager;
use Doctrine\ORM\Mapping\ClassMetadata;
use Doctrine\ORM\ORMException;
/**

View File

@ -111,7 +111,7 @@ class ArrayHydrator extends AbstractHydrator
// Get a reference to the right element in the result tree.
// This element will get the associated element attached.
if ($this->_rsm->isMixed && isset($this->_rootAliases[$parent])) {
$first = reset($this->_resultPointers);
$first = reset($this->_resultPointers);
// TODO: Exception if $key === null ?
$baseElement =& $this->_resultPointers[$parent][key($first)];
} else if (isset($this->_resultPointers[$parent])) {

View File

@ -19,8 +19,6 @@
namespace Doctrine\ORM\Internal\Hydration;
use Doctrine\DBAL\Connection;
/**
* Hydrator that produces flat, rectangular results of scalar data.
* The created result is almost the same as a regular SQL result set, except

View File

@ -347,8 +347,8 @@ final class Query extends AbstractQuery
/**
* Returns the cache driver used for query caching.
*
* @return CacheDriver The cache driver used for query caching or NULL, if this
* Query does not use query caching.
* @return CacheDriver The cache driver used for query caching or NULL, if
* this Query does not use query caching.
*/
public function getQueryCacheDriver()
{

View File

@ -19,9 +19,7 @@
namespace Doctrine\ORM\Query\AST\Functions;
use Doctrine\ORM\Query\Lexer;
use Doctrine\ORM\Query\SqlWalker;
use Doctrine\ORM\Query\Parser;
use Doctrine\ORM\Query\QueryException;
/**

View File

@ -1852,7 +1852,7 @@ class SqlWalker implements TreeWalker
$dqlAlias = $instanceOfExpr->identificationVariable;
$discrClass = $class = $this->_queryComponents[$dqlAlias]['metadata'];
if ($class->discriminatorColumn) {
$discrClass = $this->_em->getClassMetadata($class->rootEntityName);
}
@ -2046,8 +2046,8 @@ class SqlWalker implements TreeWalker
public function walkArithmeticExpression($arithmeticExpr)
{
return ($arithmeticExpr->isSimpleArithmeticExpression())
? $this->walkSimpleArithmeticExpression($arithmeticExpr->simpleArithmeticExpression)
: '(' . $this->walkSubselect($arithmeticExpr->subselect) . ')';
? $this->walkSimpleArithmeticExpression($arithmeticExpr->simpleArithmeticExpression)
: '(' . $this->walkSubselect($arithmeticExpr->subselect) . ')';
}
/**

View File

@ -20,7 +20,6 @@
namespace Doctrine\ORM\Tools\Console\Command;
use Doctrine\ORM\Mapping\MappingException;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Command\Command;

View File

@ -104,7 +104,7 @@ class LimitSubqueryWalker extends TreeWalkerAdapter
$pathExpression->type = PathExpression::TYPE_STATE_FIELD;
$AST->selectClause->selectExpressions[] = new SelectExpression(
$pathExpression,
'_dctrn_ord' . $this->_aliasCounter++
'_dctrn_ord' . $this->_aliasCounter++
);
}
}