
O - Database object type.D - Distance result type.public class PrimitiveDistanceQuery<O,D extends Distance<D>> extends AbstractDistanceQuery<O,D>
| Modifier and Type | Field and Description | 
|---|---|
| protected PrimitiveDistanceFunction<? super O,D> | distanceFunctionThe distance function we use. | 
relationHINT_BULK, HINT_EXACT, HINT_HEAVY_USE, HINT_NO_CACHE, HINT_OPTIMIZED_ONLY, HINT_SINGLE| Constructor and Description | 
|---|
| PrimitiveDistanceQuery(Relation<? extends O> relation,
                      PrimitiveDistanceFunction<? super O,D> distanceFunction)Constructor. | 
| Modifier and Type | Method and Description | 
|---|---|
| D | distance(DBIDRef id1,
        DBIDRef id2)Returns the distance between the two objects specified by their object ids. | 
| D | distance(DBIDRef id1,
        O o2)Returns the distance between the two objects specified by their object ids. | 
| D | distance(O o1,
        DBIDRef id2)Returns the distance between the two objects specified by their object ids. | 
| D | distance(O o1,
        O o2)Returns the distance between the two objects specified by their object ids. | 
| PrimitiveDistanceFunction<? super O,D> | getDistanceFunction()Get the inner distance function. | 
getDistanceFactory, infiniteDistance, nullDistance, undefinedDistancegetRelationclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetRelationprotected final PrimitiveDistanceFunction<? super O,D extends Distance<D>> distanceFunction
public PrimitiveDistanceQuery(Relation<? extends O> relation, PrimitiveDistanceFunction<? super O,D> distanceFunction)
relation - Representation to use.distanceFunction - Our distance functionpublic D distance(DBIDRef id1, DBIDRef id2)
AbstractDistanceQuerypublic D distance(O o1, DBIDRef id2)
AbstractDistanceQuerypublic D distance(DBIDRef id1, O o2)
AbstractDistanceQuerypublic D distance(O o1, O o2)
AbstractDistanceQuerypublic PrimitiveDistanceFunction<? super O,D> getDistanceFunction()
DistanceQuery