@@ 608-616 (lines=9) @@ | ||
605 | * |
|
606 | * @return Document|null |
|
607 | */ |
|
608 | public function getDocumentByReference(array $ref, $useDocumentPool = true) |
|
609 | { |
|
610 | $documentArray = $this->getMongoCollection()->getDBRef($ref); |
|
611 | if (null === $documentArray) { |
|
612 | return null; |
|
613 | } |
|
614 | ||
615 | return $this->hydrate($documentArray, $useDocumentPool); |
|
616 | } |
|
617 | ||
618 | /** |
|
619 | * Get document by id directly omitting cache |
@@ 370-378 (lines=9) @@ | ||
367 | * |
|
368 | * @return Document|null |
|
369 | */ |
|
370 | public function getDocumentByReference(array $ref, $useDocumentPool = true) |
|
371 | { |
|
372 | $documentArray = $this->getMongoDB()->getDBRef($ref); |
|
373 | if (null === $documentArray) { |
|
374 | return null; |
|
375 | } |
|
376 | ||
377 | return $this->getCollection($ref['$ref'])->hydrate($documentArray, $useDocumentPool); |
|
378 | } |
|
379 | ||
380 | /** |
|
381 | * Get instance of GridFS |