ReadByte implements Connection.
()
| 232 | |
| 233 | // ReadByte implements Connection. |
| 234 | func (c *connection) ReadByte() (b byte, err error) { |
| 235 | if err = c.waitRead(1); err != nil { |
| 236 | return b, err |
| 237 | } |
| 238 | return c.inputBuffer.ReadByte() |
| 239 | } |
| 240 | |
| 241 | // ------------------------------------------ implement zero-copy writer ------------------------------------------ |
| 242 |