ModSQL
Class IndexTableEntry

java.lang.Object
  |
  +--ModSQL.IndexTableEntry
All Implemented Interfaces:
Comparable, Serializable

class IndexTableEntry
extends Object
implements Comparable, Serializable

Column data object and table rowset combined.

Author:
chris.studholme@utoronto.ca
See Also:
Serialized Form

Field Summary
 Object data
          Column value.
 IndexTableRowset rows
          Rows that have the specified column value.
 
Constructor Summary
IndexTableEntry(Object data)
          Constructor.
IndexTableEntry(Object data, IndexTableRowset rows)
          Constructor.
IndexTableEntry(Object data, Object rowid, long count)
          Constructor.
 
Method Summary
 int compareTo(Object o)
          Compare the column value to another column value or to the column value of another IndexTableEntry.
 boolean equals(Object o)
          Test if the column value is equal to another column value or the column value of another IndexTableEntry.
 void finish()
          Finish the rowset.
 boolean sameData(IndexTableEntry o)
          Check if the other IndexTableEntry has the same column value.
 
Methods inherited from class java.lang.Object
, clone, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

data

public Object data
Column value.

rows

public IndexTableRowset rows
Rows that have the specified column value.
Constructor Detail

IndexTableEntry

public IndexTableEntry(Object data)
Constructor.
Parameters:
data - column value

IndexTableEntry

public IndexTableEntry(Object data,
                       IndexTableRowset rows)
Constructor.
Parameters:
data - column value
rows - rowset

IndexTableEntry

public IndexTableEntry(Object data,
                       Object rowid,
                       long count)
Constructor.
Parameters:
data - column value
rowid - used to create a new rowset
count - used to create a new rowset
Method Detail

finish

public void finish()
Finish the rowset.
See Also:
IndexTableRowset.finish()

sameData

public boolean sameData(IndexTableEntry o)
Check if the other IndexTableEntry has the same column value.
Parameters:
o - other entry
Returns:
true if both entries have the same column value

equals

public boolean equals(Object o)
Test if the column value is equal to another column value or the column value of another IndexTableEntry.
Overrides:
equals in class Object
Parameters:
o - other column value or other IndexTableEntry
Returns:
true if the values are equal

compareTo

public int compareTo(Object o)
Compare the column value to another column value or to the column value of another IndexTableEntry. The column value must be Comparable (or null).
Specified by:
compareTo in interface Comparable
Parameters:
o - other column value or other IndexTableEntry
Returns:
0 if equal, -1 or +1 to indicate relative order