protected boolean addHash(Object entity,Hasher hasher){
  EntityType entityType=getElementType(entity);
  if (entityType == UNKNOWN) {
    return false;
  }
  try {
    hasher.putString(getJson(entity,entityType),Charset.defaultCharset());
  }
 catch (  RuntimeException e) {
    return false;
  }
  return true;
}

protected boolean addHash ( Object entity , Hasher hasher ) { EntityType entityType = getElementType ( entity ) ; if ( entityType == UNKNOWN ) { return false ; } try { hasher . putString ( getJson ( entity , entityType ) , Charset . defaultCharset ( ) ) ; } catch ( RuntimeException e ) { return false ; } return true ; }
helper method to add entity to hash . if there is an invalid entity type it will return false
