@@ -43,7 +43,7 @@ |
||
43 | 43 | public function arrayToCollection(array $data, string $class):Traversable; |
44 | 44 | |
45 | 45 | /** |
46 | - * @param Entity[] $collection |
|
46 | + * @param Traversable $collection |
|
47 | 47 | * |
48 | 48 | * @return array |
49 | 49 | * |
@@ -34,7 +34,7 @@ |
||
34 | 34 | } |
35 | 35 | |
36 | 36 | /** |
37 | - * @return mixed |
|
37 | + * @return integer |
|
38 | 38 | */ |
39 | 39 | public function getValue() |
40 | 40 | { |
@@ -43,12 +43,14 @@ |
||
43 | 43 | /** |
44 | 44 | * @param Entity $entity |
45 | 45 | * |
46 | + * @return void |
|
46 | 47 | */ |
47 | 48 | public function save (Entity $entity); |
48 | 49 | |
49 | 50 | /** |
50 | 51 | * @param Entity $entity |
51 | 52 | * |
53 | + * @return void |
|
52 | 54 | */ |
53 | 55 | public function delete (Entity $entity); |
54 | 56 |
@@ -26,14 +26,14 @@ discard block |
||
26 | 26 | * |
27 | 27 | * @return Entity |
28 | 28 | */ |
29 | - public function get (EntityIndex $id):?Entity; |
|
29 | + public function get(EntityIndex $id): ? Entity; |
|
30 | 30 | |
31 | 31 | /** |
32 | 32 | * @param Criteria $criteria |
33 | 33 | * |
34 | 34 | * @return Iterator |
35 | 35 | */ |
36 | - public function getBy (Criteria $criteria):Iterator; |
|
36 | + public function getBy(Criteria $criteria):Iterator; |
|
37 | 37 | |
38 | 38 | /** |
39 | 39 | * @return Iterator |
@@ -44,18 +44,18 @@ discard block |
||
44 | 44 | * @param Entity $entity |
45 | 45 | * |
46 | 46 | */ |
47 | - public function save (Entity $entity); |
|
47 | + public function save(Entity $entity); |
|
48 | 48 | |
49 | 49 | /** |
50 | 50 | * @param Entity $entity |
51 | 51 | * |
52 | 52 | */ |
53 | - public function delete (Entity $entity); |
|
53 | + public function delete(Entity $entity); |
|
54 | 54 | |
55 | 55 | /** |
56 | 56 | * @param Entity $entity |
57 | 57 | * |
58 | 58 | * @return bool |
59 | 59 | */ |
60 | - public function exists (Entity $entity):bool; |
|
60 | + public function exists(Entity $entity):bool; |
|
61 | 61 | } |
62 | 62 | \ No newline at end of file |
@@ -84,7 +84,7 @@ |
||
84 | 84 | { |
85 | 85 | $result = []; |
86 | 86 | |
87 | - foreach($collection as $entity) { |
|
87 | + foreach ($collection as $entity) { |
|
88 | 88 | $result[] = $this->entityToArray($entity); |
89 | 89 | } |
90 | 90 |
@@ -33,7 +33,7 @@ |
||
33 | 33 | * |
34 | 34 | * @return Entity |
35 | 35 | */ |
36 | - public function get(EntityIndex $id):?Entity |
|
36 | + public function get(EntityIndex $id): ? Entity |
|
37 | 37 | { |
38 | 38 | return $this->collection->get((string)$id); |
39 | 39 | } |
@@ -34,7 +34,7 @@ |
||
34 | 34 | } |
35 | 35 | |
36 | 36 | /** |
37 | - * @return mixed |
|
37 | + * @return integer |
|
38 | 38 | */ |
39 | 39 | public function getValue() |
40 | 40 | { |