Completed
Pull Request — master (#6068)
by Javier
19:53 queued 08:50
created
lib/Doctrine/ORM/Tools/EntityGenerator.php 2 patches
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -1291,7 +1291,7 @@  discard block
 block discarded – undo
1291 1291
 
1292 1292
             $lines[] = $this->generateAssociationMappingPropertyDocBlock($associationMapping, $metadata);
1293 1293
             $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $associationMapping['fieldName']
1294
-                     . ($associationMapping['type'] == 'manyToMany' ? ' = array()' : null) . ";\n";
1294
+                        . ($associationMapping['type'] == 'manyToMany' ? ' = array()' : null) . ";\n";
1295 1295
         }
1296 1296
 
1297 1297
         return implode("\n", $lines);
@@ -1319,7 +1319,7 @@  discard block
 block discarded – undo
1319 1319
 
1320 1320
             $lines[] = $this->generateFieldMappingPropertyDocBlock($fieldMapping, $metadata);
1321 1321
             $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $fieldMapping['fieldName']
1322
-                     . (isset($fieldMapping['options']['default']) ? ' = ' . var_export($fieldMapping['options']['default'], true) : null) . ";\n";
1322
+                        . (isset($fieldMapping['options']['default']) ? ' = ' . var_export($fieldMapping['options']['default'], true) : null) . ";\n";
1323 1323
         }
1324 1324
 
1325 1325
         return implode("\n", $lines);
@@ -1382,14 +1382,14 @@  discard block
 block discarded – undo
1382 1382
         }
1383 1383
 
1384 1384
         $replacements = array(
1385
-          '<description>'       => ucfirst($type) . ' ' . $variableName,
1386
-          '<methodTypeHint>'    => $methodTypeHint,
1387
-          '<variableType>'      => $variableType . (null !== $defaultValue ? ('|' . $defaultValue) : ''),
1388
-          '<variableName>'      => $variableName,
1389
-          '<methodName>'        => $methodName,
1390
-          '<fieldName>'         => $fieldName,
1391
-          '<variableDefault>'   => ($defaultValue !== null ) ? (' = ' . $defaultValue) : '',
1392
-          '<entity>'            => $this->getClassName($metadata)
1385
+            '<description>'       => ucfirst($type) . ' ' . $variableName,
1386
+            '<methodTypeHint>'    => $methodTypeHint,
1387
+            '<variableType>'      => $variableType . (null !== $defaultValue ? ('|' . $defaultValue) : ''),
1388
+            '<variableName>'      => $variableName,
1389
+            '<methodName>'        => $methodName,
1390
+            '<fieldName>'         => $fieldName,
1391
+            '<variableDefault>'   => ($defaultValue !== null ) ? (' = ' . $defaultValue) : '',
1392
+            '<entity>'            => $this->getClassName($metadata)
1393 1393
         );
1394 1394
 
1395 1395
         $method = str_replace(
Please login to merge, or discard this patch.
Spacing   +142 added lines, -142 removed lines patch added patch discarded remove patch
@@ -364,14 +364,14 @@  discard block
 block discarded – undo
364 364
      */
365 365
     public function writeEntityClass(ClassMetadataInfo $metadata, $outputDirectory)
366 366
     {
367
-        $path = $outputDirectory . '/' . str_replace('\\', DIRECTORY_SEPARATOR, $metadata->name) . $this->extension;
367
+        $path = $outputDirectory.'/'.str_replace('\\', DIRECTORY_SEPARATOR, $metadata->name).$this->extension;
368 368
         $dir = dirname($path);
369 369
 
370 370
         if ( ! is_dir($dir)) {
371 371
             mkdir($dir, 0775, true);
372 372
         }
373 373
 
374
-        $this->isNew = !file_exists($path) || (file_exists($path) && $this->regenerateEntityIfExists);
374
+        $this->isNew = ! file_exists($path) || (file_exists($path) && $this->regenerateEntityIfExists);
375 375
 
376 376
         if ( ! $this->isNew) {
377 377
             $this->parseTokensInEntityFile(file_get_contents($path));
@@ -380,8 +380,8 @@  discard block
 block discarded – undo
380 380
         }
381 381
 
382 382
         if ($this->backupExisting && file_exists($path)) {
383
-            $backupPath = dirname($path) . DIRECTORY_SEPARATOR . basename($path) . "~";
384
-            if (!copy($path, $backupPath)) {
383
+            $backupPath = dirname($path).DIRECTORY_SEPARATOR.basename($path)."~";
384
+            if ( ! copy($path, $backupPath)) {
385 385
                 throw new \RuntimeException("Attempt to backup overwritten entity file but copy operation failed.");
386 386
             }
387 387
         }
@@ -421,7 +421,7 @@  discard block
 block discarded – undo
421 421
             $this->generateEntityBody($metadata)
422 422
         );
423 423
 
424
-        $code = str_replace($placeHolders, $replacements, static::$classTemplate) . "\n";
424
+        $code = str_replace($placeHolders, $replacements, static::$classTemplate)."\n";
425 425
 
426 426
         return str_replace('<spaces>', $this->spaces, $code);
427 427
     }
@@ -442,7 +442,7 @@  discard block
 block discarded – undo
442 442
         $body = str_replace('<spaces>', $this->spaces, $body);
443 443
         $last = strrpos($currentCode, '}');
444 444
 
445
-        return substr($currentCode, 0, $last) . $body . (strlen($body) > 0 ? "\n" : '') . "}\n";
445
+        return substr($currentCode, 0, $last).$body.(strlen($body) > 0 ? "\n" : '')."}\n";
446 446
     }
447 447
 
448 448
     /**
@@ -506,7 +506,7 @@  discard block
 block discarded – undo
506 506
     public function setFieldVisibility($visibility)
507 507
     {
508 508
         if ($visibility !== static::FIELD_VISIBLE_PRIVATE && $visibility !== static::FIELD_VISIBLE_PROTECTED) {
509
-            throw new \InvalidArgumentException('Invalid provided visibility (only private and protected are allowed): ' . $visibility);
509
+            throw new \InvalidArgumentException('Invalid provided visibility (only private and protected are allowed): '.$visibility);
510 510
         }
511 511
 
512 512
         $this->fieldVisibility = $visibility;
@@ -604,7 +604,7 @@  discard block
 block discarded – undo
604 604
     protected function generateEntityNamespace(ClassMetadataInfo $metadata)
605 605
     {
606 606
         if ($this->hasNamespace($metadata)) {
607
-            return 'namespace ' . $this->getNamespace($metadata) .';';
607
+            return 'namespace '.$this->getNamespace($metadata).';';
608 608
         }
609 609
     }
610 610
 
@@ -624,8 +624,8 @@  discard block
 block discarded – undo
624 624
      */
625 625
     protected function generateEntityClassName(ClassMetadataInfo $metadata)
626 626
     {
627
-        return 'class ' . $this->getClassName($metadata) .
628
-            ($this->extendsClass() ? ' extends ' . $this->getClassToExtendName() : null);
627
+        return 'class '.$this->getClassName($metadata).
628
+            ($this->extendsClass() ? ' extends '.$this->getClassToExtendName() : null);
629 629
     }
630 630
 
631 631
     /**
@@ -727,13 +727,13 @@  discard block
 block discarded – undo
727 727
         $fieldMappings = array_merge($requiredFields, $optionalFields);
728 728
 
729 729
         foreach ($metadata->embeddedClasses as $fieldName => $embeddedClass) {
730
-            $paramType = '\\' . ltrim($embeddedClass['class'], '\\');
731
-            $paramVariable = '$' . $fieldName;
730
+            $paramType = '\\'.ltrim($embeddedClass['class'], '\\');
731
+            $paramVariable = '$'.$fieldName;
732 732
 
733 733
             $paramTypes[] = $paramType;
734 734
             $paramVariables[] = $paramVariable;
735
-            $params[] = $paramType . ' ' . $paramVariable;
736
-            $fields[] = '$this->' . $fieldName . ' = ' . $paramVariable . ';';
735
+            $params[] = $paramType.' '.$paramVariable;
736
+            $fields[] = '$this->'.$fieldName.' = '.$paramVariable.';';
737 737
         }
738 738
 
739 739
         foreach ($fieldMappings as $fieldMapping) {
@@ -743,27 +743,27 @@  discard block
 block discarded – undo
743 743
                 continue;
744 744
             }
745 745
 
746
-            $paramTypes[] = $this->getType($fieldMapping['type']) . (!empty($fieldMapping['nullable']) ? '|null' : '');
747
-            $param = '$' . $fieldMapping['fieldName'];
746
+            $paramTypes[] = $this->getType($fieldMapping['type']).( ! empty($fieldMapping['nullable']) ? '|null' : '');
747
+            $param = '$'.$fieldMapping['fieldName'];
748 748
             $paramVariables[] = $param;
749 749
 
750 750
             if ($fieldMapping['type'] === 'datetime') {
751
-                $param = $this->getType($fieldMapping['type']) . ' ' . $param;
751
+                $param = $this->getType($fieldMapping['type']).' '.$param;
752 752
             }
753 753
 
754
-            if (!empty($fieldMapping['nullable'])) {
754
+            if ( ! empty($fieldMapping['nullable'])) {
755 755
                 $param .= ' = null';
756 756
             }
757 757
 
758 758
             $params[] = $param;
759 759
 
760
-            $fields[] = '$this->' . $fieldMapping['fieldName'] . ' = $' . $fieldMapping['fieldName'] . ';';
760
+            $fields[] = '$this->'.$fieldMapping['fieldName'].' = $'.$fieldMapping['fieldName'].';';
761 761
         }
762 762
 
763 763
         $maxParamTypeLength = max(array_map('strlen', $paramTypes));
764 764
         $paramTags = array_map(
765
-            function ($type, $variable) use ($maxParamTypeLength) {
766
-                return '@param ' . $type . str_repeat(' ', $maxParamTypeLength - strlen($type) + 1) . $variable;
765
+            function($type, $variable) use ($maxParamTypeLength) {
766
+                return '@param '.$type.str_repeat(' ', $maxParamTypeLength - strlen($type) + 1).$variable;
767 767
             },
768 768
             $paramTypes,
769 769
             $paramVariables
@@ -771,8 +771,8 @@  discard block
 block discarded – undo
771 771
 
772 772
         // Generate multi line constructor if the signature exceeds 120 characters.
773 773
         if (array_sum(array_map('strlen', $params)) + count($params) * 2 + 29 > 120) {
774
-            $delimiter = "\n" . $this->spaces;
775
-            $params = $delimiter . implode(',' . $delimiter, $params) . "\n";
774
+            $delimiter = "\n".$this->spaces;
775
+            $params = $delimiter.implode(','.$delimiter, $params)."\n";
776 776
         } else {
777 777
             $params = implode(', ', $params);
778 778
         }
@@ -780,7 +780,7 @@  discard block
 block discarded – undo
780 780
         $replacements = array(
781 781
             '<paramTags>' => implode("\n * ", $paramTags),
782 782
             '<params>'    => $params,
783
-            '<fields>'    => implode("\n" . $this->spaces, $fields),
783
+            '<fields>'    => implode("\n".$this->spaces, $fields),
784 784
         );
785 785
 
786 786
         $constructor = str_replace(
@@ -824,7 +824,7 @@  discard block
 block discarded – undo
824 824
 
825 825
             if ($inClass) {
826 826
                 $inClass = false;
827
-                $lastSeenClass = $lastSeenNamespace . ($lastSeenNamespace ? '\\' : '') . $token[1];
827
+                $lastSeenClass = $lastSeenNamespace.($lastSeenNamespace ? '\\' : '').$token[1];
828 828
                 $this->staticReflection[$lastSeenClass]['properties'] = array();
829 829
                 $this->staticReflection[$lastSeenClass]['methods'] = array();
830 830
             }
@@ -832,16 +832,16 @@  discard block
 block discarded – undo
832 832
             if ($token[0] == T_NAMESPACE) {
833 833
                 $lastSeenNamespace = "";
834 834
                 $inNamespace = true;
835
-            } elseif ($token[0] == T_CLASS && $tokens[$i-1][0] != T_DOUBLE_COLON) {
835
+            } elseif ($token[0] == T_CLASS && $tokens[$i - 1][0] != T_DOUBLE_COLON) {
836 836
                 $inClass = true;
837 837
             } elseif ($token[0] == T_FUNCTION) {
838
-                if ($tokens[$i+2][0] == T_STRING) {
839
-                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i+2][1]);
840
-                } elseif ($tokens[$i+2] == "&" && $tokens[$i+3][0] == T_STRING) {
841
-                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i+3][1]);
838
+                if ($tokens[$i + 2][0] == T_STRING) {
839
+                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i + 2][1]);
840
+                } elseif ($tokens[$i + 2] == "&" && $tokens[$i + 3][0] == T_STRING) {
841
+                    $this->staticReflection[$lastSeenClass]['methods'][] = strtolower($tokens[$i + 3][1]);
842 842
                 }
843
-            } elseif (in_array($token[0], array(T_VAR, T_PUBLIC, T_PRIVATE, T_PROTECTED)) && $tokens[$i+2][0] != T_FUNCTION) {
844
-                $this->staticReflection[$lastSeenClass]['properties'][] = substr($tokens[$i+2][1], 1);
843
+            } elseif (in_array($token[0], array(T_VAR, T_PUBLIC, T_PRIVATE, T_PROTECTED)) && $tokens[$i + 2][0] != T_FUNCTION) {
844
+                $this->staticReflection[$lastSeenClass]['properties'][] = substr($tokens[$i + 2][1], 1);
845 845
             }
846 846
         }
847 847
     }
@@ -854,7 +854,7 @@  discard block
 block discarded – undo
854 854
      */
855 855
     protected function hasProperty($property, ClassMetadataInfo $metadata)
856 856
     {
857
-        if ($this->extendsClass() || (!$this->isNew && class_exists($metadata->name))) {
857
+        if ($this->extendsClass() || ( ! $this->isNew && class_exists($metadata->name))) {
858 858
             // don't generate property if its already on the base class.
859 859
             $reflClass = new \ReflectionClass($this->getClassToExtend() ?: $metadata->name);
860 860
             if ($reflClass->hasProperty($property)) {
@@ -883,7 +883,7 @@  discard block
 block discarded – undo
883 883
      */
884 884
     protected function hasMethod($method, ClassMetadataInfo $metadata)
885 885
     {
886
-        if ($this->extendsClass() || (!$this->isNew && class_exists($metadata->name))) {
886
+        if ($this->extendsClass() || ( ! $this->isNew && class_exists($metadata->name))) {
887 887
             // don't generate method if its already on the base class.
888 888
             $reflClass = new \ReflectionClass($this->getClassToExtend() ?: $metadata->name);
889 889
 
@@ -912,7 +912,7 @@  discard block
 block discarded – undo
912 912
      */
913 913
     protected function getTraits(ClassMetadataInfo $metadata)
914 914
     {
915
-        if (! ($metadata->reflClass !== null || class_exists($metadata->name))) {
915
+        if ( ! ($metadata->reflClass !== null || class_exists($metadata->name))) {
916 916
             return [];
917 917
         }
918 918
 
@@ -964,7 +964,7 @@  discard block
 block discarded – undo
964 964
     {
965 965
         $refl = new \ReflectionClass($this->getClassToExtend());
966 966
 
967
-        return '\\' . $refl->getName();
967
+        return '\\'.$refl->getName();
968 968
     }
969 969
 
970 970
     /**
@@ -997,7 +997,7 @@  discard block
 block discarded – undo
997 997
     {
998 998
         $lines = array();
999 999
         $lines[] = '/**';
1000
-        $lines[] = ' * ' . $this->getClassName($metadata);
1000
+        $lines[] = ' * '.$this->getClassName($metadata);
1001 1001
 
1002 1002
         if ($this->generateAnnotations) {
1003 1003
             $lines[] = ' *';
@@ -1012,12 +1012,12 @@  discard block
 block discarded – undo
1012 1012
 
1013 1013
             foreach ($methods as $method) {
1014 1014
                 if ($code = $this->$method($metadata)) {
1015
-                    $lines[] = ' * ' . $code;
1015
+                    $lines[] = ' * '.$code;
1016 1016
                 }
1017 1017
             }
1018 1018
 
1019 1019
             if (isset($metadata->lifecycleCallbacks) && $metadata->lifecycleCallbacks) {
1020
-                $lines[] = ' * @' . $this->annotationsPrefix . 'HasLifecycleCallbacks';
1020
+                $lines[] = ' * @'.$this->annotationsPrefix.'HasLifecycleCallbacks';
1021 1021
             }
1022 1022
         }
1023 1023
 
@@ -1033,17 +1033,17 @@  discard block
 block discarded – undo
1033 1033
      */
1034 1034
     protected function generateEntityAnnotation(ClassMetadataInfo $metadata)
1035 1035
     {
1036
-        $prefix = '@' . $this->annotationsPrefix;
1036
+        $prefix = '@'.$this->annotationsPrefix;
1037 1037
 
1038 1038
         if ($metadata->isEmbeddedClass) {
1039
-            return $prefix . 'Embeddable';
1039
+            return $prefix.'Embeddable';
1040 1040
         }
1041 1041
 
1042 1042
         $customRepository = $metadata->customRepositoryClassName
1043
-            ? '(repositoryClass="' . $metadata->customRepositoryClassName . '")'
1043
+            ? '(repositoryClass="'.$metadata->customRepositoryClassName.'")'
1044 1044
             : '';
1045 1045
 
1046
-        return $prefix . ($metadata->isMappedSuperclass ? 'MappedSuperclass' : 'Entity') . $customRepository;
1046
+        return $prefix.($metadata->isMappedSuperclass ? 'MappedSuperclass' : 'Entity').$customRepository;
1047 1047
     }
1048 1048
 
1049 1049
     /**
@@ -1060,28 +1060,28 @@  discard block
 block discarded – undo
1060 1060
         $table = array();
1061 1061
 
1062 1062
         if (isset($metadata->table['schema'])) {
1063
-            $table[] = 'schema="' . $metadata->table['schema'] . '"';
1063
+            $table[] = 'schema="'.$metadata->table['schema'].'"';
1064 1064
         }
1065 1065
 
1066 1066
         if (isset($metadata->table['name'])) {
1067
-            $table[] = 'name="' . $metadata->table['name'] . '"';
1067
+            $table[] = 'name="'.$metadata->table['name'].'"';
1068 1068
         }
1069 1069
 
1070 1070
         if (isset($metadata->table['options']) && $metadata->table['options']) {
1071
-            $table[] = 'options={' . $this->exportTableOptions((array) $metadata->table['options']) . '}';
1071
+            $table[] = 'options={'.$this->exportTableOptions((array) $metadata->table['options']).'}';
1072 1072
         }
1073 1073
 
1074 1074
         if (isset($metadata->table['uniqueConstraints']) && $metadata->table['uniqueConstraints']) {
1075 1075
             $constraints = $this->generateTableConstraints('UniqueConstraint', $metadata->table['uniqueConstraints']);
1076
-            $table[] = 'uniqueConstraints={' . $constraints . '}';
1076
+            $table[] = 'uniqueConstraints={'.$constraints.'}';
1077 1077
         }
1078 1078
 
1079 1079
         if (isset($metadata->table['indexes']) && $metadata->table['indexes']) {
1080 1080
             $constraints = $this->generateTableConstraints('Index', $metadata->table['indexes']);
1081
-            $table[] = 'indexes={' . $constraints . '}';
1081
+            $table[] = 'indexes={'.$constraints.'}';
1082 1082
         }
1083 1083
 
1084
-        return '@' . $this->annotationsPrefix . 'Table(' . implode(', ', $table) . ')';
1084
+        return '@'.$this->annotationsPrefix.'Table('.implode(', ', $table).')';
1085 1085
     }
1086 1086
 
1087 1087
     /**
@@ -1096,9 +1096,9 @@  discard block
 block discarded – undo
1096 1096
         foreach ($constraints as $name => $constraint) {
1097 1097
             $columns = array();
1098 1098
             foreach ($constraint['columns'] as $column) {
1099
-                $columns[] = '"' . $column . '"';
1099
+                $columns[] = '"'.$column.'"';
1100 1100
             }
1101
-            $annotations[] = '@' . $this->annotationsPrefix . $constraintName . '(name="' . $name . '", columns={' . implode(', ', $columns) . '})';
1101
+            $annotations[] = '@'.$this->annotationsPrefix.$constraintName.'(name="'.$name.'", columns={'.implode(', ', $columns).'})';
1102 1102
         }
1103 1103
 
1104 1104
         return implode(', ', $annotations);
@@ -1112,7 +1112,7 @@  discard block
 block discarded – undo
1112 1112
     protected function generateInheritanceAnnotation($metadata)
1113 1113
     {
1114 1114
         if ($metadata->inheritanceType != ClassMetadataInfo::INHERITANCE_TYPE_NONE) {
1115
-            return '@' . $this->annotationsPrefix . 'InheritanceType("'.$this->getInheritanceTypeString($metadata->inheritanceType).'")';
1115
+            return '@'.$this->annotationsPrefix.'InheritanceType("'.$this->getInheritanceTypeString($metadata->inheritanceType).'")';
1116 1116
         }
1117 1117
     }
1118 1118
 
@@ -1125,11 +1125,11 @@  discard block
 block discarded – undo
1125 1125
     {
1126 1126
         if ($metadata->inheritanceType != ClassMetadataInfo::INHERITANCE_TYPE_NONE) {
1127 1127
             $discrColumn = $metadata->discriminatorColumn;
1128
-            $columnDefinition = 'name="' . $discrColumn['name']
1129
-                . '", type="' . $discrColumn['type']
1130
-                . '", length=' . $discrColumn['length'];
1128
+            $columnDefinition = 'name="'.$discrColumn['name']
1129
+                . '", type="'.$discrColumn['type']
1130
+                . '", length='.$discrColumn['length'];
1131 1131
 
1132
-            return '@' . $this->annotationsPrefix . 'DiscriminatorColumn(' . $columnDefinition . ')';
1132
+            return '@'.$this->annotationsPrefix.'DiscriminatorColumn('.$columnDefinition.')';
1133 1133
         }
1134 1134
     }
1135 1135
 
@@ -1144,10 +1144,10 @@  discard block
 block discarded – undo
1144 1144
             $inheritanceClassMap = array();
1145 1145
 
1146 1146
             foreach ($metadata->discriminatorMap as $type => $class) {
1147
-                $inheritanceClassMap[] .= '"' . $type . '" = "' . $class . '"';
1147
+                $inheritanceClassMap[] .= '"'.$type.'" = "'.$class.'"';
1148 1148
             }
1149 1149
 
1150
-            return '@' . $this->annotationsPrefix . 'DiscriminatorMap({' . implode(', ', $inheritanceClassMap) . '})';
1150
+            return '@'.$this->annotationsPrefix.'DiscriminatorMap({'.implode(', ', $inheritanceClassMap).'})';
1151 1151
         }
1152 1152
     }
1153 1153
 
@@ -1171,7 +1171,7 @@  discard block
 block discarded – undo
1171 1171
             if (( ! isset($fieldMapping['id']) ||
1172 1172
                     ! $fieldMapping['id'] ||
1173 1173
                     $metadata->generatorType == ClassMetadataInfo::GENERATOR_TYPE_NONE
1174
-                ) && (! $metadata->isEmbeddedClass || ! $this->embeddablesImmutable)
1174
+                ) && ( ! $metadata->isEmbeddedClass || ! $this->embeddablesImmutable)
1175 1175
             ) {
1176 1176
                 if ($code = $this->generateEntityStubMethod($metadata, 'set', $fieldMapping['fieldName'], $fieldMapping['type'], $nullableField)) {
1177 1177
                     $methods[] = $code;
@@ -1243,7 +1243,7 @@  discard block
 block discarded – undo
1243 1243
         }
1244 1244
 
1245 1245
         foreach ($joinColumns as $joinColumn) {
1246
-            if (isset($joinColumn['nullable']) && !$joinColumn['nullable']) {
1246
+            if (isset($joinColumn['nullable']) && ! $joinColumn['nullable']) {
1247 1247
                 return false;
1248 1248
             }
1249 1249
         }
@@ -1290,8 +1290,8 @@  discard block
 block discarded – undo
1290 1290
             }
1291 1291
 
1292 1292
             $lines[] = $this->generateAssociationMappingPropertyDocBlock($associationMapping, $metadata);
1293
-            $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $associationMapping['fieldName']
1294
-                     . ($associationMapping['type'] == 'manyToMany' ? ' = array()' : null) . ";\n";
1293
+            $lines[] = $this->spaces.$this->fieldVisibility.' $'.$associationMapping['fieldName']
1294
+                     . ($associationMapping['type'] == 'manyToMany' ? ' = array()' : null).";\n";
1295 1295
         }
1296 1296
 
1297 1297
         return implode("\n", $lines);
@@ -1318,8 +1318,8 @@  discard block
 block discarded – undo
1318 1318
             }
1319 1319
 
1320 1320
             $lines[] = $this->generateFieldMappingPropertyDocBlock($fieldMapping, $metadata);
1321
-            $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $fieldMapping['fieldName']
1322
-                     . (isset($fieldMapping['options']['default']) ? ' = ' . var_export($fieldMapping['options']['default'], true) : null) . ";\n";
1321
+            $lines[] = $this->spaces.$this->fieldVisibility.' $'.$fieldMapping['fieldName']
1322
+                     . (isset($fieldMapping['options']['default']) ? ' = '.var_export($fieldMapping['options']['default'], true) : null).";\n";
1323 1323
         }
1324 1324
 
1325 1325
         return implode("\n", $lines);
@@ -1340,7 +1340,7 @@  discard block
 block discarded – undo
1340 1340
             }
1341 1341
 
1342 1342
             $lines[] = $this->generateEmbeddedPropertyDocBlock($embeddedClass);
1343
-            $lines[] = $this->spaces . $this->fieldVisibility . ' $' . $fieldName . ";\n";
1343
+            $lines[] = $this->spaces.$this->fieldVisibility.' $'.$fieldName.";\n";
1344 1344
         }
1345 1345
 
1346 1346
         return implode("\n", $lines);
@@ -1357,7 +1357,7 @@  discard block
 block discarded – undo
1357 1357
      */
1358 1358
     protected function generateEntityStubMethod(ClassMetadataInfo $metadata, $type, $fieldName, $typeHint = null, $defaultValue = null)
1359 1359
     {
1360
-        $methodName = $type . Inflector::classify($fieldName);
1360
+        $methodName = $type.Inflector::classify($fieldName);
1361 1361
         $variableName = Inflector::camelize($fieldName);
1362 1362
         if (in_array($type, array("add", "remove"))) {
1363 1363
             $methodName = Inflector::singularize($methodName);
@@ -1377,18 +1377,18 @@  discard block
 block discarded – undo
1377 1377
         $variableType   = $typeHint ? $this->getType($typeHint) : null;
1378 1378
 
1379 1379
         if ($typeHint && ! isset($types[$typeHint])) {
1380
-            $variableType   =  '\\' . ltrim($variableType, '\\');
1381
-            $methodTypeHint =  '\\' . $typeHint . ' ';
1380
+            $variableType   = '\\'.ltrim($variableType, '\\');
1381
+            $methodTypeHint = '\\'.$typeHint.' ';
1382 1382
         }
1383 1383
 
1384 1384
         $replacements = array(
1385
-          '<description>'       => ucfirst($type) . ' ' . $variableName,
1385
+          '<description>'       => ucfirst($type).' '.$variableName,
1386 1386
           '<methodTypeHint>'    => $methodTypeHint,
1387
-          '<variableType>'      => $variableType . (null !== $defaultValue ? ('|' . $defaultValue) : ''),
1387
+          '<variableType>'      => $variableType.(null !== $defaultValue ? ('|'.$defaultValue) : ''),
1388 1388
           '<variableName>'      => $variableName,
1389 1389
           '<methodName>'        => $methodName,
1390 1390
           '<fieldName>'         => $fieldName,
1391
-          '<variableDefault>'   => ($defaultValue !== null ) ? (' = ' . $defaultValue) : '',
1391
+          '<variableDefault>'   => ($defaultValue !== null) ? (' = '.$defaultValue) : '',
1392 1392
           '<entity>'            => $this->getClassName($metadata)
1393 1393
         );
1394 1394
 
@@ -1416,7 +1416,7 @@  discard block
 block discarded – undo
1416 1416
         $this->staticReflection[$metadata->name]['methods'][] = $methodName;
1417 1417
 
1418 1418
         $replacements = array(
1419
-            '<name>'        => $this->annotationsPrefix . ucfirst($name),
1419
+            '<name>'        => $this->annotationsPrefix.ucfirst($name),
1420 1420
             '<methodName>'  => $methodName,
1421 1421
         );
1422 1422
 
@@ -1439,30 +1439,30 @@  discard block
 block discarded – undo
1439 1439
         $joinColumnAnnot = array();
1440 1440
 
1441 1441
         if (isset($joinColumn['name'])) {
1442
-            $joinColumnAnnot[] = 'name="' . $joinColumn['name'] . '"';
1442
+            $joinColumnAnnot[] = 'name="'.$joinColumn['name'].'"';
1443 1443
         }
1444 1444
 
1445 1445
         if (isset($joinColumn['referencedColumnName'])) {
1446
-            $joinColumnAnnot[] = 'referencedColumnName="' . $joinColumn['referencedColumnName'] . '"';
1446
+            $joinColumnAnnot[] = 'referencedColumnName="'.$joinColumn['referencedColumnName'].'"';
1447 1447
         }
1448 1448
 
1449 1449
         if (isset($joinColumn['unique']) && $joinColumn['unique']) {
1450
-            $joinColumnAnnot[] = 'unique=' . ($joinColumn['unique'] ? 'true' : 'false');
1450
+            $joinColumnAnnot[] = 'unique='.($joinColumn['unique'] ? 'true' : 'false');
1451 1451
         }
1452 1452
 
1453 1453
         if (isset($joinColumn['nullable'])) {
1454
-            $joinColumnAnnot[] = 'nullable=' . ($joinColumn['nullable'] ? 'true' : 'false');
1454
+            $joinColumnAnnot[] = 'nullable='.($joinColumn['nullable'] ? 'true' : 'false');
1455 1455
         }
1456 1456
 
1457 1457
         if (isset($joinColumn['onDelete'])) {
1458
-            $joinColumnAnnot[] = 'onDelete="' . ($joinColumn['onDelete'] . '"');
1458
+            $joinColumnAnnot[] = 'onDelete="'.($joinColumn['onDelete'].'"');
1459 1459
         }
1460 1460
 
1461 1461
         if (isset($joinColumn['columnDefinition'])) {
1462
-            $joinColumnAnnot[] = 'columnDefinition="' . $joinColumn['columnDefinition'] . '"';
1462
+            $joinColumnAnnot[] = 'columnDefinition="'.$joinColumn['columnDefinition'].'"';
1463 1463
         }
1464 1464
 
1465
-        return '@' . $this->annotationsPrefix . 'JoinColumn(' . implode(', ', $joinColumnAnnot) . ')';
1465
+        return '@'.$this->annotationsPrefix.'JoinColumn('.implode(', ', $joinColumnAnnot).')';
1466 1466
     }
1467 1467
 
1468 1468
     /**
@@ -1474,22 +1474,22 @@  discard block
 block discarded – undo
1474 1474
     protected function generateAssociationMappingPropertyDocBlock(array $associationMapping, ClassMetadataInfo $metadata)
1475 1475
     {
1476 1476
         $lines = array();
1477
-        $lines[] = $this->spaces . '/**';
1477
+        $lines[] = $this->spaces.'/**';
1478 1478
 
1479 1479
         if ($associationMapping['type'] & ClassMetadataInfo::TO_MANY) {
1480
-            $lines[] = $this->spaces . ' * @var \Doctrine\Common\Collections\Collection';
1480
+            $lines[] = $this->spaces.' * @var \Doctrine\Common\Collections\Collection';
1481 1481
         } else {
1482
-            $lines[] = $this->spaces . ' * @var \\' . ltrim($associationMapping['targetEntity'], '\\');
1482
+            $lines[] = $this->spaces.' * @var \\'.ltrim($associationMapping['targetEntity'], '\\');
1483 1483
         }
1484 1484
 
1485 1485
         if ($this->generateAnnotations) {
1486
-            $lines[] = $this->spaces . ' *';
1486
+            $lines[] = $this->spaces.' *';
1487 1487
 
1488 1488
             if (isset($associationMapping['id']) && $associationMapping['id']) {
1489
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Id';
1489
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Id';
1490 1490
 
1491 1491
                 if ($generatorType = $this->getIdGeneratorTypeString($metadata->generatorType)) {
1492
-                    $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'GeneratedValue(strategy="' . $generatorType . '")';
1492
+                    $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'GeneratedValue(strategy="'.$generatorType.'")';
1493 1493
                 }
1494 1494
             }
1495 1495
 
@@ -1511,15 +1511,15 @@  discard block
 block discarded – undo
1511 1511
             $typeOptions = array();
1512 1512
 
1513 1513
             if (isset($associationMapping['targetEntity'])) {
1514
-                $typeOptions[] = 'targetEntity="' . $associationMapping['targetEntity'] . '"';
1514
+                $typeOptions[] = 'targetEntity="'.$associationMapping['targetEntity'].'"';
1515 1515
             }
1516 1516
 
1517 1517
             if (isset($associationMapping['inversedBy'])) {
1518
-                $typeOptions[] = 'inversedBy="' . $associationMapping['inversedBy'] . '"';
1518
+                $typeOptions[] = 'inversedBy="'.$associationMapping['inversedBy'].'"';
1519 1519
             }
1520 1520
 
1521 1521
             if (isset($associationMapping['mappedBy'])) {
1522
-                $typeOptions[] = 'mappedBy="' . $associationMapping['mappedBy'] . '"';
1522
+                $typeOptions[] = 'mappedBy="'.$associationMapping['mappedBy'].'"';
1523 1523
             }
1524 1524
 
1525 1525
             if ($associationMapping['cascade']) {
@@ -1535,11 +1535,11 @@  discard block
 block discarded – undo
1535 1535
                     $cascades = array('"all"');
1536 1536
                 }
1537 1537
 
1538
-                $typeOptions[] = 'cascade={' . implode(',', $cascades) . '}';
1538
+                $typeOptions[] = 'cascade={'.implode(',', $cascades).'}';
1539 1539
             }
1540 1540
 
1541 1541
             if (isset($associationMapping['orphanRemoval']) && $associationMapping['orphanRemoval']) {
1542
-                $typeOptions[] = 'orphanRemoval=' . ($associationMapping['orphanRemoval'] ? 'true' : 'false');
1542
+                $typeOptions[] = 'orphanRemoval='.($associationMapping['orphanRemoval'] ? 'true' : 'false');
1543 1543
             }
1544 1544
 
1545 1545
             if (isset($associationMapping['fetch']) && $associationMapping['fetch'] !== ClassMetadataInfo::FETCH_LAZY) {
@@ -1548,71 +1548,71 @@  discard block
 block discarded – undo
1548 1548
                     ClassMetadataInfo::FETCH_EAGER      => 'EAGER',
1549 1549
                 );
1550 1550
 
1551
-                $typeOptions[] = 'fetch="' . $fetchMap[$associationMapping['fetch']] . '"';
1551
+                $typeOptions[] = 'fetch="'.$fetchMap[$associationMapping['fetch']].'"';
1552 1552
             }
1553 1553
 
1554
-            $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . '' . $type . '(' . implode(', ', $typeOptions) . ')';
1554
+            $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.''.$type.'('.implode(', ', $typeOptions).')';
1555 1555
 
1556 1556
             if (isset($associationMapping['joinColumns']) && $associationMapping['joinColumns']) {
1557
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'JoinColumns({';
1557
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'JoinColumns({';
1558 1558
 
1559 1559
                 $joinColumnsLines = array();
1560 1560
 
1561 1561
                 foreach ($associationMapping['joinColumns'] as $joinColumn) {
1562 1562
                     if ($joinColumnAnnot = $this->generateJoinColumnAnnotation($joinColumn)) {
1563
-                        $joinColumnsLines[] = $this->spaces . ' *   ' . $joinColumnAnnot;
1563
+                        $joinColumnsLines[] = $this->spaces.' *   '.$joinColumnAnnot;
1564 1564
                     }
1565 1565
                 }
1566 1566
 
1567 1567
                 $lines[] = implode(",\n", $joinColumnsLines);
1568
-                $lines[] = $this->spaces . ' * })';
1568
+                $lines[] = $this->spaces.' * })';
1569 1569
             }
1570 1570
 
1571 1571
             if (isset($associationMapping['joinTable']) && $associationMapping['joinTable']) {
1572 1572
                 $joinTable = array();
1573
-                $joinTable[] = 'name="' . $associationMapping['joinTable']['name'] . '"';
1573
+                $joinTable[] = 'name="'.$associationMapping['joinTable']['name'].'"';
1574 1574
 
1575 1575
                 if (isset($associationMapping['joinTable']['schema'])) {
1576
-                    $joinTable[] = 'schema="' . $associationMapping['joinTable']['schema'] . '"';
1576
+                    $joinTable[] = 'schema="'.$associationMapping['joinTable']['schema'].'"';
1577 1577
                 }
1578 1578
 
1579
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'JoinTable(' . implode(', ', $joinTable) . ',';
1580
-                $lines[] = $this->spaces . ' *   joinColumns={';
1579
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'JoinTable('.implode(', ', $joinTable).',';
1580
+                $lines[] = $this->spaces.' *   joinColumns={';
1581 1581
 
1582 1582
                 $joinColumnsLines = array();
1583 1583
 
1584 1584
                 foreach ($associationMapping['joinTable']['joinColumns'] as $joinColumn) {
1585
-                    $joinColumnsLines[] = $this->spaces . ' *     ' . $this->generateJoinColumnAnnotation($joinColumn);
1585
+                    $joinColumnsLines[] = $this->spaces.' *     '.$this->generateJoinColumnAnnotation($joinColumn);
1586 1586
                 }
1587 1587
 
1588
-                $lines[] = implode(",". PHP_EOL, $joinColumnsLines);
1589
-                $lines[] = $this->spaces . ' *   },';
1590
-                $lines[] = $this->spaces . ' *   inverseJoinColumns={';
1588
+                $lines[] = implode(",".PHP_EOL, $joinColumnsLines);
1589
+                $lines[] = $this->spaces.' *   },';
1590
+                $lines[] = $this->spaces.' *   inverseJoinColumns={';
1591 1591
 
1592 1592
                 $inverseJoinColumnsLines = array();
1593 1593
 
1594 1594
                 foreach ($associationMapping['joinTable']['inverseJoinColumns'] as $joinColumn) {
1595
-                    $inverseJoinColumnsLines[] = $this->spaces . ' *     ' . $this->generateJoinColumnAnnotation($joinColumn);
1595
+                    $inverseJoinColumnsLines[] = $this->spaces.' *     '.$this->generateJoinColumnAnnotation($joinColumn);
1596 1596
                 }
1597 1597
 
1598
-                $lines[] = implode(",". PHP_EOL, $inverseJoinColumnsLines);
1599
-                $lines[] = $this->spaces . ' *   }';
1600
-                $lines[] = $this->spaces . ' * )';
1598
+                $lines[] = implode(",".PHP_EOL, $inverseJoinColumnsLines);
1599
+                $lines[] = $this->spaces.' *   }';
1600
+                $lines[] = $this->spaces.' * )';
1601 1601
             }
1602 1602
 
1603 1603
             if (isset($associationMapping['orderBy'])) {
1604
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'OrderBy({';
1604
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'OrderBy({';
1605 1605
 
1606 1606
                 foreach ($associationMapping['orderBy'] as $name => $direction) {
1607
-                    $lines[] = $this->spaces . ' *     "' . $name . '"="' . $direction . '",';
1607
+                    $lines[] = $this->spaces.' *     "'.$name.'"="'.$direction.'",';
1608 1608
                 }
1609 1609
 
1610 1610
                 $lines[count($lines) - 1] = substr($lines[count($lines) - 1], 0, strlen($lines[count($lines) - 1]) - 1);
1611
-                $lines[] = $this->spaces . ' * })';
1611
+                $lines[] = $this->spaces.' * })';
1612 1612
             }
1613 1613
         }
1614 1614
 
1615
-        $lines[] = $this->spaces . ' */';
1615
+        $lines[] = $this->spaces.' */';
1616 1616
 
1617 1617
         return implode("\n", $lines);
1618 1618
     }
@@ -1626,35 +1626,35 @@  discard block
 block discarded – undo
1626 1626
     protected function generateFieldMappingPropertyDocBlock(array $fieldMapping, ClassMetadataInfo $metadata)
1627 1627
     {
1628 1628
         $lines = array();
1629
-        $lines[] = $this->spaces . '/**';
1630
-        $lines[] = $this->spaces . ' * @var ' . $this->getType($fieldMapping['type']) . ($this->getNullableField($fieldMapping) ? '|' . $this->getNullableField($fieldMapping) : '');;
1629
+        $lines[] = $this->spaces.'/**';
1630
+        $lines[] = $this->spaces.' * @var '.$this->getType($fieldMapping['type']).($this->getNullableField($fieldMapping) ? '|'.$this->getNullableField($fieldMapping) : ''); ;
1631 1631
 
1632 1632
         if ($this->generateAnnotations) {
1633
-            $lines[] = $this->spaces . ' *';
1633
+            $lines[] = $this->spaces.' *';
1634 1634
 
1635 1635
             $column = array();
1636 1636
             if (isset($fieldMapping['columnName'])) {
1637
-                $column[] = 'name="' . $fieldMapping['columnName'] . '"';
1637
+                $column[] = 'name="'.$fieldMapping['columnName'].'"';
1638 1638
             }
1639 1639
 
1640 1640
             if (isset($fieldMapping['type'])) {
1641
-                $column[] = 'type="' . $fieldMapping['type'] . '"';
1641
+                $column[] = 'type="'.$fieldMapping['type'].'"';
1642 1642
             }
1643 1643
 
1644 1644
             if (isset($fieldMapping['length'])) {
1645
-                $column[] = 'length=' . $fieldMapping['length'];
1645
+                $column[] = 'length='.$fieldMapping['length'];
1646 1646
             }
1647 1647
 
1648 1648
             if (isset($fieldMapping['precision'])) {
1649
-                $column[] = 'precision=' .  $fieldMapping['precision'];
1649
+                $column[] = 'precision='.$fieldMapping['precision'];
1650 1650
             }
1651 1651
 
1652 1652
             if (isset($fieldMapping['scale'])) {
1653
-                $column[] = 'scale=' . $fieldMapping['scale'];
1653
+                $column[] = 'scale='.$fieldMapping['scale'];
1654 1654
             }
1655 1655
 
1656 1656
             if (isset($fieldMapping['nullable'])) {
1657
-                $column[] = 'nullable=' .  var_export($fieldMapping['nullable'], true);
1657
+                $column[] = 'nullable='.var_export($fieldMapping['nullable'], true);
1658 1658
             }
1659 1659
 
1660 1660
             $options = [];
@@ -1668,47 +1668,47 @@  discard block
 block discarded – undo
1668 1668
             }
1669 1669
 
1670 1670
             if (isset($fieldMapping['columnDefinition'])) {
1671
-                $column[] = 'columnDefinition="' . $fieldMapping['columnDefinition'] . '"';
1671
+                $column[] = 'columnDefinition="'.$fieldMapping['columnDefinition'].'"';
1672 1672
             }
1673 1673
 
1674 1674
             if (isset($fieldMapping['unique'])) {
1675
-                $column[] = 'unique=' . var_export($fieldMapping['unique'], true);
1675
+                $column[] = 'unique='.var_export($fieldMapping['unique'], true);
1676 1676
             }
1677 1677
 
1678
-            $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Column(' . implode(', ', $column) . ')';
1678
+            $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Column('.implode(', ', $column).')';
1679 1679
 
1680 1680
             if (isset($fieldMapping['id']) && $fieldMapping['id']) {
1681
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Id';
1681
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Id';
1682 1682
 
1683 1683
                 if ($generatorType = $this->getIdGeneratorTypeString($metadata->generatorType)) {
1684
-                    $lines[] = $this->spaces.' * @' . $this->annotationsPrefix . 'GeneratedValue(strategy="' . $generatorType . '")';
1684
+                    $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'GeneratedValue(strategy="'.$generatorType.'")';
1685 1685
                 }
1686 1686
 
1687 1687
                 if ($metadata->sequenceGeneratorDefinition) {
1688 1688
                     $sequenceGenerator = array();
1689 1689
 
1690 1690
                     if (isset($metadata->sequenceGeneratorDefinition['sequenceName'])) {
1691
-                        $sequenceGenerator[] = 'sequenceName="' . $metadata->sequenceGeneratorDefinition['sequenceName'] . '"';
1691
+                        $sequenceGenerator[] = 'sequenceName="'.$metadata->sequenceGeneratorDefinition['sequenceName'].'"';
1692 1692
                     }
1693 1693
 
1694 1694
                     if (isset($metadata->sequenceGeneratorDefinition['allocationSize'])) {
1695
-                        $sequenceGenerator[] = 'allocationSize=' . $metadata->sequenceGeneratorDefinition['allocationSize'];
1695
+                        $sequenceGenerator[] = 'allocationSize='.$metadata->sequenceGeneratorDefinition['allocationSize'];
1696 1696
                     }
1697 1697
 
1698 1698
                     if (isset($metadata->sequenceGeneratorDefinition['initialValue'])) {
1699
-                        $sequenceGenerator[] = 'initialValue=' . $metadata->sequenceGeneratorDefinition['initialValue'];
1699
+                        $sequenceGenerator[] = 'initialValue='.$metadata->sequenceGeneratorDefinition['initialValue'];
1700 1700
                     }
1701 1701
 
1702
-                    $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'SequenceGenerator(' . implode(', ', $sequenceGenerator) . ')';
1702
+                    $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'SequenceGenerator('.implode(', ', $sequenceGenerator).')';
1703 1703
                 }
1704 1704
             }
1705 1705
 
1706 1706
             if (isset($fieldMapping['version']) && $fieldMapping['version']) {
1707
-                $lines[] = $this->spaces . ' * @' . $this->annotationsPrefix . 'Version';
1707
+                $lines[] = $this->spaces.' * @'.$this->annotationsPrefix.'Version';
1708 1708
             }
1709 1709
         }
1710 1710
 
1711
-        $lines[] = $this->spaces . ' */';
1711
+        $lines[] = $this->spaces.' */';
1712 1712
 
1713 1713
         return implode("\n", $lines);
1714 1714
     }
@@ -1721,23 +1721,23 @@  discard block
 block discarded – undo
1721 1721
     protected function generateEmbeddedPropertyDocBlock(array $embeddedClass)
1722 1722
     {
1723 1723
         $lines = array();
1724
-        $lines[] = $this->spaces . '/**';
1725
-        $lines[] = $this->spaces . ' * @var \\' . ltrim($embeddedClass['class'], '\\');
1724
+        $lines[] = $this->spaces.'/**';
1725
+        $lines[] = $this->spaces.' * @var \\'.ltrim($embeddedClass['class'], '\\');
1726 1726
 
1727 1727
         if ($this->generateAnnotations) {
1728
-            $lines[] = $this->spaces . ' *';
1728
+            $lines[] = $this->spaces.' *';
1729 1729
 
1730
-            $embedded = array('class="' . $embeddedClass['class'] . '"');
1730
+            $embedded = array('class="'.$embeddedClass['class'].'"');
1731 1731
 
1732 1732
             if (isset($fieldMapping['columnPrefix'])) {
1733
-                $embedded[] = 'columnPrefix=' . var_export($embeddedClass['columnPrefix'], true);
1733
+                $embedded[] = 'columnPrefix='.var_export($embeddedClass['columnPrefix'], true);
1734 1734
             }
1735 1735
 
1736
-            $lines[] = $this->spaces . ' * @' .
1737
-                $this->annotationsPrefix . 'Embedded(' . implode(', ', $embedded) . ')';
1736
+            $lines[] = $this->spaces.' * @'.
1737
+                $this->annotationsPrefix.'Embedded('.implode(', ', $embedded).')';
1738 1738
         }
1739 1739
 
1740
-        $lines[] = $this->spaces . ' */';
1740
+        $lines[] = $this->spaces.' */';
1741 1741
 
1742 1742
         return implode("\n", $lines);
1743 1743
     }
@@ -1754,7 +1754,7 @@  discard block
 block discarded – undo
1754 1754
 
1755 1755
         foreach ($lines as $key => $value) {
1756 1756
             if ( ! empty($value)) {
1757
-                $lines[$key] = str_repeat($this->spaces, $num) . $lines[$key];
1757
+                $lines[$key] = str_repeat($this->spaces, $num).$lines[$key];
1758 1758
             }
1759 1759
         }
1760 1760
 
@@ -1834,9 +1834,9 @@  discard block
 block discarded – undo
1834 1834
 
1835 1835
         foreach ($options as $name => $option) {
1836 1836
             if (is_array($option)) {
1837
-                $optionsStr[] = '"' . $name . '"={' . $this->exportTableOptions($option) . '}';
1837
+                $optionsStr[] = '"'.$name.'"={'.$this->exportTableOptions($option).'}';
1838 1838
             } else {
1839
-                $optionsStr[] = '"' . $name . '"="' . (string) $option . '"';
1839
+                $optionsStr[] = '"'.$name.'"="'.(string) $option.'"';
1840 1840
             }
1841 1841
         }
1842 1842
 
Please login to merge, or discard this patch.