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

Method encodeInt64

encode_number_int.go:38–41  ·  view source on GitHub ↗

encodeInt64 encodes an int to JSON

(n int64)

Source from the content-addressed store, hash-verified

36
37// encodeInt64 encodes an int to JSON
38func (enc *Encoder) encodeInt64(n int64) ([]byte, error) {
39 enc.buf = strconv.AppendInt(enc.buf, n, 10)
40 return enc.buf, nil
41}
42
43// AddInt adds an int to be encoded, must be used inside a slice or array encoding (does not encode a key)
44func (enc *Encoder) AddInt(v int) {

Callers 3

EncodeInt64Method · 0.95
EncodeSQLNullInt64Method · 0.95
marshalFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected