git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@529 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 26 years ago
parent e1875a2439
commit 5635ffd0b9
  1. 16
      jode/jode/bytecode/Reference.java

@ -42,11 +42,17 @@ public class Reference {
* The member type.
*/
String memberType;
/**
* The cached hash code
*/
int cachedHashCode;
public Reference(String className, String name, String type) {
this.className = className;
this.memberName = name;
this.memberType = type;
this.className = className.intern();
this.memberName = name.intern();
this.memberType = type.intern();
cachedHashCode =
className.hashCode() ^ name.hashCode() ^ type.hashCode();
}
public String getClazz() {
@ -86,4 +92,8 @@ public class Reference {
}
return false;
}
public int hashCode() {
return cachedHashCode;
}
}

Loading…
Cancel
Save