MCPcopy Create free account
hub / github.com/distributedio/titan / Integer

Method Integer

encoding/resp/resp.go:109–113  ·  view source on GitHub ↗

Integer builds a RESP integer

(v int64)

Source from the content-addressed store, hash-verified

107
108// Integer builds a RESP integer
109func (r *Encoder) Integer(v int64) error {
110 s := strconv.FormatInt(v, 10)
111 _, err := r.w.Write([]byte(":" + s + "\r\n"))
112 return err
113}
114
115// Array builds a RESP array
116func (r *Encoder) Array(size int) error {

Callers 1

TestInteger_EncodeFunction · 0.95

Implementers 1

Encoderencoding/resp/resp.go

Calls 1

WriteMethod · 0.80

Tested by 1

TestInteger_EncodeFunction · 0.76