| 80 | } |
| 81 | |
| 82 | func (b *BytesEncoder) Metadata(cctx *Context, off uint64) (uint64, ID) { |
| 83 | bytesLoc := Segment{ |
| 84 | Offset: off, |
| 85 | Length: uint64(len(b.bytesOut)), |
| 86 | MemLength: b.bytesLen, |
| 87 | CompressionFormat: b.bytesFmt, |
| 88 | } |
| 89 | off, offsLoc := b.offsets.Segment(off + bytesLoc.Length) |
| 90 | return off, cctx.enter(&Bytes{ |
| 91 | Typ: b.typ, |
| 92 | Bytes: bytesLoc, |
| 93 | Offsets: offsLoc, |
| 94 | Min: b.min, |
| 95 | Max: b.max, |
| 96 | Count: uint32(len(b.offsets.vals) - 1), |
| 97 | }) |
| 98 | } |
| 99 | |
| 100 | func (b *BytesEncoder) Emit(w io.Writer) error { |
| 101 | if len(b.bytesOut) > 0 { |