MCPcopy
hub / github.com/segmentio/kafka-go / writeTo

Method writeTo

joingroup.go:346–356  ·  view source on GitHub ↗
(wb *writeBuffer)

Source from the content-addressed store, hash-verified

344}
345
346func (t joinGroupResponse) writeTo(wb *writeBuffer) {
347 if t.v >= v2 {
348 wb.writeInt32(t.ThrottleTime)
349 }
350 wb.writeInt16(t.ErrorCode)
351 wb.writeInt32(t.GenerationID)
352 wb.writeString(t.GroupProtocol)
353 wb.writeString(t.LeaderID)
354 wb.writeString(t.MemberID)
355 wb.writeArray(len(t.Members), func(i int) { t.Members[i].writeTo(wb) })
356}
357
358func (t *joinGroupResponse) readFrom(r *bufio.Reader, size int) (remain int, err error) {
359 remain = size

Callers 1

TestJoinGroupResponseFunction · 0.95

Calls 5

writeArrayMethod · 0.80
writeToMethod · 0.65
writeInt32Method · 0.45
writeInt16Method · 0.45
writeStringMethod · 0.45

Tested by 1

TestJoinGroupResponseFunction · 0.76