@@ -131,7 +131,7 @@ discard block |
||
| 131 | 131 | */ |
| 132 | 132 | public function isTransient($className) : bool |
| 133 | 133 | { |
| 134 | - if (! $this->initialized) { |
|
| 134 | + if ( ! $this->initialized) { |
|
| 135 | 135 | $this->initialize(); |
| 136 | 136 | } |
| 137 | 137 | |
@@ -179,7 +179,7 @@ discard block |
||
| 179 | 179 | */ |
| 180 | 180 | public function getAllMetadata() : array |
| 181 | 181 | { |
| 182 | - if (! $this->initialized) { |
|
| 182 | + if ( ! $this->initialized) { |
|
| 183 | 183 | $this->initialize(); |
| 184 | 184 | } |
| 185 | 185 | |
@@ -248,7 +248,7 @@ discard block |
||
| 248 | 248 | |
| 249 | 249 | try { |
| 250 | 250 | if ($this->cacheDriver) { |
| 251 | - $cached = $this->cacheDriver->fetch($entityClassName . $this->cacheSalt); |
|
| 251 | + $cached = $this->cacheDriver->fetch($entityClassName.$this->cacheSalt); |
|
| 252 | 252 | |
| 253 | 253 | if ($cached instanceof ClassMetadata) { |
| 254 | 254 | $this->loadedMetadata[$entityClassName] = $cached; |
@@ -258,7 +258,7 @@ discard block |
||
| 258 | 258 | foreach ($this->loadMetadata($entityClassName, $metadataBuildingContext) as $loadedClass) { |
| 259 | 259 | $loadedClassName = $loadedClass->getClassName(); |
| 260 | 260 | |
| 261 | - $this->cacheDriver->save($loadedClassName . $this->cacheSalt, $loadedClass, null); |
|
| 261 | + $this->cacheDriver->save($loadedClassName.$this->cacheSalt, $loadedClass, null); |
|
| 262 | 262 | } |
| 263 | 263 | } |
| 264 | 264 | } else { |
@@ -267,7 +267,7 @@ discard block |
||
| 267 | 267 | } catch (PersistenceMappingException $loadingException) { |
| 268 | 268 | $fallbackMetadataResponse = $this->onNotFoundMetadata($entityClassName, $metadataBuildingContext); |
| 269 | 269 | |
| 270 | - if (! $fallbackMetadataResponse) { |
|
| 270 | + if ( ! $fallbackMetadataResponse) { |
|
| 271 | 271 | throw $loadingException; |
| 272 | 272 | } |
| 273 | 273 | |
@@ -303,7 +303,7 @@ discard block |
||
| 303 | 303 | */ |
| 304 | 304 | protected function loadMetadata(string $name, ClassMetadataBuildingContext $metadataBuildingContext) : array |
| 305 | 305 | { |
| 306 | - if (! $this->initialized) { |
|
| 306 | + if ( ! $this->initialized) { |
|
| 307 | 307 | $this->initialize(); |
| 308 | 308 | } |
| 309 | 309 | |
@@ -349,7 +349,7 @@ discard block |
||
| 349 | 349 | $parentClasses = []; |
| 350 | 350 | |
| 351 | 351 | foreach (array_reverse($this->getReflectionService()->getParentClasses($name)) as $parentClass) { |
| 352 | - if (! $this->getDriver()->isTransient($parentClass)) { |
|
| 352 | + if ( ! $this->getDriver()->isTransient($parentClass)) { |
|
| 353 | 353 | $parentClasses[] = $parentClass; |
| 354 | 354 | } |
| 355 | 355 | } |
@@ -364,7 +364,7 @@ discard block |
||
| 364 | 364 | string $className, |
| 365 | 365 | ClassMetadataBuildingContext $metadataBuildingContext |
| 366 | 366 | ) : ?ClassMetadata { |
| 367 | - if (! $this->evm->hasListeners(Events::onClassMetadataNotFound)) { |
|
| 367 | + if ( ! $this->evm->hasListeners(Events::onClassMetadataNotFound)) { |
|
| 368 | 368 | return null; |
| 369 | 369 | } |
| 370 | 370 | |
@@ -406,7 +406,7 @@ discard block |
||
| 406 | 406 | |
| 407 | 407 | protected function completeRuntimeMetadata(ClassMetadata $class, ?ClassMetadata $parent = null) : void |
| 408 | 408 | { |
| 409 | - if (! $parent || ! $parent->isMappedSuperclass) { |
|
| 409 | + if ( ! $parent || ! $parent->isMappedSuperclass) { |
|
| 410 | 410 | return; |
| 411 | 411 | } |
| 412 | 412 | |
@@ -424,7 +424,7 @@ discard block |
||
| 424 | 424 | continue; |
| 425 | 425 | } |
| 426 | 426 | |
| 427 | - if (! ($property instanceof ToOneAssociationMetadata)) { |
|
| 427 | + if ( ! ($property instanceof ToOneAssociationMetadata)) { |
|
| 428 | 428 | continue; |
| 429 | 429 | } |
| 430 | 430 | |
@@ -443,7 +443,7 @@ discard block |
||
| 443 | 443 | */ |
| 444 | 444 | protected function validateRuntimeMetadata(ClassMetadata $class, ?ClassMetadata $parent = null) : void |
| 445 | 445 | { |
| 446 | - if (! $class->getReflectionClass()) { |
|
| 446 | + if ( ! $class->getReflectionClass()) { |
|
| 447 | 447 | // only validate if there is a reflection class instance |
| 448 | 448 | return; |
| 449 | 449 | } |
@@ -453,13 +453,13 @@ discard block |
||
| 453 | 453 | $class->validateLifecycleCallbacks($this->getReflectionService()); |
| 454 | 454 | |
| 455 | 455 | // verify inheritance |
| 456 | - if (! $class->isMappedSuperclass && $class->inheritanceType !== InheritanceType::NONE) { |
|
| 457 | - if (! $parent) { |
|
| 458 | - if (! $class->discriminatorMap) { |
|
| 456 | + if ( ! $class->isMappedSuperclass && $class->inheritanceType !== InheritanceType::NONE) { |
|
| 457 | + if ( ! $parent) { |
|
| 458 | + if ( ! $class->discriminatorMap) { |
|
| 459 | 459 | throw MappingException::missingDiscriminatorMap($class->getClassName()); |
| 460 | 460 | } |
| 461 | 461 | |
| 462 | - if (! $class->discriminatorColumn) { |
|
| 462 | + if ( ! $class->discriminatorColumn) { |
|
| 463 | 463 | throw MappingException::missingDiscriminatorColumn($class->getClassName()); |
| 464 | 464 | } |
| 465 | 465 | } |
@@ -527,7 +527,7 @@ discard block |
||
| 527 | 527 | private function completeIdentifierGeneratorMappings(ClassMetadata $class) : void |
| 528 | 528 | { |
| 529 | 529 | foreach ($class->getDeclaredPropertiesIterator() as $property) { |
| 530 | - if (! $property instanceof FieldMetadata /*&& ! $property instanceof AssociationMetadata*/) { |
|
| 530 | + if ( ! $property instanceof FieldMetadata /*&& ! $property instanceof AssociationMetadata*/) { |
|
| 531 | 531 | continue; |
| 532 | 532 | } |
| 533 | 533 | |
@@ -537,7 +537,7 @@ discard block |
||
| 537 | 537 | |
| 538 | 538 | private function completeFieldIdentifierGeneratorMapping(FieldMetadata $field) |
| 539 | 539 | { |
| 540 | - if (! $field->hasValueGenerator()) { |
|
| 540 | + if ( ! $field->hasValueGenerator()) { |
|
| 541 | 541 | return; |
| 542 | 542 | } |
| 543 | 543 | |
@@ -596,7 +596,7 @@ discard block |
||
| 596 | 596 | |
| 597 | 597 | private function getTargetPlatform() : Platforms\AbstractPlatform |
| 598 | 598 | { |
| 599 | - if (! $this->targetPlatform) { |
|
| 599 | + if ( ! $this->targetPlatform) { |
|
| 600 | 600 | $this->targetPlatform = $this->em->getConnection()->getDatabasePlatform(); |
| 601 | 601 | } |
| 602 | 602 | |