WriteTo satisfies the io.WriterTo interface.
(w io.Writer)
| 102 | |
| 103 | // WriteTo satisfies the io.WriterTo interface. |
| 104 | func (h Hash) WriteTo(w io.Writer) (int64, error) { |
| 105 | n, err := w.Write(h.Bytes()) |
| 106 | return int64(n), err |
| 107 | } |
| 108 | |
| 109 | // ReadFrom satisfies the io.ReaderFrom interface. |
| 110 | func (h *Hash) ReadFrom(r io.Reader) (int64, error) { |