net.obsearch.ob
Interface OBDouble

All Superinterfaces:
OB, Storable
All Known Implementing Classes:
OBVectorDouble

public interface OBDouble
extends OB

Any Object whose distance function returns doubles must implement this interface. WARNING: The equals method *must* be implemented. The equals does not have to be true when the distance returns 0. Note however that at search time, elements of distance 0 are treated in the same way. Equals is only used when the database is queried for the existence of an object.

Since:
0.7
Author:
Arnoldo Jose Muller Molina

Method Summary
 double distance(OBDouble object)
          Calculates the similarity of "this" and "object".
 
Methods inherited from interface net.obsearch.Storable
load, store
 

Method Detail

distance

double distance(OBDouble object)
                throws OBException
Calculates the similarity of "this" and "object". The function must satisfy the triangular inequality and return a double.

Parameters:
object - The object of type OBDouble to be compared
result - The resulting distance
Throws:
OBException - User generated exception
Since:
0.7


Copyright © 2007-2011 Arnoldo Jose Muller Molina. All Rights Reserved.