| @@ 183-186 (lines=4) @@ | ||
| 180 | ||
| 181 | $class->setParentClasses($nonSuperclassParents); |
|
| 182 | ||
| 183 | if ($this->evm->hasListeners(Events::loadClassMetadata)) { |
|
| 184 | $eventArgs = new \Doctrine\ODM\MongoDB\Event\LoadClassMetadataEventArgs($class, $this->dm); |
|
| 185 | $this->evm->dispatchEvent(Events::loadClassMetadata, $eventArgs); |
|
| 186 | } |
|
| 187 | } |
|
| 188 | ||
| 189 | /** |
|
| @@ 436-438 (lines=3) @@ | ||
| 433 | $args = array(new PreLoadEventArgs($document, $this->dm, $data)); |
|
| 434 | $metadata->invokeLifecycleCallbacks(Events::preLoad, $document, $args); |
|
| 435 | } |
|
| 436 | if ($this->evm->hasListeners(Events::preLoad)) { |
|
| 437 | $this->evm->dispatchEvent(Events::preLoad, new PreLoadEventArgs($document, $this->dm, $data)); |
|
| 438 | } |
|
| 439 | ||
| 440 | // alsoLoadMethods may transform the document before hydration |
|
| 441 | if ( ! empty($metadata->alsoLoadMethods)) { |
|
| @@ 462-464 (lines=3) @@ | ||
| 459 | if ( ! empty($metadata->lifecycleCallbacks[Events::postLoad])) { |
|
| 460 | $metadata->invokeLifecycleCallbacks(Events::postLoad, $document, array(new LifecycleEventArgs($document, $this->dm))); |
|
| 461 | } |
|
| 462 | if ($this->evm->hasListeners(Events::postLoad)) { |
|
| 463 | $this->evm->dispatchEvent(Events::postLoad, new LifecycleEventArgs($document, $this->dm)); |
|
| 464 | } |
|
| 465 | ||
| 466 | return $data; |
|
| 467 | } |
|
| @@ 2311-2313 (lines=3) @@ | ||
| 2308 | } |
|
| 2309 | } |
|
| 2310 | ||
| 2311 | if ($this->evm->hasListeners(Events::onClear)) { |
|
| 2312 | $this->evm->dispatchEvent(Events::onClear, new Event\OnClearEventArgs($this->dm, $documentName)); |
|
| 2313 | } |
|
| 2314 | } |
|
| 2315 | ||
| 2316 | /** |
|