Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for newResponseWriter (0.17 sec)

  1. staging/src/k8s.io/apimachinery/pkg/util/httpstream/httpstream_test.go

    */
    
    package httpstream
    
    import (
    	"errors"
    	"fmt"
    	"net/http"
    	"reflect"
    	"testing"
    )
    
    type responseWriter struct {
    	header     http.Header
    	statusCode *int
    }
    
    func newResponseWriter() *responseWriter {
    	return &responseWriter{
    		header: make(http.Header),
    	}
    }
    
    func (r *responseWriter) Header() http.Header {
    	return r.header
    }
    
    func (r *responseWriter) WriteHeader(code int) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Oct 23 22:33:38 UTC 2023
    - 4.5K bytes
    - Viewed (0)
  2. src/net/http/h2_bundle.go

    		TLS:        tlsState,
    		Host:       rp.authority,
    		Body:       body,
    		Trailer:    trailer,
    	}
    	req = req.WithContext(st.ctx)
    
    	rw := sc.newResponseWriter(st, req)
    	return rw, req, nil
    }
    
    func (sc *http2serverConn) newResponseWriter(st *http2stream, req *Request) *http2responseWriter {
    	rws := http2responseWriterStatePool.Get().(*http2responseWriterState)
    	bwSave := rws.bw
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 16:19:04 UTC 2024
    - 364.1K bytes
    - Viewed (0)
Back to top