MCPcopy
hub / github.com/dropbox/godropbox / HexEncodeToWriter

Function HexEncodeToWriter

encoding2/hex.go:10–14  ·  view source on GitHub ↗

This hex encodes the binary data and writes the encoded data to the writer.

(w BinaryWriter, data []byte)

Source from the content-addressed store, hash-verified

8
9// This hex encodes the binary data and writes the encoded data to the writer.
10func HexEncodeToWriter(w BinaryWriter, data []byte) {
11 for _, b := range data {
12 w.Write(hexMap[b])
13 }
14}
15
16func init() {
17 hexMap = make([][]byte, 256)

Callers 2

encodeSqlMethod · 0.92
TestBasicStreamHexMethod · 0.85

Calls 1

WriteMethod · 0.45

Tested by 1

TestBasicStreamHexMethod · 0.68