func (c *ProtocolV2ResponseChunk) EncodeToPktLine() []byte {
	if len(c.Response) != 0 {
		return BytesPacket(c.Response).EncodeToPktLine()
	}
	if c.Delimiter {
		return DelimPacket{}.EncodeToPktLine()
	}
	if c.EndResponse {
		return FlushPacket{}.EncodeToPktLine()
	}
	panic("impossible chunk")
}
EncodeToPktLine serializes the chunk.
package gitprotocolio
import (
	"fmt"
	"io"
)
type protocolV2ResponseState int
const (
	protocolV2ResponseStateBegin protocolV2ResponseState = iota
	protocolV2ResponseStateScanResponse
	protocolV2ResponseStateEnd
)
type ProtocolV2ResponseChunk struct {
	Response    []byte
	Delimiter   bool
	EndResponse bool
}