MCPcopy Create free account
hub / github.com/cinit/TMoe / readProto

Method readProto

app/src/main/java/cc/ioctl/tmoe/util/dex/DexFlow.java:471–486  ·  view source on GitHub ↗
(byte[] buf, int idx)

Source from the content-addressed store, hash-verified

469 }
470
471 public static String readProto(byte[] buf, int idx) {
472 int protoIdsOff = readLe32(buf, 0x4c);
473 int returnTypeIdx = readLe32(buf, protoIdsOff + 12 * idx + 4);
474 int parametersOff = readLe32(buf, protoIdsOff + 12 * idx + 8);
475 StringBuilder sb = new StringBuilder("(");
476 if (parametersOff != 0) {
477 int size = readLe32(buf, parametersOff);
478 for (int i = 0; i < size; i++) {
479 int typeIdx = readLe16(buf, parametersOff + 4 + 2 * i);
480 sb.append(readType(buf, typeIdx));
481 }
482 }
483 sb.append(")");
484 sb.append(readType(buf, returnTypeIdx));
485 return sb.toString();
486 }
487
488 public static int arrayIndexOf(byte[] arr, byte[] subArr, int startIndex, int endIndex) {
489 byte a = subArr[0];

Callers 4

getDeclaredDexMethodsMethod · 0.95
guessNewInstanceTypeMethod · 0.95

Calls 4

readLe32Method · 0.95
readLe16Method · 0.95
readTypeMethod · 0.95
toStringMethod · 0.45

Tested by

no test coverage detected