设置请求头<br>
不覆盖原有请求头

@param headers 请求头
@return this
776382
public T header(Map<String, List<String>> headers) {
		return header(headers, false);
	}
318401
public function allowHeaders($headers = '*')
    {
        $this->response = $this->corsHandler->setResponse($this->response)
            ->allowHeaders($headers)
            ->getResponse();

        return $this;
    }
1187872
public function exposeHeaders($headers = '*')
    {
        $headers = array_map([HeaderHelper::class, 'normalizeHeaderName'], (array) $headers);
        $headers = implode(', ', $headers);

        $this->response = $this->response->withHeader('Access-Control-Allow-Headers', $headers);

        return $this;
    }
666413
public void setAllowHeaders(String... headers) {
        allowHeadersSet.clear();
        for (String header : headers) {
            allowHeadersSet.add(header.toLowerCase());
        }
        allowHeaders = Joiner.on(",").join(headers);
    }
902089
public void setDefaultHeaders(Collection<? extends Header> defaultHeaders) {
        Collection<BasicHeader> copiedHeaders = new HashSet<>();
        for (Header header : defaultHeaders) {
            copiedHeaders.add(new BasicHeader(header.getName(), header.getValue()));
        }
        this.defaultHeaders = copiedHeaders;
    }
1100917
public function exposeHeaders($headers = '*')
    {
        $this->response = $this->corsHandler->setResponse($this->response)
            ->exposeHeaders($headers)
            ->getResponse();

        return $this;
    }
425678
public B setHttpHeaders(Headers<AsciiString, String, ?> httpHeaders) {
        requireNonNull(httpHeaders, "httpHeaders");
        this.httpHeaders.setAll(httpHeaders);
        return self();
    }
678044
public CSV header(String... items) {
      this.header = (items == null ? null : Arrays.asList(items));
      if (header != null && header.size() > 0) {
         this.hasHeader = true;
      }
      return this;
   }
1218157
public void setHead(Object[] h) {

        headers = new Object[h.length];

        // System.arraycopy(h, 0, headers, 0, h.length);
        for (int i = 0; i < h.length; i++) {
            headers[i] = h[i];
        }
    }
1291458
public T addHeaders(Map<String, String> headers) {
		if(CollectionUtil.isEmpty(headers)) {
			return (T)this;
		}
		
		for (Entry<String,String> entry : headers.entrySet()) {
			this.header(entry.getKey(), StrUtil.nullToEmpty(entry.getValue()), false);
		}
		return (T)this;
	}
831324
public OkRequest<T> headers(final Map<String, String> headers) {
        if (!headers.isEmpty())
            for (Map.Entry<String, String> header : headers.entrySet())
                header(header);
        return this;
    }
1013717
public <T extends Header> T getHeader(short ... ids) {
        if(ids == null || ids.length == 0)
            return null;
        return Headers.getHeader(this.headers, ids);
    }
697474
public void setHeader(HasJqmHeader header) {
        removeHeader();
        this.header = header;
        if (this.header == null) return;

        addLogical(header.getHeaderStage());

        if (panel == null) {
        	getElement().insertBefore(header.getJqmHeader().getElement(), getElement().getFirstChild());
        } else {
        	getElement().insertAfter(header.getJqmHeader().getElement(), panel.getElement());
        }
    }
436171
public PactDslRequestWithPath headers(Map<String, String> headers) {
      for (Map.Entry<String, String> entry: headers.entrySet()) {
        requestHeaders.put(entry.getKey(), Collections.singletonList(entry.getValue()));
      }
      return this;
    }
193774
public function withHeaders( array $headers )
	{
		foreach ( $headers as $key => $value )
		{
			$this->headers->set( $key, $value );
		}

		return $this;
	}
387928
public Map<String, Collection<String>> headers() {
    Map<String, Collection<String>> headerMap = new TreeMap<>(String.CASE_INSENSITIVE_ORDER);
    this.headers.forEach((key, headerTemplate) -> {
      List<String> values = new ArrayList<>(headerTemplate.getValues());

      /* add the expanded collection, but only if it has values */
      if (!values.isEmpty()) {
        headerMap.put(key, Collections.unmodifiableList(values));
      }
    });
    return Collections.unmodifiableMap(headerMap);
  }
412694
function Headers(headers) {
	            var _this = this;
	            /** @internal header names are lower case */
	            this._headers = new Map();
	            /** @internal map lower case names to actual names */
	            this._normalizedNames = new Map();
	            if (!headers) {
	                return;
	            }
	            if (headers instanceof Headers) {
	                headers._headers.forEach(function (values, name) {
	                    values.forEach(function (value) { return _this.append(name, value); });
	                });
	                return;
	            }
	            Object.keys(headers).forEach(function (name) {
	                var values = Array.isArray(headers[name]) ? headers[name] : [headers[name]];
	                _this.delete(name);
	                values.forEach(function (value) { return _this.append(name, value); });
	            });
	        }