MCPcopy Create free account
hub / github.com/cockroachdb/cockroachdb-parser / encode

Method encode

pkg/util/json/json.go:219–219  ·  view source on GitHub ↗

encode appends the encoding of the JSON document to appendTo, returning the result alongside the JEntry for the document. Note that some values (true/false/null) are encoded with 0 bytes and are purely defined by their JEntry.

(appendTo []byte)

Source from the content-addressed store, hash-verified

217 // (true/false/null) are encoded with 0 bytes and are purely defined by their
218 // JEntry.
219 encode(appendTo []byte) (jEntry jEntry, b []byte, err error)
220
221 // MaybeDecode returns an equivalent JSON which is not a jsonEncoded.
222 MaybeDecode() JSON

Callers 3

encodeMethod · 0.65
encodeMethod · 0.65
EncodeJSONFunction · 0.65

Implementers 4

jsonNullpkg/util/json/json.go
jsonFalsepkg/util/json/json.go
jsonTruepkg/util/json/json.go
jsonEncodedpkg/util/json/encoded.go

Calls

no outgoing calls

Tested by

no test coverage detected