public abstract class RandomStarTable extends AbstractStarTable
The isRandom
method always returns true, and the
getRowSequence
method is implemented using the table's
(abstract) getCell
and getRow
methods,
which must be safe for concurrent use from multiple threads.
This implementation is only suitable where table data access is
naturally thread-safe; in cases where synchronization or some
other potentially expensive mechanism is used to secure thread-safety
of getCell
, it is better to use a different implementation
with a better getRowSequence
implementation.
Constructor and Description |
---|
RandomStarTable() |
Modifier and Type | Method and Description |
---|---|
abstract Object |
getCell(long irow,
int icol)
Implementations of this method must be safe for concurrent calls
from multiple threads.
|
RowAccess |
getRowAccess()
Returns a
RowAccess object based on the random data
access methods of this table. |
abstract long |
getRowCount()
Implementations must supply a non-negative return value.
|
RowSequence |
getRowSequence()
Returns a
RowSequence object based on the random data
access methods of this table. |
boolean |
isRandom()
Returns true.
|
checkedLongToInt, close, getColumnAuxDataInfos, getColumnCount, getColumnInfo, getName, getParameters, getRow, getRowSplittable, getURL, setName, setParameters, setURL
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getParameterByName, setParameter
public boolean isRandom()
isRandom
in interface StarTable
isRandom
in class AbstractStarTable
public RowSequence getRowSequence()
RowSequence
object based on the random data
access methods of this table.getRowSequence
in interface StarTable
getRowSequence
in class AbstractStarTable
public RowAccess getRowAccess()
RowAccess
object based on the random data
access methods of this table.getRowAccess
in interface StarTable
getRowAccess
in class AbstractStarTable
public abstract long getRowCount()
getRowCount
in interface StarTable
getRowCount
in class AbstractStarTable
public abstract Object getCell(long irow, int icol) throws IOException
getCell
in interface StarTable
getCell
in class AbstractStarTable
irow
- the index of the cell's rowicol
- the index of the cell's columnIOException
- if there is an error reading the dataCopyright © 2025 Central Laboratory of the Research Councils. All Rights Reserved.