(byte[] extra, int header, byte[] data)
| 82 | } |
| 83 | |
| 84 | public static byte[] set(byte[] extra, int header, byte[] data) throws IOException { |
| 85 | extra = remove(extra, header); |
| 86 | byte[] newExtra = new byte[4 + data.length + extra.length]; |
| 87 | ZipUtil.writeShort(newExtra, 0, header); |
| 88 | ZipUtil.writeShort(newExtra, 2, data.length); |
| 89 | System.arraycopy(data, 0, newExtra, 4, data.length); |
| 90 | System.arraycopy(extra, 0, newExtra, 4 + data.length, extra.length); |
| 91 | return newExtra; |
| 92 | } |
| 93 | |
| 94 | public static byte[] remove(byte[] extra, int header) throws IOException { |
| 95 | int offset = 0; |
no test coverage detected