コード例 #1
0
 /**
  * Detects if an object is mapped and if it isn't scheduled in the UoW as an reference to avoid
  * circular references.
  *
  * @param $object
  * @param \Doctrine\ORM\ODMAdapter\ObjectAdapterManager $objectAdapterManager
  * @return bool
  */
 protected function isReferenceable($object, ObjectAdapterManager $objectAdapterManager)
 {
     return !$objectAdapterManager->hasValidMapping(get_class($object)) || $objectAdapterManager->isReferenced($object) || $objectAdapterManager->isSleepingProxy($object) ? false : true;
 }
コード例 #2
0
 /**
  * Detects if an object is mapped and if it isn't scheduled in the UoW as an reference to avoid
  * circular references.
  *
  * @param $object
  * @return bool
  */
 protected function isReferenceable($object)
 {
     return !$this->objectAdapterManager->hasValidMapping(get_class($object)) || $this->objectAdapterManager->isReferenced($object) ? false : true;
 }