Convert ArgRef to Kotlin

bzip2
Graham 5 years ago
parent 8b57525c88
commit 44d7b3703f
  1. 42
      deob/src/main/java/dev/openrs2/deob/ArgRef.java
  2. 6
      deob/src/main/java/dev/openrs2/deob/ArgRef.kt

@ -1,42 +0,0 @@
package dev.openrs2.deob;
import java.util.Objects;
import dev.openrs2.asm.MemberRef;
import dev.openrs2.util.collect.DisjointSet;
public final class ArgRef {
private final DisjointSet.Partition<MemberRef> method;
private final int arg;
public ArgRef(DisjointSet.Partition<MemberRef> method, int arg) {
this.method = method;
this.arg = arg;
}
public DisjointSet.Partition<MemberRef> getMethod() {
return method;
}
public int getArg() {
return arg;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
ArgRef argRef = (ArgRef) o;
return arg == argRef.arg &&
method.equals(argRef.method);
}
@Override
public int hashCode() {
return Objects.hash(method, arg);
}
}

@ -0,0 +1,6 @@
package dev.openrs2.deob
import dev.openrs2.asm.MemberRef
import dev.openrs2.util.collect.DisjointSet
data class ArgRef(val method: DisjointSet.Partition<MemberRef>, val arg: Int)
Loading…
Cancel
Save