Duplicate headers from the source. Existing headers are all cleared. @param source the source headers @throws IOException if an I/O error occurs
(MimeHeaders source)
| 186 | * @throws IOException if an I/O error occurs |
| 187 | */ |
| 188 | public void duplicate(MimeHeaders source) throws IOException { |
| 189 | recycle(); |
| 190 | for (int i = 0; i < source.size(); i++) { |
| 191 | MimeHeaderField mhf = createHeader(); |
| 192 | mhf.getName().duplicate(source.getName(i)); |
| 193 | mhf.getValue().duplicate(source.getValue(i)); |
| 194 | } |
| 195 | } |
| 196 | |
| 197 | |
| 198 | // -------------------- Idx access to headers ---------- |
no test coverage detected