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

Function NewEncoder

encoding/resp/resp.go:79–81  ·  view source on GitHub ↗

NewEncoder creates a RESP encoder

(w io.Writer)

Source from the content-addressed store, hash-verified

77
78// NewEncoder creates a RESP encoder
79func NewEncoder(w io.Writer) *Encoder {
80 return &Encoder{w}
81}
82
83//Error builds a RESP error
84func (r *Encoder) Error(s string) error {

Callers 12

TestArray_EncodeFunction · 0.85
TestSimpleString_EncodeFunction · 0.85
TestBulkString_EncodeFunction · 0.85
TestError_EncodeFunction · 0.85
TestInteger_EncodeFunction · 0.85
ReplyErrorFunction · 0.85
ReplySimpleStringFunction · 0.85
ReplyBulkStringFunction · 0.85
ReplyNullBulkStringFunction · 0.85
ReplyIntegerFunction · 0.85
ReplyArrayFunction · 0.85

Calls

no outgoing calls

Tested by 6

TestArray_EncodeFunction · 0.68
TestSimpleString_EncodeFunction · 0.68
TestBulkString_EncodeFunction · 0.68
TestError_EncodeFunction · 0.68
TestInteger_EncodeFunction · 0.68