(b *bytes.Buffer)
| 36 | } |
| 37 | |
| 38 | func (set CompressedSet) writeTo(b *bytes.Buffer) { |
| 39 | a := [27]byte{} |
| 40 | |
| 41 | for i, it := 0, set.Iter(); it.Next(); i++ { |
| 42 | if i != 0 { |
| 43 | b.WriteString(", ") |
| 44 | } |
| 45 | b.WriteByte('"') |
| 46 | it.KSUID.Append(a[:0]) |
| 47 | b.Write(a[:]) |
| 48 | b.WriteByte('"') |
| 49 | } |
| 50 | } |
| 51 | |
| 52 | // Compress creates and returns a compressed set of KSUIDs from the list given |
| 53 | // as arguments. |