src/Http.php
public function encode($func = self::JSON, $is_clear = false) {
        if ($is_clear) {
            $this->encodeFunc = [];
        }
        $this->encodeFunc[] = $func;
        return $this;
    }
public function encode($func = self::JSON, $is_clear = false) {
        if ($is_clear) {
            $this->encodeFunc = [];
        }
        $this->encodeFunc[] = $func;
        return $this;
    }
编码
@param string|callable $func
@param bool $is_clear 清空原有的d
@return Http