org.h2.result
Class SimpleRow

java.lang.Object
  extended by org.h2.result.SimpleRow
All Implemented Interfaces:
SearchRow

public class SimpleRow
extends java.lang.Object
implements SearchRow

Represents a simple row without state.


Field Summary
 
Fields inherited from interface org.h2.result.SearchRow
EMPTY_ARRAY
 
Constructor Summary
SimpleRow(Value[] data)
           
 
Method Summary
 int getColumnCount()
          Get the column count.
 long getKey()
          Get the unique key of the row.
 int getMemory()
          Get the estimated memory used for this row, in bytes.
 Value getValue(int i)
          Get the value for the column
 int getVersion()
          Get the version of the row.
 void setKey(long key)
          Set the unique key of the row.
 void setKeyAndVersion(SearchRow row)
          Set the position and version to match another row.
 void setValue(int i, Value v)
          Set the value for given column
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimpleRow

public SimpleRow(Value[] data)
Method Detail

getColumnCount

public int getColumnCount()
Description copied from interface: SearchRow
Get the column count.

Specified by:
getColumnCount in interface SearchRow
Returns:
the column count

getKey

public long getKey()
Description copied from interface: SearchRow
Get the unique key of the row.

Specified by:
getKey in interface SearchRow
Returns:
the key

setKey

public void setKey(long key)
Description copied from interface: SearchRow
Set the unique key of the row.

Specified by:
setKey in interface SearchRow
Parameters:
key - the key

setKeyAndVersion

public void setKeyAndVersion(SearchRow row)
Description copied from interface: SearchRow
Set the position and version to match another row.

Specified by:
setKeyAndVersion in interface SearchRow
Parameters:
row - the other row.

getVersion

public int getVersion()
Description copied from interface: SearchRow
Get the version of the row.

Specified by:
getVersion in interface SearchRow
Returns:
the version

setValue

public void setValue(int i,
                     Value v)
Description copied from interface: SearchRow
Set the value for given column

Specified by:
setValue in interface SearchRow
Parameters:
i - the column number (starting with 0)
v - the new value

getValue

public Value getValue(int i)
Description copied from interface: SearchRow
Get the value for the column

Specified by:
getValue in interface SearchRow
Parameters:
i - the column number (starting with 0)
Returns:
the value

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getMemory

public int getMemory()
Description copied from interface: SearchRow
Get the estimated memory used for this row, in bytes.

Specified by:
getMemory in interface SearchRow
Returns:
the memory