int add(Entry source){
  Integer id=hash.get(source);
  if (id == null) {
    id=hash.size() + 1;
    list.add(source);
    hash.put(source,id);
  }
  return id;
}

int add ( Entry source ) { Integer id = hash . get ( source ) ; if ( id == null ) { id = hash . size ( ) + 1 ; list . add ( source ) ; hash . put ( source , id ) ; } return id ; }
add a source to the hash list and return its id .
