MCPcopy Create free account
hub / github.com/cli/cli / Write

Method Write

internal/codespaces/portforwarder/port_forwarder.go:446–449  ·  view source on GitHub ↗

Write wraps the underlying ReadWriteCloser's Write method and keeps the session alive with the "output" traffic type.

(p []byte)

Source from the content-addressed store, hash-verified

444
445// Write wraps the underlying ReadWriteCloser's Write method and keeps the session alive with the "output" traffic type.
446func (t *trafficMonitor) Write(p []byte) (n int, err error) {
447 t.fwd.KeepAlive(trafficTypeOutput)
448 return t.rwc.Write(p)
449}
450
451// Close closes the underlying ReadWriteCloser.
452func (t *trafficMonitor) Close() error {

Callers

nothing calls this directly

Calls 2

KeepAliveMethod · 0.65
WriteMethod · 0.65

Tested by

no test coverage detected