src/Routes/UrlManager.php
public function getHostInfo($app = null)
    {
        if ($app !== null && $app instanceof RequestApplicationInterface) {
            return $app->reqHelper->getHostInfo();
        }
        if ($this->_hostInfo === null) {
            throw new InvalidConfigException('Please configure UrlManager::hostInfo correctly if you are running a console application.');
        }
        return $this->_hostInfo;
    }
public function getHostInfo($app = null)
    {
        if ($app !== null && $app instanceof RequestApplicationInterface) {
            return $app->reqHelper->getHostInfo();
        }
        if ($this->_hostInfo === null) {
            throw new InvalidConfigException('Please configure UrlManager::hostInfo correctly if you are running a console application.');
        }
        return $this->_hostInfo;
    }
Getter for $hostInfo
@param RequestApplicationInterface|null $app
@return string