Home | History | Annotate | Download | only in io

Lines Matching defs:Write

28 // ErrClosedPipe is the error used for read or write operations on a closed pipe.
29 var ErrClosedPipe = errors.New("io: read/write on closed pipe")
33 wrMu sync.Mutex // Serializes Write operations
77 func (p *pipe) Write(b []byte) (n int, err error) {
123 // arrives or the write end is closed.
124 // If the write end is closed with an error, that error is
131 // write half of the pipe will return the error ErrClosedPipe.
137 // to the write half of the pipe will return the error err.
142 // A PipeWriter is the write half of a pipe.
147 // Write implements the standard Write interface:
152 func (w *PipeWriter) Write(data []byte) (n int, err error) {
153 return w.p.Write(data)
176 // except when multiple Reads are needed to consume a single Write.
177 // That is, each Write to the PipeWriter blocks until it has satisfied
180 // The data is copied directly from the Write to the corresponding
183 // It is safe to call Read and Write in parallel with each other or with Close.
184 // Parallel calls to Read and parallel calls to Write are also safe: