============================================================================ Exported helper functions for primitive slice serialization (ARRAY protocol) These functions write: size_bytes + binary_data They are used by struct serializers and generated code ===========================================
(buf *ByteBuffer, value []byte)
| 707 | |
| 708 | // WriteByteSlice writes []byte to buffer using ARRAY protocol |
| 709 | func WriteByteSlice(buf *ByteBuffer, value []byte) { |
| 710 | buf.WriteLength(len(value)) |
| 711 | if len(value) > 0 { |
| 712 | buf.WriteBinary(value) |
| 713 | } |
| 714 | } |
| 715 | |
| 716 | // ReadByteSlice reads []byte from buffer using ARRAY protocol |
| 717 | func ReadByteSlice(buf *ByteBuffer, err *Error) []byte { |
nothing calls this directly
no test coverage detected