Completed
Pull Request — master (#6869)
by Michael
17:01
created
lib/Doctrine/ORM/Tools/EntityGenerator.php 1 patch
Spacing   +151 added lines, -151 removed lines patch added patch discarded remove patch
@@ -334,7 +334,7 @@  discard block
 block discarded – undo
334 334
      */
335 335
     public function __construct()
336 336
     {
337
-        @trigger_error(self::class . ' is deprecated and will be removed in Doctrine 3.0', E_USER_DEPRECATED);
337
+        @trigger_error(self::class.' is deprecated and will be removed in Doctrine 3.0', E_USER_DEPRECATED);
338 338
 
339 339
         if (version_compare(\Doctrine\Common\Version::VERSION, '2.2.0-DEV', '>=')) {
340 340
             $this->annotationsPrefix = 'ORM\\';
@@ -368,7 +368,7 @@  discard block
 block discarded – undo
368 368
      */
369 369
     public function writeEntityClass(ClassMetadataInfo $metadata, $outputDirectory)
370 370
     {
371
-        $path = $outputDirectory . '/' . str_replace('\\', DIRECTORY_SEPARATOR, $metadata->name) . $this->extension;
371
+        $path = $outputDirectory.'/'.str_replace('\\', DIRECTORY_SEPARATOR, $metadata->name).$this->extension;
372 372
         $dir = dirname($path);
373 373
 
374 374
         if ( ! is_dir($dir)) {
@@ -384,8 +384,8 @@  discard block
 block discarded – undo
384 384
         }
385 385
 
386 386
         if ($this->backupExisting && file_exists($path)) {
387
-            $backupPath = dirname($path) . DIRECTORY_SEPARATOR . basename($path) . "~";
388
-            if (!copy($path, $backupPath)) {
387
+            $backupPath = dirname($path).DIRECTORY_SEPARATOR.basename($path)."~";
388
+            if ( ! copy($path, $backupPath)) {
389 389
                 throw new \RuntimeException("Attempt to backup overwritten entity file but copy operation failed.");
390 390
             }
391 391
         }
@@ -446,7 +446,7 @@  discard block
 block discarded – undo
446 446
         $body = str_replace('<spaces>', $this->spaces, $body);
447 447
         $last = strrpos($currentCode, '}');
448 448
 
449
-        return substr($currentCode, 0, $last) . $body . ($body ? "\n" : '') . "}\n";
449
+        return substr($currentCode, 0, $last).$body.($body ? "\n" : '')."}\n";
450 450
     }
451 451
 
452 452
     /**
@@ -510,7 +510,7 @@  discard block
 block discarded – undo
510 510
     public function setFieldVisibility($visibility)
511 511
     {
512 512
         if ($visibility !== static::FIELD_VISIBLE_PRIVATE && $visibility !== static::FIELD_VISIBLE_PROTECTED) {
513
-            throw new \InvalidArgumentException('Invalid provided visibility (only private and protected are allowed): ' . $visibility);
513
+            throw new \InvalidArgumentException('Invalid provided visibility (only private and protected are allowed): '.$visibility);
514 514
         }
515 515
 
516 516
         $this->fieldVisibility = $visibility;
@@ -607,11 +607,11 @@  discard block
 block discarded – undo
607 607
      */
608 608
     protected function generateEntityNamespace(ClassMetadataInfo $metadata)
609 609
     {
610
-        if (! $this->hasNamespace($metadata)) {
610
+        if ( ! $this->hasNamespace($metadata)) {
611 611
             return '';
612 612
         }
613 613
 
614
-        return 'namespace ' . $this->getNamespace($metadata) .';';
614
+        return 'namespace '.$this->getNamespace($metadata).';';
615 615
     }
616 616
 
617 617
     /**
@@ -619,7 +619,7 @@  discard block
 block discarded – undo
619 619
      */
620 620
     protected function generateEntityUse()
621 621
     {
622
-        if (! $this->generateAnnotations) {
622
+        if ( ! $this->generateAnnotations) {
623 623
             return '';
624 624
         }
625 625
 
@@ -633,8 +633,8 @@  discard block
 block discarded – undo
633 633
      */
634 634
     protected function generateEntityClassName(ClassMetadataInfo $metadata)
635 635
     {
636
-        return 'class ' . $this->getClassName($metadata) .
637
-            ($this->extendsClass() ? ' extends ' . $this->getClassToExtendName() : null);
636
+        return 'class '.$this->getClassName($metadata).
637
+            ($this->extendsClass() ? ' extends '.$this->getClassToExtendName() : null);
638 638
     }
639 639
 
640 640
     /**
@@ -736,13 +736,13 @@  discard block
 block discarded – undo
736 736
         $fieldMappings = array_merge($requiredFields, $optionalFields);
737 737
 
738 738
         foreach ($metadata->embeddedClasses as $fieldName => $embeddedClass) {
739
-            $paramType = '\\' . ltrim($embeddedClass['class'], '\\');
740
-            $paramVariable = '$' . $fieldName;
739
+            $paramType = '\\'.ltrim($embeddedClass['class'], '\\');
740
+            $paramVariable = '$'.$fieldName;
741 741
 
742 742
             $paramTypes[] = $paramType;
743 743
             $paramVariables[] = $paramVariable;
744
-            $params[] = $paramType . ' ' . $paramVariable;
745
-            $fields[] = '$this->' . $fieldName . ' = ' . $paramVariable . ';';
744
+            $params[] = $paramType.' '.$paramVariable;
745
+            $fields[] = '$this->'.$fieldName.' = '.$paramVariable.';';
746 746
         }
747 747
 
748 748
         foreach ($fieldMappings as $fieldMapping) {
@@ -750,27 +750,27 @@  discard block
 block discarded – undo
750 750
                 continue;
751 751
             }
752 752
 
753
-            $paramTypes[] = $this->getType($fieldMapping['type']) . (!empty($fieldMapping['nullable']) ? '|null' : '');
754
-            $param = '$' . $fieldMapping['fieldName'];
753
+            $paramTypes[] = $this->getType($fieldMapping['type']).( ! empty($fieldMapping['nullable']) ? '|null' : '');
754
+            $param = '$'.$fieldMapping['fieldName'];
755 755
             $paramVariables[] = $param;
756 756
 
757 757
             if ($fieldMapping['type'] === 'datetime') {
758
-                $param = $this->getType($fieldMapping['type']) . ' ' . $param;
758
+                $param = $this->getType($fieldMapping['type']).' '.$param;
759 759
             }
760 760
 
761
-            if (!empty($fieldMapping['nullable'])) {
761
+            if ( ! empty($fieldMapping['nullable'])) {
762 762
                 $param .= ' = null';
763 763
             }
764 764
 
765 765
             $params[] = $param;
766 766
 
767
-            $fields[] = '$this->' . $fieldMapping['fieldName'] . ' = $' . $fieldMapping['fieldName'] . ';';
767
+            $fields[] = '$this->'.$fieldMapping['fieldName'].' = $'.$fieldMapping['fieldName'].';';
768 768
         }
769 769
 
770 770
         $maxParamTypeLength = max(array_map('strlen', $paramTypes));
771 771
         $paramTags = array_map(
772
-            function ($type, $variable) use ($maxParamTypeLength) {
773
-                return '@param ' . $type . str_repeat(' ', $maxParamTypeLength - strlen($type) + 1) . $variable;
772
+            function($type, $variable) use ($maxParamTypeLength) {
773
+                return '@param '.$type.str_repeat(' ', $maxParamTypeLength - strlen($type) + 1).$variable;
774 774
             },
775 775
             $paramTypes,
776 776
             $paramVariables
@@ -778,8 +778,8 @@  discard block
 block discarded – undo
778 778
 
779 779
         // Generate multi line constructor if the signature exceeds 120 characters.
780 780
         if (array_sum(array_map('strlen', $params)) + count($params) * 2 + 29 > 120) {
781
-            $delimiter = "\n" . $this->spaces;
782
-            $params = $delimiter . implode(',' . $delimiter, $params) . "\n";
781
+            $delimiter = "\n".$this->spaces;
782
+            $params = $delimiter.implode(','.$delimiter, $params)."\n";
783 783
         } else {
784 784
             $params = implode(', ', $params);
785 785
         }
@@ -787,7 +787,7 @@  discard block
 block discarded – undo
787 787
         $replacements = [
788 788
             '<paramTags>' => implode("\n * ", $paramTags),
789 789
             '<params>'    => $params,
790
-            '<fields>'    => implode("\n" . $this->spaces, $fields),
790
+            '<fields>'    => implode("\n".$this->spaces, $fields),
791 791
         ];
792 792
 
793 793
         $constructor = str_replace(
@@ -832,7 +832,7 @@  discard block
 block discarded – undo
832 832
 
833 833
             if ($inClass) {
834 834
                 $inClass = false;
835
-                $lastSeenClass = $lastSeenNamespace . ($lastSeenNamespace ? '\\' : '') . $token[1];
835
+                $lastSeenClass = $lastSeenNamespace.($lastSeenNamespace ? '\\' : '').$token[1];
836 836
                 $this->staticReflection[$lastSeenClass]['properties'] = [];
837 837
                 $this->staticReflection[$lastSeenClass]['methods'] = [];
838 838
             }
@@ -840,16 +840,16 @@  discard block
 block discarded – undo
840 840
             if (T_NAMESPACE === $token[0]) {
841 841
                 $lastSeenNamespace = '';
842 842
                 $inNamespace = true;
843
-            } elseif (T_CLASS === $token[0] && T_DOUBLE_COLON !== $tokens[$i-1][0]) {
843
+            } elseif (T_CLASS === $token[0] && T_DOUBLE_COLON !== $tokens[$i - 1][0]) {
844 844
                 $inClass = true;
845 845
             } elseif (T_FUNCTION === $token[0]) {
846
-                if (T_STRING === $tokens[$i+2][0]) {
847
-                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i+2][1]);
848
-                } elseif ($tokens[$i+2] == '&' && T_STRING === $tokens[$i+3][0]) {
849
-                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i+3][1]);
846
+                if (T_STRING === $tokens[$i + 2][0]) {
847
+                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i + 2][1]);
848
+                } elseif ($tokens[$i + 2] == '&' && T_STRING === $tokens[$i + 3][0]) {
849
+                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i + 3][1]);
850 850
                 }
851
-            } elseif (in_array($token[0], [T_VAR, T_PUBLIC, T_PRIVATE, T_PROTECTED], true) && T_FUNCTION !== $tokens[$i+2][0]) {
852
-                $this->staticReflection[$lastSeenClass]['properties'][] = substr($tokens[$i+2][1], 1);
851
+            } elseif (in_array($token[0], [T_VAR, T_PUBLIC, T_PRIVATE, T_PROTECTED], true) && T_FUNCTION !== $tokens[$i + 2][0]) {
852
+                $this->staticReflection[$lastSeenClass]['properties'][] = substr($tokens[$i + 2][1], 1);
853 853
             }
854 854
         }
855 855
     }
@@ -862,7 +862,7 @@  discard block
 block discarded – undo
862 862
      */
863 863
     protected function hasProperty($property, ClassMetadataInfo $metadata)
864 864
     {
865
-        if ($this->extendsClass() || (!$this->isNew && class_exists($metadata->name))) {
865
+        if ($this->extendsClass() || ( ! $this->isNew && class_exists($metadata->name))) {
866 866
             // don't generate property if its already on the base class.
867 867
             $reflClass = new \ReflectionClass($this->getClassToExtend() ?: $metadata->name);
868 868
             if ($reflClass->hasProperty($property)) {
@@ -891,7 +891,7 @@  discard block
 block discarded – undo
891 891
      */
892 892
     protected function hasMethod($method, ClassMetadataInfo $metadata)
893 893
     {
894
-        if ($this->extendsClass() || (!$this->isNew && class_exists($metadata->name))) {
894
+        if ($this->extendsClass() || ( ! $this->isNew && class_exists($metadata->name))) {
895 895
             // don't generate method if its already on the base class.
896 896
             $reflClass = new \ReflectionClass($this->getClassToExtend() ?: $metadata->name);
897 897
 
@@ -922,7 +922,7 @@  discard block
 block discarded – undo
922 922
      */
923 923
     protected function getTraits(ClassMetadataInfo $metadata)
924 924
     {
925
-        if (! ($metadata->reflClass !== null || class_exists($metadata->name))) {
925
+        if ( ! ($metadata->reflClass !== null || class_exists($metadata->name))) {
926 926
             return [];
927 927
         }
928 928
 
@@ -972,7 +972,7 @@  discard block
 block discarded – undo
972 972
     {
973 973
         $refl = new \ReflectionClass($this->getClassToExtend());
974 974
 
975
-        return '\\' . $refl->getName();
975
+        return '\\'.$refl->getName();
976 976
     }
977 977
 
978 978
     /**
@@ -1005,7 +1005,7 @@  discard block
 block discarded – undo
1005 1005
     {
1006 1006
         $lines = [];
1007 1007
         $lines[] = '/**';
1008
-        $lines[] = ' * ' . $this->getClassName($metadata);
1008
+        $lines[] = ' * '.$this->getClassName($metadata);
1009 1009
 
1010 1010
         if ($this->generateAnnotations) {
1011 1011
             $lines[] = ' *';
@@ -1021,12 +1021,12 @@  discard block
 block discarded – undo
1021 1021
 
1022 1022
             foreach ($methods as $method) {
1023 1023
                 if ($code = $this->$method($metadata)) {
1024
-                    $lines[] = ' * ' . $code;
1024
+                    $lines[] = ' * '.$code;
1025 1025
                 }
1026 1026
             }
1027 1027
 
1028 1028
             if (isset($metadata->lifecycleCallbacks) && $metadata->lifecycleCallbacks) {
1029
-                $lines[] = ' * @' . $this->annotationsPrefix . 'HasLifecycleCallbacks';
1029
+                $lines[] = ' * @'.$this->annotationsPrefix.'HasLifecycleCallbacks';
1030 1030
             }
1031 1031
         }
1032 1032
 
@@ -1042,17 +1042,17 @@  discard block
 block discarded – undo
1042 1042
      */
1043 1043
     protected function generateEntityAnnotation(ClassMetadataInfo $metadata)
1044 1044
     {
1045
-        $prefix = '@' . $this->annotationsPrefix;
1045
+        $prefix = '@'.$this->annotationsPrefix;
1046 1046
 
1047 1047
         if ($metadata->isEmbeddedClass) {
1048
-            return $prefix . 'Embeddable';
1048
+            return $prefix.'Embeddable';
1049 1049
         }
1050 1050
 
1051 1051
         $customRepository = $metadata->customRepositoryClassName
1052
-            ? '(repositoryClass="' . $metadata->customRepositoryClassName . '")'
1052
+            ? '(repositoryClass="'.$metadata->customRepositoryClassName.'")'
1053 1053
             : '';
1054 1054
 
1055
-        return $prefix . ($metadata->isMappedSuperclass ? 'MappedSuperclass' : 'Entity') . $customRepository;
1055
+        return $prefix.($metadata->isMappedSuperclass ? 'MappedSuperclass' : 'Entity').$customRepository;
1056 1056
     }
1057 1057
 
1058 1058
     /**
@@ -1069,28 +1069,28 @@  discard block
 block discarded – undo
1069 1069
         $table = [];
1070 1070
 
1071 1071
         if (isset($metadata->table['schema'])) {
1072
-            $table[] = 'schema="' . $metadata->table['schema'] . '"';
1072
+            $table[] = 'schema="'.$metadata->table['schema'].'"';
1073 1073
         }
1074 1074
 
1075 1075
         if (isset($metadata->table['name'])) {
1076
-            $table[] = 'name="' . $metadata->table['name'] . '"';
1076
+            $table[] = 'name="'.$metadata->table['name'].'"';
1077 1077
         }
1078 1078
 
1079 1079
         if (isset($metadata->table['options']) && $metadata->table['options']) {
1080
-            $table[] = 'options={' . $this->exportTableOptions((array) $metadata->table['options']) . '}';
1080
+            $table[] = 'options={'.$this->exportTableOptions((array) $metadata->table['options']).'}';
1081 1081
         }
1082 1082
 
1083 1083
         if (isset($metadata->table['uniqueConstraints']) && $metadata->table['uniqueConstraints']) {
1084 1084
             $constraints = $this->generateTableConstraints('UniqueConstraint', $metadata->table['uniqueConstraints']);
1085
-            $table[] = 'uniqueConstraints={' . $constraints . '}';
1085
+            $table[] = 'uniqueConstraints={'.$constraints.'}';
1086 1086
         }
1087 1087
 
1088 1088
         if (isset($metadata->table['indexes']) && $metadata->table['indexes']) {
1089 1089
             $constraints = $this->generateTableConstraints('Index', $metadata->table['indexes']);
1090
-            $table[] = 'indexes={' . $constraints . '}';
1090
+            $table[] = 'indexes={'.$constraints.'}';
1091 1091
         }
1092 1092
 
1093
-        return '@' . $this->annotationsPrefix . 'Table(' . implode(', ', $table) . ')';
1093
+        return '@'.$this->annotationsPrefix.'Table('.implode(', ', $table).')';
1094 1094
     }
1095 1095
 
1096 1096
     /**
@@ -1105,9 +1105,9 @@  discard block
 block discarded – undo
1105 1105
         foreach ($constraints as $name => $constraint) {
1106 1106
             $columns = [];
1107 1107
             foreach ($constraint['columns'] as $column) {
1108
-                $columns[] = '"' . $column . '"';
1108
+                $columns[] = '"'.$column.'"';
1109 1109
             }
1110
-            $annotations[] = '@' . $this->annotationsPrefix . $constraintName . '(name="' . $name . '", columns={' . implode(', ', $columns) . '})';
1110
+            $annotations[] = '@'.$this->annotationsPrefix.$constraintName.'(name="'.$name.'", columns={'.implode(', ', $columns).'})';
1111 1111
         }
1112 1112
 
1113 1113
         return implode(', ', $annotations);
@@ -1124,7 +1124,7 @@  discard block
 block discarded – undo
1124 1124
             return '';
1125 1125
         }
1126 1126
 
1127
-        return '@' . $this->annotationsPrefix . 'InheritanceType("'.$this->getInheritanceTypeString($metadata->inheritanceType).'")';
1127
+        return '@'.$this->annotationsPrefix.'InheritanceType("'.$this->getInheritanceTypeString($metadata->inheritanceType).'")';
1128 1128
     }
1129 1129
 
1130 1130
     /**
@@ -1139,11 +1139,11 @@  discard block
 block discarded – undo
1139 1139
         }
1140 1140
 
1141 1141
         $discrColumn = $metadata->discriminatorColumn;
1142
-        $columnDefinition = 'name="' . $discrColumn['name']
1143
-            . '", type="' . $discrColumn['type']
1144
-            . '", length=' . $discrColumn['length'];
1142
+        $columnDefinition = 'name="'.$discrColumn['name']
1143
+            . '", type="'.$discrColumn['type']
1144
+            . '", length='.$discrColumn['length'];
1145 1145
 
1146
-        return '@' . $this->annotationsPrefix . 'DiscriminatorColumn(' . $columnDefinition . ')';
1146
+        return '@'.$this->annotationsPrefix.'DiscriminatorColumn('.$columnDefinition.')';
1147 1147
     }
1148 1148
 
1149 1149
     /**
@@ -1160,10 +1160,10 @@  discard block
 block discarded – undo
1160 1160
         $inheritanceClassMap = [];
1161 1161
 
1162 1162
         foreach ($metadata->discriminatorMap as $type => $class) {
1163
-            $inheritanceClassMap[] .= '"' . $type . '" = "' . $class . '"';
1163
+            $inheritanceClassMap[] .= '"'.$type.'" = "'.$class.'"';
1164 1164
         }
1165 1165
 
1166
-        return '@' . $this->annotationsPrefix . 'DiscriminatorMap({' . implode(', ', $inheritanceClassMap) . '})';
1166
+        return '@'.$this->annotationsPrefix.'DiscriminatorMap({'.implode(', ', $inheritanceClassMap).'})';
1167 1167
     }
1168 1168
 
1169 1169
     /**
@@ -1182,8 +1182,8 @@  discard block
 block discarded – undo
1182 1182
 
1183 1183
             $nullableField = $this->nullableFieldExpression($fieldMapping);
1184 1184
 
1185
-            if ((!$metadata->isEmbeddedClass || !$this->embeddablesImmutable)
1186
-                && (!isset($fieldMapping['id']) || ! $fieldMapping['id'] || $metadata->generatorType === ClassMetadataInfo::GENERATOR_TYPE_NONE)
1185
+            if (( ! $metadata->isEmbeddedClass || ! $this->embeddablesImmutable)
1186
+                && ( ! isset($fieldMapping['id']) || ! $fieldMapping['id'] || $metadata->generatorType === ClassMetadataInfo::GENERATOR_TYPE_NONE)
1187 1187
                 && $code = $this->generateEntityStubMethod($metadata, 'set', $fieldMapping['fieldName'], $fieldMapping['type'], $nullableField)
1188 1188
             ) {
1189 1189
                 $methods[] = $code;
@@ -1254,7 +1254,7 @@  discard block
 block discarded – undo
1254 1254
         }
1255 1255
 
1256 1256
         foreach ($joinColumns as $joinColumn) {
1257
-            if (isset($joinColumn['nullable']) && !$joinColumn['nullable']) {
1257
+            if (isset($joinColumn['nullable']) && ! $joinColumn['nullable']) {
1258 1258
                 return false;
1259 1259
             }
1260 1260
         }
@@ -1299,8 +1299,8 @@  discard block
 block discarded – undo
1299 1299
             }
1300 1300
 
1301 1301
             $lines[] = $this->generateAssociationMappingPropertyDocBlock($associationMapping, $metadata);
1302
-            $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $associationMapping['fieldName']
1303
-                     . ($associationMapping['type'] == 'manyToMany' ? ' = array()' : null) . ";\n";
1302
+            $lines[] = $this->spaces.$this->fieldVisibility.' $'.$associationMapping['fieldName']
1303
+                     . ($associationMapping['type'] == 'manyToMany' ? ' = array()' : null).";\n";
1304 1304
         }
1305 1305
 
1306 1306
         return implode("\n", $lines);
@@ -1324,8 +1324,8 @@  discard block
 block discarded – undo
1324 1324
             }
1325 1325
 
1326 1326
             $lines[] = $this->generateFieldMappingPropertyDocBlock($fieldMapping, $metadata);
1327
-            $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $fieldMapping['fieldName']
1328
-                     . (isset($fieldMapping['options']['default']) ? ' = ' . var_export($fieldMapping['options']['default'], true) : null) . ";\n";
1327
+            $lines[] = $this->spaces.$this->fieldVisibility.' $'.$fieldMapping['fieldName']
1328
+                     . (isset($fieldMapping['options']['default']) ? ' = '.var_export($fieldMapping['options']['default'], true) : null).";\n";
1329 1329
         }
1330 1330
 
1331 1331
         return implode("\n", $lines);
@@ -1346,7 +1346,7 @@  discard block
 block discarded – undo
1346 1346
             }
1347 1347
 
1348 1348
             $lines[] = $this->generateEmbeddedPropertyDocBlock($embeddedClass);
1349
-            $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $fieldName . ";\n";
1349
+            $lines[] = $this->spaces.$this->fieldVisibility.' $'.$fieldName.";\n";
1350 1350
         }
1351 1351
 
1352 1352
         return implode("\n", $lines);
@@ -1363,7 +1363,7 @@  discard block
 block discarded – undo
1363 1363
      */
1364 1364
     protected function generateEntityStubMethod(ClassMetadataInfo $metadata, $type, $fieldName, $typeHint = null, $defaultValue = null)
1365 1365
     {
1366
-        $methodName = $type . Inflector::classify($fieldName);
1366
+        $methodName = $type.Inflector::classify($fieldName);
1367 1367
         $variableName = Inflector::camelize($fieldName);
1368 1368
         if (in_array($type, ["add", "remove"])) {
1369 1369
             $methodName = Inflector::singularize($methodName);
@@ -1383,18 +1383,18 @@  discard block
 block discarded – undo
1383 1383
         $variableType   = $typeHint ? $this->getType($typeHint) : null;
1384 1384
 
1385 1385
         if ($typeHint && ! isset($types[$typeHint])) {
1386
-            $variableType   =  '\\' . ltrim($variableType, '\\');
1387
-            $methodTypeHint =  '\\' . $typeHint . ' ';
1386
+            $variableType   = '\\'.ltrim($variableType, '\\');
1387
+            $methodTypeHint = '\\'.$typeHint.' ';
1388 1388
         }
1389 1389
 
1390 1390
         $replacements = [
1391
-          '<description>'       => ucfirst($type) . ' ' . $variableName . '.',
1391
+          '<description>'       => ucfirst($type).' '.$variableName.'.',
1392 1392
           '<methodTypeHint>'    => $methodTypeHint,
1393
-          '<variableType>'      => $variableType . (null !== $defaultValue ? ('|' . $defaultValue) : ''),
1393
+          '<variableType>'      => $variableType.(null !== $defaultValue ? ('|'.$defaultValue) : ''),
1394 1394
           '<variableName>'      => $variableName,
1395 1395
           '<methodName>'        => $methodName,
1396 1396
           '<fieldName>'         => $fieldName,
1397
-          '<variableDefault>'   => ($defaultValue !== null ) ? (' = ' . $defaultValue) : '',
1397
+          '<variableDefault>'   => ($defaultValue !== null) ? (' = '.$defaultValue) : '',
1398 1398
           '<entity>'            => $this->getClassName($metadata)
1399 1399
         ];
1400 1400
 
@@ -1423,7 +1423,7 @@  discard block
 block discarded – undo
1423 1423
         $this->staticReflection[$metadata->name]['methods'][] = $methodName;
1424 1424
 
1425 1425
         $replacements = [
1426
-            '<name>'        => $this->annotationsPrefix . ucfirst($name),
1426
+            '<name>'        => $this->annotationsPrefix.ucfirst($name),
1427 1427
             '<methodName>'  => $methodName,
1428 1428
         ];
1429 1429
 
@@ -1446,30 +1446,30 @@  discard block
 block discarded – undo
1446 1446
         $joinColumnAnnot = [];
1447 1447
 
1448 1448
         if (isset($joinColumn['name'])) {
1449
-            $joinColumnAnnot[] = 'name="' . $joinColumn['name'] . '"';
1449
+            $joinColumnAnnot[] = 'name="'.$joinColumn['name'].'"';
1450 1450
         }
1451 1451
 
1452 1452
         if (isset($joinColumn['referencedColumnName'])) {
1453
-            $joinColumnAnnot[] = 'referencedColumnName="' . $joinColumn['referencedColumnName'] . '"';
1453
+            $joinColumnAnnot[] = 'referencedColumnName="'.$joinColumn['referencedColumnName'].'"';
1454 1454
         }
1455 1455
 
1456 1456
         if (isset($joinColumn['unique']) && $joinColumn['unique']) {
1457
-            $joinColumnAnnot[] = 'unique=' . ($joinColumn['unique'] ? 'true' : 'false');
1457
+            $joinColumnAnnot[] = 'unique='.($joinColumn['unique'] ? 'true' : 'false');
1458 1458
         }
1459 1459
 
1460 1460
         if (isset($joinColumn['nullable'])) {
1461
-            $joinColumnAnnot[] = 'nullable=' . ($joinColumn['nullable'] ? 'true' : 'false');
1461
+            $joinColumnAnnot[] = 'nullable='.($joinColumn['nullable'] ? 'true' : 'false');
1462 1462
         }
1463 1463
 
1464 1464
         if (isset($joinColumn['onDelete'])) {
1465
-            $joinColumnAnnot[] = 'onDelete="' . ($joinColumn['onDelete'] . '"');
1465
+            $joinColumnAnnot[] = 'onDelete="'.($joinColumn['onDelete'].'"');
1466 1466
         }
1467 1467
 
1468 1468
         if (isset($joinColumn['columnDefinition'])) {
1469
-            $joinColumnAnnot[] = 'columnDefinition="' . $joinColumn['columnDefinition'] . '"';
1469
+            $joinColumnAnnot[] = 'columnDefinition="'.$joinColumn['columnDefinition'].'"';
1470 1470
         }
1471 1471
 
1472
-        return '@' . $this->annotationsPrefix . 'JoinColumn(' . implode(', ', $joinColumnAnnot) . ')';
1472
+        return '@'.$this->annotationsPrefix.'JoinColumn('.implode(', ', $joinColumnAnnot).')';
1473 1473
     }
1474 1474
 
1475 1475
     /**
@@ -1481,22 +1481,22 @@  discard block
 block discarded – undo
1481 1481
     protected function generateAssociationMappingPropertyDocBlock(array $associationMapping, ClassMetadataInfo $metadata)
1482 1482
     {
1483 1483
         $lines = [];
1484
-        $lines[] = $this->spaces . '/**';
1484
+        $lines[] = $this->spaces.'/**';
1485 1485
 
1486 1486
         if ($associationMapping['type'] & ClassMetadataInfo::TO_MANY) {
1487
-            $lines[] = $this->spaces . ' * @var \Doctrine\Common\Collections\Collection';
1487
+            $lines[] = $this->spaces.' * @var \Doctrine\Common\Collections\Collection';
1488 1488
         } else {
1489
-            $lines[] = $this->spaces . ' * @var \\' . ltrim($associationMapping['targetEntity'], '\\');
1489
+            $lines[] = $this->spaces.' * @var \\'.ltrim($associationMapping['targetEntity'], '\\');
1490 1490
         }
1491 1491
 
1492 1492
         if ($this->generateAnnotations) {
1493
-            $lines[] = $this->spaces . ' *';
1493
+            $lines[] = $this->spaces.' *';
1494 1494
 
1495 1495
             if (isset($associationMapping['id']) && $associationMapping['id']) {
1496
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Id';
1496
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Id';
1497 1497
 
1498 1498
                 if ($generatorType = $this->getIdGeneratorTypeString($metadata->generatorType)) {
1499
-                    $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'GeneratedValue(strategy="' . $generatorType . '")';
1499
+                    $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'GeneratedValue(strategy="'.$generatorType.'")';
1500 1500
                 }
1501 1501
             }
1502 1502
 
@@ -1518,15 +1518,15 @@  discard block
 block discarded – undo
1518 1518
             $typeOptions = [];
1519 1519
 
1520 1520
             if (isset($associationMapping['targetEntity'])) {
1521
-                $typeOptions[] = 'targetEntity="' . $associationMapping['targetEntity'] . '"';
1521
+                $typeOptions[] = 'targetEntity="'.$associationMapping['targetEntity'].'"';
1522 1522
             }
1523 1523
 
1524 1524
             if (isset($associationMapping['inversedBy'])) {
1525
-                $typeOptions[] = 'inversedBy="' . $associationMapping['inversedBy'] . '"';
1525
+                $typeOptions[] = 'inversedBy="'.$associationMapping['inversedBy'].'"';
1526 1526
             }
1527 1527
 
1528 1528
             if (isset($associationMapping['mappedBy'])) {
1529
-                $typeOptions[] = 'mappedBy="' . $associationMapping['mappedBy'] . '"';
1529
+                $typeOptions[] = 'mappedBy="'.$associationMapping['mappedBy'].'"';
1530 1530
             }
1531 1531
 
1532 1532
             if ($associationMapping['cascade']) {
@@ -1542,11 +1542,11 @@  discard block
 block discarded – undo
1542 1542
                     $cascades = ['"all"'];
1543 1543
                 }
1544 1544
 
1545
-                $typeOptions[] = 'cascade={' . implode(',', $cascades) . '}';
1545
+                $typeOptions[] = 'cascade={'.implode(',', $cascades).'}';
1546 1546
             }
1547 1547
 
1548 1548
             if (isset($associationMapping['orphanRemoval']) && $associationMapping['orphanRemoval']) {
1549
-                $typeOptions[] = 'orphanRemoval=' . ($associationMapping['orphanRemoval'] ? 'true' : 'false');
1549
+                $typeOptions[] = 'orphanRemoval='.($associationMapping['orphanRemoval'] ? 'true' : 'false');
1550 1550
             }
1551 1551
 
1552 1552
             if (isset($associationMapping['fetch']) && $associationMapping['fetch'] !== ClassMetadataInfo::FETCH_LAZY) {
@@ -1555,71 +1555,71 @@  discard block
 block discarded – undo
1555 1555
                     ClassMetadataInfo::FETCH_EAGER      => 'EAGER',
1556 1556
                 ];
1557 1557
 
1558
-                $typeOptions[] = 'fetch="' . $fetchMap[$associationMapping['fetch']] . '"';
1558
+                $typeOptions[] = 'fetch="'.$fetchMap[$associationMapping['fetch']].'"';
1559 1559
             }
1560 1560
 
1561
-            $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . '' . $type . '(' . implode(', ', $typeOptions) . ')';
1561
+            $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.''.$type.'('.implode(', ', $typeOptions).')';
1562 1562
 
1563 1563
             if (isset($associationMapping['joinColumns']) && $associationMapping['joinColumns']) {
1564
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'JoinColumns({';
1564
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'JoinColumns({';
1565 1565
 
1566 1566
                 $joinColumnsLines = [];
1567 1567
 
1568 1568
                 foreach ($associationMapping['joinColumns'] as $joinColumn) {
1569 1569
                     if ($joinColumnAnnot = $this->generateJoinColumnAnnotation($joinColumn)) {
1570
-                        $joinColumnsLines[] = $this->spaces . ' *   ' . $joinColumnAnnot;
1570
+                        $joinColumnsLines[] = $this->spaces.' *   '.$joinColumnAnnot;
1571 1571
                     }
1572 1572
                 }
1573 1573
 
1574 1574
                 $lines[] = implode(",\n", $joinColumnsLines);
1575
-                $lines[] = $this->spaces . ' * })';
1575
+                $lines[] = $this->spaces.' * })';
1576 1576
             }
1577 1577
 
1578 1578
             if (isset($associationMapping['joinTable']) && $associationMapping['joinTable']) {
1579 1579
                 $joinTable = [];
1580
-                $joinTable[] = 'name="' . $associationMapping['joinTable']['name'] . '"';
1580
+                $joinTable[] = 'name="'.$associationMapping['joinTable']['name'].'"';
1581 1581
 
1582 1582
                 if (isset($associationMapping['joinTable']['schema'])) {
1583
-                    $joinTable[] = 'schema="' . $associationMapping['joinTable']['schema'] . '"';
1583
+                    $joinTable[] = 'schema="'.$associationMapping['joinTable']['schema'].'"';
1584 1584
                 }
1585 1585
 
1586
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'JoinTable(' . implode(', ', $joinTable) . ',';
1587
-                $lines[] = $this->spaces . ' *   joinColumns={';
1586
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'JoinTable('.implode(', ', $joinTable).',';
1587
+                $lines[] = $this->spaces.' *   joinColumns={';
1588 1588
 
1589 1589
                 $joinColumnsLines = [];
1590 1590
 
1591 1591
                 foreach ($associationMapping['joinTable']['joinColumns'] as $joinColumn) {
1592
-                    $joinColumnsLines[] = $this->spaces . ' *     ' . $this->generateJoinColumnAnnotation($joinColumn);
1592
+                    $joinColumnsLines[] = $this->spaces.' *     '.$this->generateJoinColumnAnnotation($joinColumn);
1593 1593
                 }
1594 1594
 
1595
-                $lines[] = implode(",". PHP_EOL, $joinColumnsLines);
1596
-                $lines[] = $this->spaces . ' *   },';
1597
-                $lines[] = $this->spaces . ' *   inverseJoinColumns={';
1595
+                $lines[] = implode(",".PHP_EOL, $joinColumnsLines);
1596
+                $lines[] = $this->spaces.' *   },';
1597
+                $lines[] = $this->spaces.' *   inverseJoinColumns={';
1598 1598
 
1599 1599
                 $inverseJoinColumnsLines = [];
1600 1600
 
1601 1601
                 foreach ($associationMapping['joinTable']['inverseJoinColumns'] as $joinColumn) {
1602
-                    $inverseJoinColumnsLines[] = $this->spaces . ' *     ' . $this->generateJoinColumnAnnotation($joinColumn);
1602
+                    $inverseJoinColumnsLines[] = $this->spaces.' *     '.$this->generateJoinColumnAnnotation($joinColumn);
1603 1603
                 }
1604 1604
 
1605
-                $lines[] = implode(",". PHP_EOL, $inverseJoinColumnsLines);
1606
-                $lines[] = $this->spaces . ' *   }';
1607
-                $lines[] = $this->spaces . ' * )';
1605
+                $lines[] = implode(",".PHP_EOL, $inverseJoinColumnsLines);
1606
+                $lines[] = $this->spaces.' *   }';
1607
+                $lines[] = $this->spaces.' * )';
1608 1608
             }
1609 1609
 
1610 1610
             if (isset($associationMapping['orderBy'])) {
1611
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'OrderBy({';
1611
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'OrderBy({';
1612 1612
 
1613 1613
                 foreach ($associationMapping['orderBy'] as $name => $direction) {
1614
-                    $lines[] = $this->spaces . ' *     "' . $name . '"="' . $direction . '",';
1614
+                    $lines[] = $this->spaces.' *     "'.$name.'"="'.$direction.'",';
1615 1615
                 }
1616 1616
 
1617 1617
                 $lines[count($lines) - 1] = substr($lines[count($lines) - 1], 0, strlen($lines[count($lines) - 1]) - 1);
1618
-                $lines[] = $this->spaces . ' * })';
1618
+                $lines[] = $this->spaces.' * })';
1619 1619
             }
1620 1620
         }
1621 1621
 
1622
-        $lines[] = $this->spaces . ' */';
1622
+        $lines[] = $this->spaces.' */';
1623 1623
 
1624 1624
         return implode("\n", $lines);
1625 1625
     }
@@ -1633,43 +1633,43 @@  discard block
 block discarded – undo
1633 1633
     protected function generateFieldMappingPropertyDocBlock(array $fieldMapping, ClassMetadataInfo $metadata)
1634 1634
     {
1635 1635
         $lines = [];
1636
-        $lines[] = $this->spaces . '/**';
1637
-        $lines[] = $this->spaces . ' * @var '
1636
+        $lines[] = $this->spaces.'/**';
1637
+        $lines[] = $this->spaces.' * @var '
1638 1638
             . $this->getType($fieldMapping['type'])
1639 1639
             . ($this->nullableFieldExpression($fieldMapping) ? '|null' : '');
1640 1640
 
1641 1641
         if ($this->generateAnnotations) {
1642
-            $lines[] = $this->spaces . ' *';
1642
+            $lines[] = $this->spaces.' *';
1643 1643
 
1644 1644
             $column = [];
1645 1645
             if (isset($fieldMapping['columnName'])) {
1646
-                $column[] = 'name="' . $fieldMapping['columnName'] . '"';
1646
+                $column[] = 'name="'.$fieldMapping['columnName'].'"';
1647 1647
             }
1648 1648
 
1649 1649
             if (isset($fieldMapping['type'])) {
1650
-                $column[] = 'type="' . $fieldMapping['type'] . '"';
1650
+                $column[] = 'type="'.$fieldMapping['type'].'"';
1651 1651
             }
1652 1652
 
1653 1653
             if (isset($fieldMapping['length'])) {
1654
-                $column[] = 'length=' . $fieldMapping['length'];
1654
+                $column[] = 'length='.$fieldMapping['length'];
1655 1655
             }
1656 1656
 
1657 1657
             if (isset($fieldMapping['precision'])) {
1658
-                $column[] = 'precision=' .  $fieldMapping['precision'];
1658
+                $column[] = 'precision='.$fieldMapping['precision'];
1659 1659
             }
1660 1660
 
1661 1661
             if (isset($fieldMapping['scale'])) {
1662
-                $column[] = 'scale=' . $fieldMapping['scale'];
1662
+                $column[] = 'scale='.$fieldMapping['scale'];
1663 1663
             }
1664 1664
 
1665 1665
             if (isset($fieldMapping['nullable'])) {
1666
-                $column[] = 'nullable=' .  var_export($fieldMapping['nullable'], true);
1666
+                $column[] = 'nullable='.var_export($fieldMapping['nullable'], true);
1667 1667
             }
1668 1668
 
1669 1669
             $options = [];
1670 1670
 
1671 1671
             if (isset($fieldMapping['options']['default']) && $fieldMapping['options']['default']) {
1672
-                $options[] = '"default"="' . $fieldMapping['options']['default'] .'"';
1672
+                $options[] = '"default"="'.$fieldMapping['options']['default'].'"';
1673 1673
             }
1674 1674
 
1675 1675
             if (isset($fieldMapping['options']['unsigned']) && $fieldMapping['options']['unsigned']) {
@@ -1681,15 +1681,15 @@  discard block
 block discarded – undo
1681 1681
             }
1682 1682
 
1683 1683
             if (isset($fieldMapping['options']['comment']) && $fieldMapping['options']['comment']) {
1684
-                $options[] = '"comment"="' . $fieldMapping['options']['comment'] .'"';
1684
+                $options[] = '"comment"="'.$fieldMapping['options']['comment'].'"';
1685 1685
             }
1686 1686
 
1687 1687
             if (isset($fieldMapping['options']['collation']) && $fieldMapping['options']['collation']) {
1688
-                $options[] = '"collation"="' . $fieldMapping['options']['collation'] .'"';
1688
+                $options[] = '"collation"="'.$fieldMapping['options']['collation'].'"';
1689 1689
             }
1690 1690
 
1691 1691
             if (isset($fieldMapping['options']['check']) && $fieldMapping['options']['check']) {
1692
-                $options[] = '"check"="' . $fieldMapping['options']['check'] .'"';
1692
+                $options[] = '"check"="'.$fieldMapping['options']['check'].'"';
1693 1693
             }
1694 1694
 
1695 1695
             if ($options) {
@@ -1697,47 +1697,47 @@  discard block
 block discarded – undo
1697 1697
             }
1698 1698
 
1699 1699
             if (isset($fieldMapping['columnDefinition'])) {
1700
-                $column[] = 'columnDefinition="' . $fieldMapping['columnDefinition'] . '"';
1700
+                $column[] = 'columnDefinition="'.$fieldMapping['columnDefinition'].'"';
1701 1701
             }
1702 1702
 
1703 1703
             if (isset($fieldMapping['unique'])) {
1704
-                $column[] = 'unique=' . var_export($fieldMapping['unique'], true);
1704
+                $column[] = 'unique='.var_export($fieldMapping['unique'], true);
1705 1705
             }
1706 1706
 
1707
-            $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Column(' . implode(', ', $column) . ')';
1707
+            $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Column('.implode(', ', $column).')';
1708 1708
 
1709 1709
             if (isset($fieldMapping['id']) && $fieldMapping['id']) {
1710
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Id';
1710
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Id';
1711 1711
 
1712 1712
                 if ($generatorType = $this->getIdGeneratorTypeString($metadata->generatorType)) {
1713
-                    $lines[] = $this->spaces.' * @' . $this->annotationsPrefix . 'GeneratedValue(strategy="' . $generatorType . '")';
1713
+                    $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'GeneratedValue(strategy="'.$generatorType.'")';
1714 1714
                 }
1715 1715
 
1716 1716
                 if ($metadata->sequenceGeneratorDefinition) {
1717 1717
                     $sequenceGenerator = [];
1718 1718
 
1719 1719
                     if (isset($metadata->sequenceGeneratorDefinition['sequenceName'])) {
1720
-                        $sequenceGenerator[] = 'sequenceName="' . $metadata->sequenceGeneratorDefinition['sequenceName'] . '"';
1720
+                        $sequenceGenerator[] = 'sequenceName="'.$metadata->sequenceGeneratorDefinition['sequenceName'].'"';
1721 1721
                     }
1722 1722
 
1723 1723
                     if (isset($metadata->sequenceGeneratorDefinition['allocationSize'])) {
1724
-                        $sequenceGenerator[] = 'allocationSize=' . $metadata->sequenceGeneratorDefinition['allocationSize'];
1724
+                        $sequenceGenerator[] = 'allocationSize='.$metadata->sequenceGeneratorDefinition['allocationSize'];
1725 1725
                     }
1726 1726
 
1727 1727
                     if (isset($metadata->sequenceGeneratorDefinition['initialValue'])) {
1728
-                        $sequenceGenerator[] = 'initialValue=' . $metadata->sequenceGeneratorDefinition['initialValue'];
1728
+                        $sequenceGenerator[] = 'initialValue='.$metadata->sequenceGeneratorDefinition['initialValue'];
1729 1729
                     }
1730 1730
 
1731
-                    $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'SequenceGenerator(' . implode(', ', $sequenceGenerator) . ')';
1731
+                    $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'SequenceGenerator('.implode(', ', $sequenceGenerator).')';
1732 1732
                 }
1733 1733
             }
1734 1734
 
1735 1735
             if (isset($fieldMapping['version']) && $fieldMapping['version']) {
1736
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Version';
1736
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Version';
1737 1737
             }
1738 1738
         }
1739 1739
 
1740
-        $lines[] = $this->spaces . ' */';
1740
+        $lines[] = $this->spaces.' */';
1741 1741
 
1742 1742
         return implode("\n", $lines);
1743 1743
     }
@@ -1750,27 +1750,27 @@  discard block
 block discarded – undo
1750 1750
     protected function generateEmbeddedPropertyDocBlock(array $embeddedClass)
1751 1751
     {
1752 1752
         $lines = [];
1753
-        $lines[] = $this->spaces . '/**';
1754
-        $lines[] = $this->spaces . ' * @var \\' . ltrim($embeddedClass['class'], '\\');
1753
+        $lines[] = $this->spaces.'/**';
1754
+        $lines[] = $this->spaces.' * @var \\'.ltrim($embeddedClass['class'], '\\');
1755 1755
 
1756 1756
         if ($this->generateAnnotations) {
1757
-            $lines[] = $this->spaces . ' *';
1757
+            $lines[] = $this->spaces.' *';
1758 1758
 
1759
-            $embedded = ['class="' . $embeddedClass['class'] . '"'];
1759
+            $embedded = ['class="'.$embeddedClass['class'].'"'];
1760 1760
 
1761 1761
             if (isset($embeddedClass['columnPrefix'])) {
1762 1762
                 if (is_string($embeddedClass['columnPrefix'])) {
1763
-                    $embedded[] = 'columnPrefix="' . $embeddedClass['columnPrefix'] . '"';
1763
+                    $embedded[] = 'columnPrefix="'.$embeddedClass['columnPrefix'].'"';
1764 1764
                 } else {
1765
-                    $embedded[] = 'columnPrefix=' . var_export($embeddedClass['columnPrefix'], true);
1765
+                    $embedded[] = 'columnPrefix='.var_export($embeddedClass['columnPrefix'], true);
1766 1766
                 }
1767 1767
             }
1768 1768
 
1769
-            $lines[] = $this->spaces . ' * @' .
1770
-                $this->annotationsPrefix . 'Embedded(' . implode(', ', $embedded) . ')';
1769
+            $lines[] = $this->spaces.' * @'.
1770
+                $this->annotationsPrefix.'Embedded('.implode(', ', $embedded).')';
1771 1771
         }
1772 1772
 
1773
-        $lines[] = $this->spaces . ' */';
1773
+        $lines[] = $this->spaces.' */';
1774 1774
 
1775 1775
         return implode("\n", $lines);
1776 1776
     }
@@ -1784,13 +1784,13 @@  discard block
 block discarded – undo
1784 1784
         $processedClasses = [];
1785 1785
         foreach ($metadata->entityListeners as $event => $eventListeners) {
1786 1786
             foreach ($eventListeners as $eventListener) {
1787
-                $processedClasses[] = '"' . $eventListener['class'] . '"';
1787
+                $processedClasses[] = '"'.$eventListener['class'].'"';
1788 1788
             }
1789 1789
         }
1790 1790
 
1791 1791
         return \sprintf(
1792 1792
             '%s%s({%s})',
1793
-            '@' . $this->annotationsPrefix,
1793
+            '@'.$this->annotationsPrefix,
1794 1794
             'EntityListeners',
1795 1795
             \implode(',', \array_unique($processedClasses))
1796 1796
         );
@@ -1808,7 +1808,7 @@  discard block
 block discarded – undo
1808 1808
 
1809 1809
         foreach ($lines as $key => $value) {
1810 1810
             if ( ! empty($value)) {
1811
-                $lines[$key] = str_repeat($this->spaces, $num) . $lines[$key];
1811
+                $lines[$key] = str_repeat($this->spaces, $num).$lines[$key];
1812 1812
             }
1813 1813
         }
1814 1814
 
@@ -1890,9 +1890,9 @@  discard block
 block discarded – undo
1890 1890
 
1891 1891
         foreach ($options as $name => $option) {
1892 1892
             if (is_array($option)) {
1893
-                $optionsStr[] = '"' . $name . '"={' . $this->exportTableOptions($option) . '}';
1893
+                $optionsStr[] = '"'.$name.'"={'.$this->exportTableOptions($option).'}';
1894 1894
             } else {
1895
-                $optionsStr[] = '"' . $name . '"="' . (string) $option . '"';
1895
+                $optionsStr[] = '"'.$name.'"="'.(string) $option.'"';
1896 1896
             }
1897 1897
         }
1898 1898
 
Please login to merge, or discard this patch.