| 1 | <?php |
||
| 17 | abstract class AbstractDoctrineLoader implements LoaderInterface |
||
| 18 | { |
||
| 19 | /** |
||
| 20 | * @var ObjectManager |
||
| 21 | */ |
||
| 22 | protected $manager; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @var string |
||
| 26 | */ |
||
| 27 | protected $class; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @param string $class |
||
| 31 | */ |
||
| 32 | public function __construct(ObjectManager $manager, $class = null) |
||
| 37 | |||
| 38 | /** |
||
| 39 | * {@inheritdoc} |
||
| 40 | */ |
||
| 41 | public function find($path) |
||
| 59 | |||
| 60 | /** |
||
| 61 | * Map the requested path (ie. subpath in the URL) to an id that can be used to lookup the image in the Doctrine store. |
||
| 62 | * |
||
| 63 | * @param string $path |
||
| 64 | * |
||
| 65 | * @return string |
||
| 66 | */ |
||
| 67 | abstract protected function mapPathToId($path); |
||
| 68 | |||
| 69 | /** |
||
| 70 | * Return a stream resource from the Doctrine entity/document with the image content. |
||
| 71 | * |
||
| 72 | * @param object $image |
||
| 73 | * |
||
| 74 | * @return resource |
||
| 75 | */ |
||
| 76 | abstract protected function getStreamFromImage($image); |
||
| 77 | } |
||
| 78 |
This check looks for function or method calls that always return null and whose return value is assigned to a variable.
The method
getObject()can return nothing but null, so it makes no sense to assign that value to a variable.The reason is most likely that a function or method is imcomplete or has been reduced for debug purposes.