if i did not previously load a document of the class of the child, phpcr-odm can not know the alias to load it. it throws an exception.
for example, use $this->documentManager->find('My\Class', '/path/to/document'); where My\Class has an @child annotation for a child that is a File. it has the file alias, but phpcr-odm knows nothing of that alias if i did not previously try to find something with 'Doctrine\...\File' that made it load the meta data.
the workaround is to get the repositories to make phpcr-odm know the alias, but this is no solution.
we could add something to specify the document class in the child annotation, but this sounds stupid.
and getting a document without knowing its document class beforehand would be a nice feature in general. however, the info is currently scattered in annotations over the project. any idea how we could make phpcr-odm know all alias to document class mappings?