MCPcopy Create free account
hub / github.com/francoispqt/gojay / AddStringKeyOmitEmpty

Method AddStringKeyOmitEmpty

encode_string.go:57–59  ·  view source on GitHub ↗

AddStringKeyOmitEmpty adds a string to be encoded or skips it if it is zero value. Must be used inside an object as it will encode a key

(key, v string)

Source from the content-addressed store, hash-verified

55// AddStringKeyOmitEmpty adds a string to be encoded or skips it if it is zero value.
56// Must be used inside an object as it will encode a key
57func (enc *Encoder) AddStringKeyOmitEmpty(key, v string) {
58 enc.StringKeyOmitEmpty(key, v)
59}
60
61// AddStringKeyNullEmpty adds a string to be encoded or skips it if it is zero value.
62// Must be used inside an object as it will encode a key

Callers 3

MarshalJSONObjectMethod · 0.80

Calls 1

StringKeyOmitEmptyMethod · 0.95

Tested by 2

MarshalJSONObjectMethod · 0.64