@@ -139,7 +139,7 @@ |
||
| 139 | 139 | * @param Cache $cache The cache driver. |
| 140 | 140 | * @param string $namespace The cache namespace. |
| 141 | 141 | */ |
| 142 | - private static function setCache(Cache &$cacheToChange = null, Cache $cache = null, $namespace = null) |
|
| 142 | + private static function setCache(Cache & $cacheToChange = null, Cache $cache = null, $namespace = null) |
|
| 143 | 143 | { |
| 144 | 144 | if ($namespace === null) { |
| 145 | 145 | $namespace = self::$cacheDefaultNamespace; |
@@ -82,7 +82,7 @@ |
||
| 82 | 82 | /** |
| 83 | 83 | * Get the information on a class from its instance. |
| 84 | 84 | * |
| 85 | - * @param object $object |
|
| 85 | + * @param \Accessible\AutomatedBehaviorTrait $object |
|
| 86 | 86 | * |
| 87 | 87 | * @return array |
| 88 | 88 | */ |
@@ -26,7 +26,7 @@ discard block |
||
| 26 | 26 | */ |
| 27 | 27 | public static function getClassesToRead(\ReflectionObject $reflectionObject) |
| 28 | 28 | { |
| 29 | - $cacheId = md5("classesToRead:" . $reflectionObject->getName()); |
|
| 29 | + $cacheId = md5("classesToRead:".$reflectionObject->getName()); |
|
| 30 | 30 | $objectClasses = self::getFromCache($cacheId); |
| 31 | 31 | if ($objectClasses !== null) { |
| 32 | 32 | return $objectClasses; |
@@ -89,7 +89,7 @@ discard block |
||
| 89 | 89 | public static function getClassInformation($object) |
| 90 | 90 | { |
| 91 | 91 | $reflectionObject = new \ReflectionObject($object); |
| 92 | - $cacheId = md5("classInformation:" . $reflectionObject->getName()); |
|
| 92 | + $cacheId = md5("classInformation:".$reflectionObject->getName()); |
|
| 93 | 93 | $classInfo = self::getFromCache($cacheId); |
| 94 | 94 | if ($classInfo !== null) { |
| 95 | 95 | return $classInfo; |
@@ -119,7 +119,7 @@ discard block |
||
| 119 | 119 | foreach ($constraintsViolations as $violation) { |
| 120 | 120 | $errorMessageList[] = $violation->getMessage(); |
| 121 | 121 | } |
| 122 | - $errorMessage .= implode("\", \n\"", $errorMessageList) . "\"."; |
|
| 122 | + $errorMessage .= implode("\", \n\"", $errorMessageList)."\"."; |
|
| 123 | 123 | |
| 124 | 124 | throw new \InvalidArgumentException($errorMessage); |
| 125 | 125 | } |
@@ -147,8 +147,8 @@ discard block |
||
| 147 | 147 | $associatedProperty = $association['property']; |
| 148 | 148 | switch ($association['association']) { |
| 149 | 149 | case 'inverted': |
| 150 | - $invertedGetMethod = 'get' . ucfirst($associatedProperty); |
|
| 151 | - $invertedSetMethod = 'set' . ucfirst($associatedProperty); |
|
| 150 | + $invertedGetMethod = 'get'.ucfirst($associatedProperty); |
|
| 151 | + $invertedSetMethod = 'set'.ucfirst($associatedProperty); |
|
| 152 | 152 | if ($oldValue !== null && $oldValue->$invertedGetMethod() === $this) { |
| 153 | 153 | $oldValue->$invertedSetMethod(null); |
| 154 | 154 | } |
@@ -159,9 +159,9 @@ discard block |
||
| 159 | 159 | |
| 160 | 160 | case 'mapped': |
| 161 | 161 | $itemName = $association['itemName']; |
| 162 | - $mappedGetMethod = 'get' . ucfirst($associatedProperty); |
|
| 163 | - $mappedAddMethod = 'add' . ucfirst($itemName); |
|
| 164 | - $mappedRemoveMethod = 'remove' . ucfirst($itemName); |
|
| 162 | + $mappedGetMethod = 'get'.ucfirst($associatedProperty); |
|
| 163 | + $mappedAddMethod = 'add'.ucfirst($itemName); |
|
| 164 | + $mappedRemoveMethod = 'remove'.ucfirst($itemName); |
|
| 165 | 165 | |
| 166 | 166 | if ($oldValue !== null && CollectionManager::collectionContains($this, $oldValue->$mappedGetMethod())) { |
| 167 | 167 | $oldValue->$mappedRemoveMethod($this); |
@@ -55,8 +55,8 @@ |
||
| 55 | 55 | && !(empty($this->_associationsList[$property])) |
| 56 | 56 | ) { |
| 57 | 57 | $itemName = $this->_collectionsItemNames['byProperty'][$property]['itemName']; |
| 58 | - $propertyAddMethod = 'add' . ucfirst($itemName); |
|
| 59 | - $propertyRemoveMethod = 'remove' . ucfirst($itemName); |
|
| 58 | + $propertyAddMethod = 'add'.ucfirst($itemName); |
|
| 59 | + $propertyRemoveMethod = 'remove'.ucfirst($itemName); |
|
| 60 | 60 | |
| 61 | 61 | foreach ($this->$property as $item) { |
| 62 | 62 | $this->$propertyRemoveMethod($item); |