change hashcode to sha1
add some javadoc