code: func NewEncoder(w io.Writer, codec runtime.Codec) *Encoder {
  	return &Encoder{
  		w:       w,
  		encoder: json.NewEncoder(w),
  		codec:   codec,
  	}
  }
docs: // NewEncoder creates an Encoder for the given writer and codec