net.obsearch.index.ghs
Class SketchProjection

java.lang.Object
  extended by net.obsearch.index.ghs.SketchProjection
All Implemented Interfaces:
Comparable<SketchProjection>, Projection<SketchProjection,CBitVector>

public final class SketchProjection
extends Object
implements Projection<SketchProjection,CBitVector>


Constructor Summary
SketchProjection(byte[] ordering, CBitVector sketch, int distance, double[] lowerBounds)
           
 
Method Summary
 int compareTo(SketchProjection o)
           
 SketchProjection distance(CBitVector b)
          Calculate the distance between the given bitvector and this sketch projection Return a sketch projection with the quality measurements based on the data found in this object.
 boolean equals(Object o)
           
 byte[] getAddress()
           
 CBitVector getCompactRepresentation()
           
 int getDistance()
           
 CBitVector getSketch()
           
 int hamming(CBitVector b)
           
 void setDistance(int distance)
           
 void setSketch(CBitVector sketch)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SketchProjection

public SketchProjection(byte[] ordering,
                        CBitVector sketch,
                        int distance,
                        double[] lowerBounds)
Method Detail

toString

public String toString()
Overrides:
toString in class Object

setDistance

public void setDistance(int distance)

setSketch

public void setSketch(CBitVector sketch)

getDistance

public int getDistance()

equals

public boolean equals(Object o)
Overrides:
equals in class Object

compareTo

public int compareTo(SketchProjection o)
Specified by:
compareTo in interface Comparable<SketchProjection>

getCompactRepresentation

public CBitVector getCompactRepresentation()
Specified by:
getCompactRepresentation in interface Projection<SketchProjection,CBitVector>

getSketch

public CBitVector getSketch()

getAddress

public byte[] getAddress()
Specified by:
getAddress in interface Projection<SketchProjection,CBitVector>

distance

public SketchProjection distance(CBitVector b)
Calculate the distance between the given bitvector and this sketch projection Return a sketch projection with the quality measurements based on the data found in this object.

Specified by:
distance in interface Projection<SketchProjection,CBitVector>
Parameters:
b -
Returns:

hamming

public int hamming(CBitVector b)


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