add environment variables support (#255)

This commit is contained in:
sunxyw
2023-01-15 21:30:44 +08:00
committed by GitHub
parent a420c3ab23
commit ca1d2a1ed8
7 changed files with 147 additions and 5 deletions

View File

@@ -0,0 +1,23 @@
<?php
declare(strict_types=1);
namespace ZM\Config;
interface EnvironmentInterface
{
/**
* 设置环境变量
*/
public function set(string $name, mixed $value): self;
/**
* 获取环境变量
*/
public function get(string $name, mixed $default = null): mixed;
/**
* 获取所有环境变量
*/
public function getAll(): array;
}