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

Method SQLNullInt64KeyOmitEmpty

encode_sqlnull.go:177–181  ·  view source on GitHub ↗

SQLNullInt64KeyOmitEmpty 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 string, v *sql.NullInt64)

Source from the content-addressed store, hash-verified

175// SQLNullInt64KeyOmitEmpty adds a string to be encoded or skips it if it is zero value.
176// Must be used inside an object as it will encode a key
177func (enc *Encoder) SQLNullInt64KeyOmitEmpty(key string, v *sql.NullInt64) {
178 if v != nil && v.Valid && v.Int64 != 0 {
179 enc.Int64KeyOmitEmpty(key, v.Int64)
180 }
181}
182
183// SQLNullInt64KeyNullEmpty adds a string to be encoded or skips it if it is zero value.
184// Must be used inside an object as it will encode a key

Callers 1

TestAddSQLNullInt64KeyFunction · 0.95

Calls 1

Int64KeyOmitEmptyMethod · 0.95

Tested by 1

TestAddSQLNullInt64KeyFunction · 0.76