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

Method AddArrayKey

encode_array.go:44–46  ·  view source on GitHub ↗

AddArrayKey adds an array or slice to be encoded, must be used inside an object as it will encode a key value must implement Marshaler

(key string, v MarshalerJSONArray)

Source from the content-addressed store, hash-verified

42// AddArrayKey adds an array or slice to be encoded, must be used inside an object as it will encode a key
43// value must implement Marshaler
44func (enc *Encoder) AddArrayKey(key string, v MarshalerJSONArray) {
45 enc.ArrayKey(key, v)
46}
47
48// AddArrayKeyOmitEmpty adds an array or slice to be encoded and skips it if it is nil.
49// Must be called inside an object as it will encode a key.

Callers 4

AddInterfaceKeyMethod · 0.95
MarshalJSONObjectMethod · 0.80
MarshalJSONObjectMethod · 0.80
MarshalJSONObjectMethod · 0.80

Calls 1

ArrayKeyMethod · 0.95

Tested by

no test coverage detected