|
Mobios v0.91 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object mobios.type.IndexObject mobios.type.DoubleVector
public class DoubleVector
This class represents space vectors, where each element is a double.
Constructor Summary | |
---|---|
DoubleVector()
TODO |
|
DoubleVector(mobios.db.Table table,
int rowID,
double[] data)
Builds an instance from a double array. |
|
DoubleVector(mobios.db.Table table,
int rowID,
String dataString)
Builds an instance from a space-separated String of doubles. |
Method Summary | |
---|---|
int |
compareTo(DoubleVector oThat)
|
int |
compareTo(IndexObject oThat)
|
boolean |
equals(Object that)
|
IndexObject[] |
expand()
This method is necessary to implement bucketing, so that similar objects are only stored once in the database. |
double[] |
getData()
|
int |
hashCode()
|
void |
readExternal(ObjectInput in)
|
int |
size()
|
String |
toString()
all implementing classes are required to override toString |
void |
writeExternal(ObjectOutput out)
|
Methods inherited from class mobios.type.IndexObject |
---|
getRowID, setRowID, setRowIDLength |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DoubleVector()
public DoubleVector(mobios.db.Table table, int rowID, String dataString)
String
of doubles.
table
- rowID
- dataString
- public DoubleVector(mobios.db.Table table, int rowID, double[] data)
rowID
- data
- the double array containning all the elements. cannot be nullMethod Detail |
---|
public double[] getData()
public int size()
size
in class IndexObject
public IndexObject[] expand()
IndexObject
expand
in class IndexObject
IndexObject
spublic int compareTo(IndexObject oThat)
compareTo
in interface Comparable<IndexObject>
compareTo
in class IndexObject
public int compareTo(DoubleVector oThat)
oThat
-
public boolean equals(Object that)
equals
in class Object
public int hashCode()
hashCode
in class Object
public String toString()
IndexObject
toString
in class IndexObject
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
readExternal
in class IndexObject
IOException
ClassNotFoundException
public void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
writeExternal
in class IndexObject
IOException
|
Mobios v0.91 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |