()
| 88 | } |
| 89 | |
| 90 | func (e *Encoder) initialize() { |
| 91 | if e.o.concurrent == 0 { |
| 92 | e.o.setDefault() |
| 93 | } |
| 94 | e.encoders = make(chan encoder, e.o.concurrent) |
| 95 | for i := 0; i < e.o.concurrent; i++ { |
| 96 | enc := e.o.encoder() |
| 97 | e.encoders <- enc |
| 98 | } |
| 99 | } |
| 100 | |
| 101 | // Reset will re-initialize the writer and new writes will encode to the supplied writer |
| 102 | // as a new, independent stream. |
no test coverage detected