Package uk.ac.starlink.topcat
Class SubsetStarTable
java.lang.Object
uk.ac.starlink.table.WrapperStarTable
uk.ac.starlink.topcat.SubsetStarTable
- All Implemented Interfaces:
Closeable
,AutoCloseable
,uk.ac.starlink.table.StarTable
public class SubsetStarTable
extends uk.ac.starlink.table.WrapperStarTable
StarTable that applies a row subset selection to a given input table.
This implementation is not random access, but does supply a
non-trivial RowSplittable.
- Since:
- 14 Dec 2020
- Author:
- Mark Taylor
-
Field Summary
Fields inherited from class uk.ac.starlink.table.WrapperStarTable
baseTable
-
Constructor Summary
ConstructorsConstructorDescriptionSubsetStarTable
(uk.ac.starlink.table.StarTable base, RowSubset rset) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic uk.ac.starlink.table.StarTable
createTable
(uk.ac.starlink.table.StarTable table, RowSubset rset) Returns a table with row selection characteristics matching those of the given subset.getCell
(long irow, int icol) Object[]
getRow
(long irow) uk.ac.starlink.table.RowAccess
long
uk.ac.starlink.table.RowSequence
uk.ac.starlink.table.RowSplittable
Note the row index reflects the index in the underlying table, not that of the subset table.boolean
isRandom()
Methods inherited from class uk.ac.starlink.table.WrapperStarTable
checkedLongToInt, close, getBaseTable, getColumnAuxDataInfos, getColumnCount, getColumnInfo, getName, getParameterByName, getParameters, getURL, setName, setParameter, setURL, toString
-
Constructor Details
-
SubsetStarTable
Constructor.- Parameters:
base
- table supplying row datarset
- subset defining row inclusion
-
-
Method Details
-
isRandom
public boolean isRandom()- Specified by:
isRandom
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
isRandom
in classuk.ac.starlink.table.WrapperStarTable
-
getRowCount
public long getRowCount()- Specified by:
getRowCount
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
getRowCount
in classuk.ac.starlink.table.WrapperStarTable
-
getCell
- Specified by:
getCell
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
getCell
in classuk.ac.starlink.table.WrapperStarTable
-
getRow
- Specified by:
getRow
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
getRow
in classuk.ac.starlink.table.WrapperStarTable
-
getRowAccess
public uk.ac.starlink.table.RowAccess getRowAccess()- Specified by:
getRowAccess
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
getRowAccess
in classuk.ac.starlink.table.WrapperStarTable
-
getRowSequence
- Specified by:
getRowSequence
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
getRowSequence
in classuk.ac.starlink.table.WrapperStarTable
- Throws:
IOException
-
getRowSplittable
Note the row index reflects the index in the underlying table, not that of the subset table.- Specified by:
getRowSplittable
in interfaceuk.ac.starlink.table.StarTable
- Overrides:
getRowSplittable
in classuk.ac.starlink.table.WrapperStarTable
- Throws:
IOException
-
createTable
public static uk.ac.starlink.table.StarTable createTable(uk.ac.starlink.table.StarTable table, RowSubset rset) Returns a table with row selection characteristics matching those of the given subset.
-