MCPcopy
hub / github.com/jackc/pgx / Scan

Method Scan

pgtype/bytea.go:194–208  ·  view source on GitHub ↗
(src []byte, dst any)

Source from the content-addressed store, hash-verified

192type scanPlanTextByteaToBytes struct{}
193
194func (scanPlanTextByteaToBytes) Scan(src []byte, dst any) error {
195 dstBuf := dst.(*[]byte)
196 if src == nil {
197 *dstBuf = nil
198 return nil
199 }
200
201 buf, err := decodeHexBytea(src)
202 if err != nil {
203 return err
204 }
205 *dstBuf = buf
206
207 return nil
208}
209
210type scanPlanTextByteaToBytesScanner struct{}
211

Callers

nothing calls this directly

Calls 1

decodeHexByteaFunction · 0.85

Tested by

no test coverage detected