This commit is contained in:
2021-03-08 15:07:52 +08:00
parent 5f83915a94
commit bdef22d202
+11
View File
@@ -69,6 +69,17 @@ class Router extends HttpService implements RouterInterface
}
/**
* @param $port
* @param Closure|array $closure
* @throws ConfigException
*/
public function addPortListen($port, Closure|array $closure)
{
$this->addRoute('add-port-listen/' . $port, $closure, 'listen');
}
/**
* @param $path
* @param $handler