public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (this.getClass() != obj.getClass()) return false; final CPClass other = (CPClass) obj; return utf8.equals(other.utf8); }
/** * Creates a new CPClass * * @param name * @param globalIndex index in CpBands * @throws NullPointerException if name is null */ public CPClass(CPUTF8 name, int globalIndex) { super(ConstantPoolEntry.CP_Class, globalIndex); if (name == null) { throw new NullPointerException("Null arguments are not allowed"); } this.name = name.underlyingString(); this.utf8 = name; }
private void generateHashCode() { hashcodeComputed = true; cachedHashCode = utf8.hashCode(); }