Files
expose/app/Server/Configuration.php
Marcel Pociot a972c8581c wip
2020-04-30 15:17:25 +02:00

41 lines
720 B
PHP

<?php
namespace App\Server;
class Configuration
{
/** @var string */
protected $hostname;
/** @var int */
protected $port;
public function __construct(string $hostname, int $port)
{
$this->hostname = $hostname;
$this->port = $port;
}
public function hostname(): string
{
return $this->hostname;
}
public function port(): int
{
return $this->port;
}
public function __isset($key)
{
return property_exists($this, $key) || ! is_null(config('expose.admin.'.$key));
}
public function __get($key)
{
dump(config('expose.admin'));
return $this->$key ?? config('expose.admin.'.$key);
}
}