MCPcopy Create free account
hub / github.com/L-JINBIN/ApkDataMultiplexing / set

Method set

src/bin/zip/ExtraDataRecord.java:84–92  ·  view source on GitHub ↗
(byte[] extra, int header, byte[] data)

Source from the content-addressed store, hash-verified

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;

Callers 3

writeHeaderMethod · 0.95
dosToJavaTimeMethod · 0.80

Calls 2

removeMethod · 0.95
writeShortMethod · 0.95

Tested by

no test coverage detected