Api\StructType\ApiSearchRequest::setVersion PHP Method

setVersion() public method

Set Version value
public setVersion ( string $version = '2.2' ) : ApiSearchRequest
$version string
return ApiSearchRequest
    public function setVersion($version = '2.2')
    {
        // validation for constraint: string
        if (!is_null($version) && !is_string($version)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($version)), __LINE__);
        }
        $this->Version = $version;
        return $this;
    }