File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 16
16
use Geocoder \Exception \CollectionIsEmpty ;
17
17
use Geocoder \Exception \OutOfBounds ;
18
18
use Geocoder \Location ;
19
+ use Traversable ;
19
20
20
21
final class AddressCollection implements Collection
21
22
{
@@ -35,15 +36,15 @@ public function __construct(array $locations = [])
35
36
/**
36
37
* {@inheritdoc}
37
38
*/
38
- public function getIterator ()
39
+ public function getIterator (): Traversable
39
40
{
40
41
return new \ArrayIterator ($ this ->all ());
41
42
}
42
43
43
44
/**
44
45
* {@inheritdoc}
45
46
*/
46
- public function count ()
47
+ public function count (): int
47
48
{
48
49
return count ($ this ->locations );
49
50
}
Original file line number Diff line number Diff line change 15
15
use Geocoder \Exception \CollectionIsEmpty ;
16
16
use Geocoder \Exception \InvalidArgument ;
17
17
use Geocoder \Exception \OutOfBounds ;
18
+ use Traversable ;
18
19
19
20
/**
20
21
* @author Giorgio Premi <[email protected] >
@@ -53,15 +54,15 @@ public function __construct(array $adminLevels = [])
53
54
/**
54
55
* {@inheritdoc}
55
56
*/
56
- public function getIterator ()
57
+ public function getIterator (): Traversable
57
58
{
58
59
return new \ArrayIterator ($ this ->all ());
59
60
}
60
61
61
62
/**
62
63
* {@inheritdoc}
63
64
*/
64
- public function count ()
65
+ public function count (): int
65
66
{
66
67
return count ($ this ->adminLevels );
67
68
}
You can’t perform that action at this time.
0 commit comments