finish acceptance tests and refactor IotaCodesClient to service container

This commit is contained in:
Richard Morgan
2017-05-15 22:14:14 -04:00
parent 2c8c692890
commit e4e17dedc5
13 changed files with 338 additions and 24 deletions

View File

@@ -3,17 +3,33 @@ namespace App\Libraries\IotaCodes;
class Airport
{
/**
* @var string
*/
public $name;
/**
* @var string
*/
public $code;
/**
* Airport constructor.
* @param $name
* @param $code
*/
protected function __construct($name, $code)
{
$this->name = $name;
$this->code = $code;
}
/**
* Airport factory method
* @param $name
* @param $code
* @return \App\Libraries\IotaCodes\Airport
*/
public static function create($name, $code)
{
return new self($name, $code);