@Override public int compareTo(DiscordRecord other){
  if (null == other) {
    throw new NullPointerException("Unable compare to null!");
  }
  return Double.compare(other.getNNDistance(),this.nnDistance);
}

@ Override public int compareTo ( DiscordRecord other ) { if ( null == other ) { throw new NullPointerException ( "Unable compare to null!" ) ; } return Double . compare ( other . getNNDistance ( ) , this . nnDistance ) ; }
the simple comparator based on the distance . note that discord is " better " if the nn distance is greater .
