| Total Complexity | 4 |
| Total Lines | 47 |
| Duplicated Lines | 0 % |
| Coverage | 50% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | class GoogleMapsClient |
||
| 18 | { |
||
| 19 | |||
| 20 | /** |
||
| 21 | * @var Client |
||
| 22 | */ |
||
| 23 | protected $client = null; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * GeocoderClient constructor. |
||
| 27 | */ |
||
| 28 | 35 | public function __construct() |
|
| 29 | { |
||
| 30 | |||
| 31 | 35 | $this->setClient(new Client()); |
|
| 32 | 35 | } |
|
| 33 | |||
| 34 | /** |
||
| 35 | * @param null $client |
||
|
|
|||
| 36 | * |
||
| 37 | * @return GoogleMapsClient |
||
| 38 | */ |
||
| 39 | 35 | public function setClient($client) |
|
| 45 | } |
||
| 46 | |||
| 47 | /** |
||
| 48 | * @param string $url |
||
| 49 | * @param null|string $query |
||
| 50 | * |
||
| 51 | * @return \Biscolab\GoogleMaps\Http\GoogleMapsResponse |
||
| 52 | */ |
||
| 53 | public function get(string $url, ?string $query = null): GoogleMapsResponse |
||
| 64 | } |
||
| 65 | } |