(vec vector.Any)
| 27 | } |
| 28 | |
| 29 | func (f *FusionEncoder) Write(vec vector.Any) { |
| 30 | if vec.Len() == 0 { |
| 31 | return |
| 32 | } |
| 33 | fusion := vec.(*vector.Fusion) |
| 34 | f.values.Write(fusion.Values) |
| 35 | //XXX calling SubTypes is a slow path... we should have another |
| 36 | // method on vector.TypeLoader that can just return the type IDs |
| 37 | // as a slice and lookup the interned CSUP type table and copy |
| 38 | // what is needed. |
| 39 | for _, typ := range fusion.Subtypes() { |
| 40 | f.subtypes = append(f.subtypes, f.cctx.lookupTypeID(fusion.Sctx, typ)) |
| 41 | } |
| 42 | } |
| 43 | |
| 44 | func (f *FusionEncoder) Emit(w io.Writer) error { |
| 45 | if err := f.values.Emit(w); err != nil { |
nothing calls this directly
no test coverage detected