@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | } |
51 | 51 | |
52 | 52 | /** |
53 | - * @param $name |
|
53 | + * @param integer $name |
|
54 | 54 | * |
55 | 55 | * @return BaseFilterInterface |
56 | 56 | */ |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | } |
93 | 93 | |
94 | 94 | /** |
95 | - * @param $name |
|
95 | + * @param integer $name |
|
96 | 96 | */ |
97 | 97 | protected function clearCollection($name) |
98 | 98 | { |
@@ -42,8 +42,8 @@ |
||
42 | 42 | /** |
43 | 43 | * Pageable constructor. |
44 | 44 | * |
45 | - * @param $pageNumber |
|
46 | - * @param $pageSize |
|
45 | + * @param integer $pageNumber |
|
46 | + * @param integer $pageSize |
|
47 | 47 | * @param SortInterface|null $sort |
48 | 48 | * @param FilterInterface|null $filter |
49 | 49 | * @param FieldsInterface|null $fields |
@@ -33,14 +33,14 @@ |
||
33 | 33 | /** @var Order $sortDirection */ |
34 | 34 | foreach ($sortOrder as $propertyName => $sortDirection) { |
35 | 35 | if ($sortDirection->isAscending()) { |
36 | - self::stableUasort($results, function ($a, $b) use ($propertyName) { |
|
36 | + self::stableUasort($results, function($a, $b) use ($propertyName) { |
|
37 | 37 | $value1 = (string) self::getValue($a, $propertyName); |
38 | 38 | $value2 = (string) self::getValue($b, $propertyName); |
39 | 39 | |
40 | 40 | return ((int) (strcmp($value1, $value2) >= 0)); |
41 | 41 | }); |
42 | 42 | } else { |
43 | - self::stableUasort($results, function ($a, $b) use ($propertyName) { |
|
43 | + self::stableUasort($results, function($a, $b) use ($propertyName) { |
|
44 | 44 | $value1 = (string) self::getValue($a, $propertyName); |
45 | 45 | $value2 = (string) self::getValue($b, $propertyName); |
46 | 46 |
@@ -41,7 +41,7 @@ |
||
41 | 41 | */ |
42 | 42 | protected function calculateIndexKey() |
43 | 43 | { |
44 | - $callable = function ($value) { |
|
44 | + $callable = function($value) { |
|
45 | 45 | return null !== $value; |
46 | 46 | }; |
47 | 47 |
@@ -53,8 +53,8 @@ discard block |
||
53 | 53 | * Page constructor. |
54 | 54 | * |
55 | 55 | * @param array $elements |
56 | - * @param $totalElements |
|
57 | - * @param $pageNumber |
|
56 | + * @param integer $totalElements |
|
57 | + * @param integer $pageNumber |
|
58 | 58 | * @param $totalPages |
59 | 59 | * @param SortInterface $sort |
60 | 60 | * @param FilterInterface $filter |
@@ -193,7 +193,7 @@ discard block |
||
193 | 193 | } |
194 | 194 | |
195 | 195 | /** |
196 | - * @return FieldsInterface |
|
196 | + * @return null|FieldsInterface |
|
197 | 197 | */ |
198 | 198 | public function getFields() |
199 | 199 | { |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | throw new ColorNotFoundException($id); |
46 | 46 | } |
47 | 47 | |
48 | - $id = (string)$id; |
|
48 | + $id = (string) $id; |
|
49 | 49 | |
50 | 50 | return clone $this->data[$id]; |
51 | 51 | } |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | */ |
86 | 86 | public function persist($value) |
87 | 87 | { |
88 | - $id = (string)$value->id(); |
|
88 | + $id = (string) $value->id(); |
|
89 | 89 | |
90 | 90 | $this->data[$id] = clone $value; |
91 | 91 | } |
@@ -154,7 +154,7 @@ discard block |
||
154 | 154 | */ |
155 | 155 | public function exists(Identity $id) |
156 | 156 | { |
157 | - $id = (string)$id; |
|
157 | + $id = (string) $id; |
|
158 | 158 | |
159 | 159 | return array_key_exists($id, $this->data); |
160 | 160 | } |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -include __DIR__ . '/../vendor/autoload.php'; |
|
3 | +include __DIR__.'/../vendor/autoload.php'; |
|
4 | 4 | |
5 | 5 | use NilPortugues\Example\Repository\Color; |
6 | 6 | use NilPortugues\Example\Repository\ColorRepository; |
@@ -60,6 +60,6 @@ |
||
60 | 60 | */ |
61 | 61 | public function __toString() |
62 | 62 | { |
63 | - return (string)$this->getHexCode(); |
|
63 | + return (string) $this->getHexCode(); |
|
64 | 64 | } |
65 | 65 | } |
@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | */ |
16 | 16 | public static function startsWith($property, $value) |
17 | 17 | { |
18 | - return function ($v) use ($property, $value) { |
|
18 | + return function($v) use ($property, $value) { |
|
19 | 19 | $v = InMemoryValue::get($v, $property); |
20 | 20 | |
21 | 21 | self::propertyGuard($v, $property); |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | */ |
60 | 60 | public static function endsWith($property, $value) |
61 | 61 | { |
62 | - return function ($v) use ($property, $value) { |
|
62 | + return function($v) use ($property, $value) { |
|
63 | 63 | $v = InMemoryValue::get($v, $property); |
64 | 64 | |
65 | 65 | self::propertyGuard($v, $property); |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | */ |
78 | 78 | public static function notStartsWith($property, $value) |
79 | 79 | { |
80 | - return function ($v) use ($property, $value) { |
|
80 | + return function($v) use ($property, $value) { |
|
81 | 81 | $v = InMemoryValue::get($v, $property); |
82 | 82 | |
83 | 83 | self::propertyGuard($v, $property); |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | */ |
96 | 96 | public static function notEndsWith($property, $value) |
97 | 97 | { |
98 | - return function ($v) use ($property, $value) { |
|
98 | + return function($v) use ($property, $value) { |
|
99 | 99 | $v = InMemoryValue::get($v, $property); |
100 | 100 | |
101 | 101 | self::propertyGuard($v, $property); |