src/Control/HTTPRequest.php
public function setIP($ip)
    {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new InvalidArgumentException("Invalid ip $ip");
        }
        $this->ip = $ip;
        return $this;
    }
public function setIP($ip)
    {
        if (!filter_var($ip, FILTER_VALIDATE_IP)) {
            throw new InvalidArgumentException("Invalid ip $ip");
        }
        $this->ip = $ip;
        return $this;
    }
public function setIP ( $ ip ) { if ( ! filter_var ( $ ip , FILTER_VALIDATE_IP ) ) { throw new InvalidArgumentException ( "Invalid ip $ip" ) ; } $ this -> ip = $ ip ; return $ this ; }
Sets the client IP address which originated this request.
Use setIPFromHeaderValue if assigning from header value.

@param $ip string
@return $this
Sets the client IP address which originated this request . Use setIPFromHeaderValue if assigning from header value .