https://hyperf.wiki/3.0/#/zh-cn/di?id=%e4%be%9d%e8%b5%96%e6%b3%a8%e5%85%a5
private UserService $userService;
// 通过在构造函数的参数上声明参数类型完成自动注入
public function __construct(UserService $userService)
{
$this->userService = $userService;
}
use App\Service\UserService;
use Hyperf\Di\Annotation\Inject;
{
#[Inject]
private UserService $userService;
}