uncommenting the hash code method and adding jdk 7 support