protected function setHost($host)
    {
        $host = strtolower($host);
        
        if ($host !== '' && !$this->isValidDomain($host) && !$this->isValidIpv4($host) && !$this->isValidIpv6($host)) {
            throw new \InvalidArgumentException("Invalid hostname '$host'");
        }
        
        $this->host = $host;
    }
protected function setHost($host)
    {
        $host = strtolower($host);
        
        if ($host !== '' && !$this->isValidDomain($host) && !$this->isValidIpv4($host) && !$this->isValidIpv6($host)) {
            throw new \InvalidArgumentException("Invalid hostname '$host'");
        }
        
        $this->host = $host;
    }
protected function setHost ( $ host ) { $ host = strtolower ( $ host ) ; if ( $ host !== '' && ! $ this -> isValidDomain ( $ host ) && ! $ this -> isValidIpv4 ( $ host ) && ! $ this -> isValidIpv6 ( $ host ) ) { throw new \ InvalidArgumentException ( "Invalid hostname '$host'" ) ; } $ this -> host = $ host ; }
Set the host

@param string $host
Set the host