Recycle the output buffer.
()
| 178 | * Recycle the output buffer. |
| 179 | */ |
| 180 | public void recycle() { |
| 181 | |
| 182 | initial = true; |
| 183 | bytesWritten = 0; |
| 184 | charsWritten = 0; |
| 185 | |
| 186 | if (bb.capacity() > 16 * defaultBufferSize) { |
| 187 | // Discard buffers which are too large |
| 188 | bb = ByteBuffer.allocate(defaultBufferSize); |
| 189 | } |
| 190 | clear(bb); |
| 191 | clear(cb); |
| 192 | closed = false; |
| 193 | suspended = false; |
| 194 | doFlush = false; |
| 195 | |
| 196 | if (conv != null) { |
| 197 | conv.recycle(); |
| 198 | conv = null; |
| 199 | } |
| 200 | } |
| 201 | |
| 202 | |
| 203 | /** |