Check parameter type

Since the setParent and setPosition arguments expect an object we should check that that is what being provided. Rationale - As a noob user of the CMF components I wasn't sure I was supposed to be passing the parent object or path. When passing the path I would get odd errors such as:
```
PHP Warning:  spl_object_hash() expects parameter 1 to be object, string given in /home/gnat/Projects/photography/vendor/doctrine/phpcr-odm/lib/Doctrine/ODM/PHPCR/UnitOfWork.php on line 942
PHP Warning:  get_class() expects parameter 1 to be object, string given in /home/gnat/Projects/photography/vendor/doctrine/phpcr-odm/lib/Doctrine/ODM/PHPCR/UnitOfWork.php on line 944
```

This change fails sooner and in a better way in my opinion.