protected final List < DoubleIntPair > getSortedEntries ( N node , DBID q ) { List < DoubleIntPair > result = new ArrayList <> ( ) ; for ( int i = 0 ; i < node . getNumEntries ( ) ; i ++ ) { E entry = node . getEntry ( i ) ; double distance = distance ( entry . getRoutingObjectID ( ) , q ) ; double radius = entry . getCoveringRadius ( ) ; double minDist = ( radius > distance ) ? 0.0 : distance - radius ; result . add ( new DoubleIntPair ( minDist , i ) ) ; } Collections . sort ( result ) ; return result ; }
Sorts the entries of the specified node according to their minimum distance to the specified object .