WriteTo satisfies the io.WriterTo interface.
(w io.Writer)
| 109 | |
| 110 | // WriteTo satisfies the io.WriterTo interface. |
| 111 | func (h Hash) WriteTo(w io.Writer) (int64, error) { |
| 112 | n, err := w.Write(h.Bytes()) |
| 113 | return int64(n), err |
| 114 | } |
| 115 | |
| 116 | // ReadFrom satisfies the io.ReaderFrom interface. |
| 117 | func (h *Hash) ReadFrom(r io.Reader) (int64, error) { |
no test coverage detected