MCPcopy
hub / github.com/labstack/echo / Write

Method Write

middleware/body_dump.go:182–198  ·  view source on GitHub ↗
(b []byte)

Source from the content-addressed store, hash-verified

180}
181
182func (w *limitedWriter) Write(b []byte) (n int, err error) {
183 // Always write full data to actual response (don't truncate client response)
184 n, err = w.response.Write(b)
185 if err != nil {
186 return n, err
187 }
188
189 // Write to dump buffer only up to limit
190 if w.dumped < w.limit {
191 remaining := w.limit - w.dumped
192 toDump := min(int64(n), remaining)
193 w.dumpBuf.Write(b[:toDump])
194 w.dumped += toDump
195 }
196
197 return n, nil
198}

Callers 15

WriteMethod · 0.45
proxyRawFunction · 0.45
TestGzip_chunkedFunction · 0.45
TestGzipWithMinLengthFunction · 0.45
BenchmarkGzipFunction · 0.45
TestDecompressFunction · 0.45

Calls

no outgoing calls