@@ -250,7 +250,7 @@ |
||
250 | 250 | /** |
251 | 251 | * @param string $name |
252 | 252 | * @param string $className |
253 | - * @param array $options |
|
253 | + * @param string $options |
|
254 | 254 | */ |
255 | 255 | public function addDesignDocument($name, $className, $options) |
256 | 256 | { |
@@ -2,18 +2,13 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB; |
4 | 4 | |
5 | -use Doctrine\Common\Cache\Cache; |
|
6 | -use Doctrine\Common\Persistence\Mapping\Driver\MappingDriver; |
|
7 | - |
|
8 | -use Doctrine\CouchDB\HTTP\Client; |
|
9 | -use Doctrine\CouchDB\HTTP\SocketClient; |
|
10 | -use Doctrine\CouchDB\HTTP\LoggingClient; |
|
11 | - |
|
12 | -use Doctrine\ODM\CouchDB\Mapping\MetadataResolver\MetadataResolver; |
|
13 | -use Doctrine\ODM\CouchDB\Mapping\MetadataResolver\DoctrineResolver; |
|
14 | -use Doctrine\ODM\CouchDB\Migrations\DocumentMigration; |
|
15 | -use Doctrine\ODM\CouchDB\Proxy\ProxyFactory; |
|
16 | -use ProxyManager\Configuration as ProxyManagerConfiguration; |
|
5 | +use Doctrine\Common\Cache\Cache; |
|
6 | +use Doctrine\Common\Persistence\Mapping\Driver\MappingDriver; |
|
7 | +use Doctrine\ODM\CouchDB\Mapping\MetadataResolver\MetadataResolver; |
|
8 | +use Doctrine\ODM\CouchDB\Mapping\MetadataResolver\DoctrineResolver; |
|
9 | +use Doctrine\ODM\CouchDB\Migrations\DocumentMigration; |
|
10 | +use Doctrine\ODM\CouchDB\Proxy\ProxyFactory; |
|
11 | +use ProxyManager\Configuration as ProxyManagerConfiguration; |
|
17 | 12 | use ProxyManager\Factory\LazyLoadingGhostFactory; |
18 | 13 | |
19 | 14 | /** |
@@ -258,7 +258,7 @@ discard block |
||
258 | 258 | /** |
259 | 259 | * Refresh the given document by querying the CouchDB to get the current state. |
260 | 260 | * |
261 | - * @param object $document |
|
261 | + * @param \ProxyManager\Proxy\GhostObjectInterface $document |
|
262 | 262 | */ |
263 | 263 | public function refresh($document) |
264 | 264 | { |
@@ -303,7 +303,7 @@ discard block |
||
303 | 303 | } |
304 | 304 | |
305 | 305 | /** |
306 | - * @param object $document |
|
306 | + * @param \Doctrine\Tests\Models\CMS\CmsUser $document |
|
307 | 307 | * @return bool |
308 | 308 | */ |
309 | 309 | public function contains($document) |
@@ -2,14 +2,14 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB; |
4 | 4 | |
5 | -use Doctrine\Common\EventManager; |
|
6 | -use Doctrine\Common\Persistence\ObjectManager; |
|
7 | -use Doctrine\CouchDB\CouchDBClient; |
|
8 | -use Doctrine\CouchDB\View; |
|
9 | -use Doctrine\CouchDB\View\Query; |
|
10 | -use Doctrine\ODM\CouchDB\Mapping\ClassMetadataFactory; |
|
11 | -use Doctrine\ODM\CouchDB\View\ODMQuery; |
|
12 | -use Doctrine\ODM\CouchDB\View\ODMLuceneQuery; |
|
5 | +use Doctrine\Common\EventManager; |
|
6 | +use Doctrine\Common\Persistence\ObjectManager; |
|
7 | +use Doctrine\CouchDB\CouchDBClient; |
|
8 | +use Doctrine\CouchDB\View; |
|
9 | +use Doctrine\CouchDB\View\Query; |
|
10 | +use Doctrine\ODM\CouchDB\Mapping\ClassMetadataFactory; |
|
11 | +use Doctrine\ODM\CouchDB\View\ODMQuery; |
|
12 | +use Doctrine\ODM\CouchDB\View\ODMLuceneQuery; |
|
13 | 13 | use Doctrine\ODM\CouchDB\CouchDBException; |
14 | 14 | |
15 | 15 | class DocumentManager implements ObjectManager |
@@ -9,6 +9,9 @@ |
||
9 | 9 | |
10 | 10 | private $documentManager; |
11 | 11 | |
12 | + /** |
|
13 | + * @param \Doctrine\ODM\CouchDB\DocumentManager $documentManager |
|
14 | + */ |
|
12 | 15 | function __construct($document, $documentManager) |
13 | 16 | { |
14 | 17 | $this->document = $document; |
@@ -270,7 +270,7 @@ discard block |
||
270 | 270 | * - reflClass (ReflectionClass) |
271 | 271 | * - reflFields (ReflectionProperty array) |
272 | 272 | * |
273 | - * @return array The names of all the fields that should be serialized. |
|
273 | + * @return string[] The names of all the fields that should be serialized. |
|
274 | 274 | */ |
275 | 275 | public function __sleep() |
276 | 276 | { |
@@ -330,6 +330,7 @@ discard block |
||
330 | 330 | |
331 | 331 | /** |
332 | 332 | * Restores some state that can not be serialized/unserialized. |
333 | + * @param \Doctrine\Common\Persistence\Mapping\RuntimeReflectionService $reflService |
|
333 | 334 | */ |
334 | 335 | public function wakeupReflection($reflService) |
335 | 336 | { |
@@ -518,7 +519,7 @@ discard block |
||
518 | 519 | * Since CouchDB only allows exactly one identifier field this is a proxy |
519 | 520 | * to {@see getIdentifier()} and returns an array. |
520 | 521 | * |
521 | - * @return array |
|
522 | + * @return string[] |
|
522 | 523 | */ |
523 | 524 | public function getIdentifierFieldNames() |
524 | 525 | { |
@@ -2,10 +2,10 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB\Mapping; |
4 | 4 | |
5 | -use Doctrine\Common\Persistence\Mapping\ClassMetadata AS IClassMetadata, |
|
6 | - Doctrine\Instantiator\Instantiator, |
|
7 | - ReflectionClass, |
|
8 | - ReflectionProperty; |
|
5 | +use Doctrine\Common\Persistence\Mapping\ClassMetadata as IClassMetadata; |
|
6 | +use Doctrine\Instantiator\Instantiator; |
|
7 | +use ReflectionClass; |
|
8 | +use ReflectionProperty; |
|
9 | 9 | |
10 | 10 | /** |
11 | 11 | * Metadata class |
@@ -166,7 +166,7 @@ |
||
166 | 166 | * is still not loaded. |
167 | 167 | * |
168 | 168 | * @param string $className The name of the class for which the metadata should get loaded. |
169 | - * @return array |
|
169 | + * @return string[] |
|
170 | 170 | * @throws MappingException |
171 | 171 | */ |
172 | 172 | protected function loadMetadata($className) |
@@ -2,11 +2,11 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB\Mapping; |
4 | 4 | |
5 | -use Doctrine\ODM\CouchDB\DocumentManager, |
|
6 | - Doctrine\Common\Persistence\Mapping\Driver\MappingDriver, |
|
7 | - Doctrine\Common\Persistence\Mapping\ClassMetadata as ClassMetadataInterface, |
|
8 | - Doctrine\Common\Persistence\Mapping\ReflectionService, |
|
9 | - Doctrine\Common\Persistence\Mapping\AbstractClassMetadataFactory; |
|
5 | +use Doctrine\ODM\CouchDB\DocumentManager; |
|
6 | +use Doctrine\Common\Persistence\Mapping\Driver\MappingDriver; |
|
7 | +use Doctrine\Common\Persistence\Mapping\ClassMetadata as ClassMetadataInterface; |
|
8 | +use Doctrine\Common\Persistence\Mapping\ReflectionService; |
|
9 | +use Doctrine\Common\Persistence\Mapping\AbstractClassMetadataFactory; |
|
10 | 10 | |
11 | 11 | /** |
12 | 12 | * The ClassMetadataFactory is used to create ClassMetadata objects that contain all the |
@@ -2,13 +2,10 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB\Mapping\Driver; |
4 | 4 | |
5 | -use Doctrine\Common\Annotations\AnnotationReader, |
|
6 | - Doctrine\Common\Annotations\AnnotationRegistry, |
|
7 | - Doctrine\Common\Annotations\Reader, |
|
8 | - Doctrine\Common\Persistence\Mapping\ClassMetadata, |
|
9 | - Doctrine\Common\Persistence\Mapping\Driver\AnnotationDriver as AbstractAnnotationDriver, |
|
10 | - Doctrine\ODM\CouchDB\Mapping\Annotations as ODM, |
|
11 | - Doctrine\ODM\CouchDB\Mapping\MappingException; |
|
5 | +use Doctrine\Common\Persistence\Mapping\ClassMetadata; |
|
6 | +use Doctrine\Common\Persistence\Mapping\Driver\AnnotationDriver as AbstractAnnotationDriver; |
|
7 | +use Doctrine\ODM\CouchDB\Mapping\Annotations as ODM; |
|
8 | +use Doctrine\ODM\CouchDB\Mapping\MappingException; |
|
12 | 9 | |
13 | 10 | /** |
14 | 11 | * The AnnotationDriver reads the mapping metadata from docblock annotations. |
@@ -24,6 +24,7 @@ |
||
24 | 24 | |
25 | 25 | /** |
26 | 26 | * {@inheritDoc} |
27 | + * @param string[] $locator |
|
27 | 28 | */ |
28 | 29 | public function __construct($locator, $fileExtension = self::DEFAULT_FILE_EXTENSION) |
29 | 30 | { |
@@ -2,11 +2,10 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB\Mapping\Driver; |
4 | 4 | |
5 | -use Doctrine\Common\Persistence\Mapping\Driver\FileDriver, |
|
6 | - Doctrine\Common\Persistence\Mapping\ClassMetadata, |
|
7 | - Doctrine\ODM\CouchDB\Mapping\MappingException, |
|
8 | - Doctrine\Common\Persistence\Mapping\MappingException as DoctrineMappingException, |
|
9 | - SimpleXmlElement; |
|
5 | +use Doctrine\Common\Persistence\Mapping\Driver\FileDriver; |
|
6 | +use Doctrine\Common\Persistence\Mapping\ClassMetadata; |
|
7 | +use Doctrine\ODM\CouchDB\Mapping\MappingException; |
|
8 | +use Doctrine\Common\Persistence\Mapping\MappingException as DoctrineMappingException; |
|
10 | 9 | |
11 | 10 | /** |
12 | 11 | * XmlDriver is a metadata driver that enables mapping through XML files. |
@@ -2,11 +2,11 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB\Mapping\Driver; |
4 | 4 | |
5 | -use Doctrine\Common\Persistence\Mapping\Driver\FileDriver, |
|
6 | - Doctrine\Common\Persistence\Mapping\ClassMetadata, |
|
7 | - Doctrine\ODM\CouchDB\Mapping\MappingException, |
|
8 | - Doctrine\Common\Persistence\Mapping\MappingException as DoctrineMappingException, |
|
9 | - Symfony\Component\Yaml\Yaml; |
|
5 | +use Doctrine\Common\Persistence\Mapping\Driver\FileDriver; |
|
6 | +use Doctrine\Common\Persistence\Mapping\ClassMetadata; |
|
7 | +use Doctrine\ODM\CouchDB\Mapping\MappingException; |
|
8 | +use Doctrine\Common\Persistence\Mapping\MappingException as DoctrineMappingException; |
|
9 | +use Symfony\Component\Yaml\Yaml; |
|
10 | 10 | |
11 | 11 | /** |
12 | 12 | * The YamlDriver reads the mapping metadata from yaml schema files. |
@@ -24,6 +24,7 @@ |
||
24 | 24 | |
25 | 25 | /** |
26 | 26 | * {@inheritDoc} |
27 | + * @param string[] $locator |
|
27 | 28 | */ |
28 | 29 | public function __construct($locator, $fileExtension = self::DEFAULT_FILE_EXTENSION) |
29 | 30 | { |
@@ -21,6 +21,9 @@ |
||
21 | 21 | |
22 | 22 | private $metadataResolver; |
23 | 23 | |
24 | + /** |
|
25 | + * @param ClassMetadataFactory $metadataFactory |
|
26 | + */ |
|
24 | 27 | public function __construct($metadataFactory, $metadataResolver) |
25 | 28 | { |
26 | 29 | $this->metadataFactory = $metadataFactory; |
@@ -2,9 +2,8 @@ |
||
2 | 2 | |
3 | 3 | namespace Doctrine\ODM\CouchDB\Mapping; |
4 | 4 | |
5 | -use Doctrine\Common\Collections\ArrayCollection; |
|
6 | -use Doctrine\ODM\CouchDB\Mapping\ClassMetadata; |
|
7 | -use Doctrine\ODM\CouchDB\Types\Type; |
|
5 | +use Doctrine\Common\Collections\ArrayCollection; |
|
6 | +use Doctrine\ODM\CouchDB\Types\Type; |
|
8 | 7 | use Doctrine\Common\Util\ClassUtils; |
9 | 8 | |
10 | 9 | /** |