Completed
Push — master ( 7c792b...5c54ea )
by Bryan
01:53
created

location::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 5
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 3
nc 1
nop 2
1
<?php
2
namespace Bhhaskin\WeatherBee\Util;
3
4
/**
5
 * Class for handling location
6
 */
7
class location
8
{
9
10
    /**
11
     * Latitude of location.
12
     * @var float
13
     */
14
    public $lat;
15
16
    /**
17
     * Longitude of location.
18
     * @var float
19
     */
20
    public $lng;
21
22
    /**
23
     * Creates location object.
24
     * @param float $lat Latitude of location.
25
     * @param float $lng Longitude of location.
26
     */
27
    function __construct(float $lat = null, float $lng = null)
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
28
    {
29
        $this->lat = $lat;
30
        $this->lng = $lng;
31
    }
32
}
33