1
0
mirror of synced 2024-12-05 03:06:05 +03:00

CS/Typo Fixes

This commit is contained in:
fabios 2013-12-16 15:55:54 -05:00
parent 0a66a2bc09
commit 4e0e1b8061
15 changed files with 28 additions and 27 deletions

View File

@ -102,7 +102,7 @@ class DefaultCacheFactory implements CacheFactory
*/
public function setRegion(Region $region)
{
$this->regions[$region->getName()] = $region;
$this->regions[$region->getName()] = $region;
}
/**
@ -110,7 +110,7 @@ class DefaultCacheFactory implements CacheFactory
*/
public function setTimestampRegion(TimestampRegion $region)
{
$this->timestampRegion = $region;
$this->timestampRegion = $region;
}
/**

View File

@ -94,7 +94,7 @@ class DefaultEntityHydrator implements EntityHydrator
: $data[$name];
// @TODO - fix it !
// hande UnitOfWork#createEntity hash generation
// handle UnitOfWork#createEntity hash generation
if ( ! is_array($targetId)) {
$data[reset($assoc['joinColumnFieldNames'])] = $targetId;

View File

@ -90,10 +90,10 @@ abstract class AbstractCollectionPersister implements CachedCollectionPersister
protected $cacheLogger;
/**
* @param \Doctrine\ORM\Persisters\CollectionPersister $persister The collection persister that will be cached.
* @param \Doctrine\ORM\Cache\Region $region The collection region.
* @param \Doctrine\ORM\EntityManagerInterface $em The entity manager.
* @param array $mapping The association mapping.
* @param \Doctrine\ORM\Persisters\CollectionPersister $persister The collection persister that will be cached.
* @param \Doctrine\ORM\Cache\Region $region The collection region.
* @param \Doctrine\ORM\EntityManagerInterface $em The entity manager.
* @param array $association The association mapping.
*/
public function __construct(CollectionPersister $persister, Region $region, EntityManagerInterface $em, array $association)
{

View File

@ -85,7 +85,7 @@ class NonStrictReadWriteCachedCollectionPersister extends AbstractCollectionPers
$ownerId = $this->uow->getEntityIdentifier($collection->getOwner());
$key = new CollectionCacheKey($this->sourceEntity->rootEntityName, $this->association['fieldName'], $ownerId);
// Invalidate non initialized collections OR odered collection
// Invalidate non initialized collections OR ordered collection
if ($isDirty && ! $isInitialized || isset($this->association['orderBy'])) {
$this->persister->update($collection);

View File

@ -34,10 +34,10 @@ use Doctrine\ORM\PersistentCollection;
class ReadWriteCachedCollectionPersister extends AbstractCollectionPersister
{
/**
* @param \Doctrine\ORM\Persisters\CollectionPersister $persister The collection persister that will be cached.
* @param \Doctrine\ORM\Cache\ConcurrentRegion $region The collection region.
* @param \Doctrine\ORM\EntityManagerInterface $em The entity manager.
* @param array $mapping The association mapping.
* @param \Doctrine\ORM\Persisters\CollectionPersister $persister The collection persister that will be cached.
* @param \Doctrine\ORM\Cache\ConcurrentRegion $region The collection region.
* @param \Doctrine\ORM\EntityManagerInterface $em The entity manager.
* @param array $association The association mapping.
*/
public function __construct(CollectionPersister $persister, ConcurrentRegion $region, EntityManagerInterface $em, array $association)
{

View File

@ -51,7 +51,7 @@ interface QueryCache
* @param \Doctrine\ORM\Query\ResultSetMapping $rsm
* @param array $hints
*
* @return void
* @return array|null
*/
public function get(QueryCacheKey $key, ResultSetMapping $rsm, array $hints = array());

View File

@ -33,7 +33,7 @@ interface QueryCacheValidator
/**
* Checks if the query entry is valid
*
* @param \Doctrine\ORM\Cache\QueryCacheEntry $key
* @param \Doctrine\ORM\Cache\QueryCacheKey $key
* @param \Doctrine\ORM\Cache\QueryCacheEntry $entry
*
* @return boolean

View File

@ -29,8 +29,8 @@ use Doctrine\ORM\Cache\ConcurrentRegion;
/**
* Very naive concurrent region, based on file locks.
*
* since 2.5
* author Fabio B. Silva <fabio.bat.silvagmail.com>
* @since 2.5
* @author Fabio B. Silva <fabio.bat.silvagmail.com>
*/
class FileLockRegion implements ConcurrentRegion
{
@ -42,7 +42,7 @@ class FileLockRegion implements ConcurrentRegion
private $region;
/**
* var string
* @var string
*/
private $directory;
@ -74,8 +74,8 @@ class FileLockRegion implements ConcurrentRegion
}
/**
* param \Doctrine\ORM\Cache\CacheKey $key
* param \Doctrine\ORM\Cache\Lock $lock
* @param \Doctrine\ORM\Cache\CacheKey $key
* @param \Doctrine\ORM\Cache\Lock $lock
*
* @return boolean
*/

View File

@ -31,7 +31,7 @@ use Doctrine\ORM\Query\ResultSetMapping;
interface EntityManagerInterface extends ObjectManager
{
/**
* Returns the cache API for managing the second level cache regions or NULL if the cache is not anabled.
* Returns the cache API for managing the second level cache regions or NULL if the cache is not enabled.
*
* @return \Doctrine\ORM\Cache|null
*/

View File

@ -1021,7 +1021,8 @@ class ClassMetadataInfo implements ClassMetadata
}
/**
* @param array $cache
* @param string $fieldName
* @param array $cache
*
* @return void
*/

View File

@ -44,7 +44,7 @@ class DefaultCacheFactoryTest extends OrmTestCase
), $arguments);
}
public function testInplementsCacheFactory()
public function testImplementsCacheFactory()
{
$this->assertInstanceOf('Doctrine\ORM\Cache\CacheFactory', $this->factory);
}

View File

@ -245,7 +245,7 @@ class DefaultCacheTest extends OrmTestCase
$this->assertSame($fooQueryCache, $this->cache->getQueryCache('foo'));
}
public function testToIdentifierArrayShoudLookupForEntityIdentifier()
public function testToIdentifierArrayShouldLookupForEntityIdentifier()
{
$identifier = 123;
$entity = new Country('Foo');

View File

@ -216,7 +216,7 @@ class DefaultQueryCacheTest extends OrmTestCase
$this->assertCount(13, $this->region->calls['put']);
}
public function testgGetBasicQueryResult()
public function testGetBasicQueryResult()
{
$rsm = new ResultSetMappingBuilder($this->em);
$key = new QueryCacheKey('query.key1', 0);
@ -480,7 +480,7 @@ class DefaultQueryCacheTest extends OrmTestCase
* @expectedException Doctrine\ORM\Cache\CacheException
* @expectedExceptionMessage Second level cache does not support multiple root entities.
*/
public function testSuportMultipleRootEntitiesException()
public function testSupportMultipleRootEntitiesException()
{
$result = array();
$key = new QueryCacheKey('query.key1', 0);

View File

@ -199,7 +199,7 @@ abstract class AbstractCollectionPersisterTest extends OrmTestCase
$this->assertEquals(0, $persister->count($collection));
}
public function testInvokEslice()
public function testInvokeSlice()
{
$entity = new State("Foo");
$persister = $this->createPersisterDefault();

View File

@ -153,7 +153,7 @@ class ReadWriteCachedEntityPersisterTest extends AbstractEntityPersisterTest
$this->assertCount(0, $property->getValue($persister));
}
public function testTransactionlCommitShouldClearQueue()
public function testTransactionCommitShouldClearQueue()
{
$entity = new Country("Foo");
$lock = Lock::createLockRead();