MCPcopy Create free account
hub / github.com/dolthub/doltgresql / encode

Method encode

postgres/parser/json/encode.go:74–79  ·  view source on GitHub ↗
(appendTo []byte)

Source from the content-addressed store, hash-verified

72}
73
74func (j jsonString) encode(appendTo []byte) (e jEntry, b []byte, err error) {
75 if err := checkLength(len(j)); err != nil {
76 return jEntry{}, b, err
77 }
78 return makeStringJEntry(len(j)), append(appendTo, []byte(j)...), nil
79}
80
81func (j jsonNumber) encode(appendTo []byte) (e jEntry, b []byte, err error) {
82 decOffset := len(appendTo)

Callers

nothing calls this directly

Calls 2

checkLengthFunction · 0.85
makeStringJEntryFunction · 0.85

Tested by

no test coverage detected