public function setParam($name, $value, $replace = true)
    {
        if (is_array($name)) {
            if (!isset($this->components[self::QUERY])) {
                $this->components[self::QUERY] = [];
            }
            TreeTools::setByPath($this->components[self::QUERY], $name, $value);
        } else {
            if (isset($this->components[self::QUERY][$name]) && !$replace) {
                return $this;
            }
            $this->components[self::QUERY][$name] = $value;
        }
        return $this;
    }