public class CdfStarTable extends AbstractStarTable
| Constructor and Description |
|---|
CdfStarTable(uk.ac.bristol.star.cdf.CdfContent content,
CdfTableProfile profile,
uk.ac.bristol.star.cdf.Variable dependVar)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
getCell(long irow,
int icol)
The
AbstractStarTable implementation of this method
throws an UnsupportedOperationException,
since unless otherwise provided there is no random access. |
int |
getColumnCount()
Returns the number of columns in this table.
|
ColumnInfo |
getColumnInfo(int icol)
Returns the object describing the data in a given column.
|
RowAccess |
getRowAccess()
Returns an object which can provide random access to this
table's data, if random access is implemented.
|
long |
getRowCount()
Returns the number of rows in this table, if known.
|
RowSequence |
getRowSequence()
Returns an object which can iterate over all the rows in the table
sequentially.
|
static String |
getStringEntry(uk.ac.bristol.star.cdf.VariableAttribute att,
uk.ac.bristol.star.cdf.Variable var)
Gets a variable's attribute value expected to be of string type.
|
boolean |
isRandom()
The
AbstractStarTable implementation of this method
returns false. |
checkedLongToInt, close, getColumnAuxDataInfos, getName, getParameters, getRow, getRowSplittable, getURL, setName, setParameters, setURLclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetParameterByName, setParameterpublic CdfStarTable(uk.ac.bristol.star.cdf.CdfContent content,
CdfTableProfile profile,
uk.ac.bristol.star.cdf.Variable dependVar)
throws IOException
The optional dependVar parameter provides an
effective grouping of columns, and corresponds to the DEPEND_0
variable attribute defined by the ISTP Metadata Guidelines.
CDF files contain multiple variables that are not necessarily
all columns of the same table; at least within the ISTP guidelines
a table is effectively defined by an independent epoch variable
and a number of other variables depending on that (and thus
presumably having the same number of values/rows).
This interpretation is not exactly explicit in ISTP, but it looks
like our best bet for turning CDF content into a thing or things
that look like StarTables.
If dependVar is null, we just have to assume that
all the variables are effectively columns in the same table.
In case that they don't all have the same multiplicity,
just guess something and issue a warning.
content - CDF data content objectprofile - parameterisation of how CDFs should get turned
into StarTablesdependVar - independent variable on which other columns depend,
or nullIOException - in case of errorpublic int getColumnCount()
StarTablegetColumnCount in interface StarTablegetColumnCount in class AbstractStarTablepublic long getRowCount()
StarTablegetRowCount in interface StarTablegetRowCount in class AbstractStarTablepublic ColumnInfo getColumnInfo(int icol)
StarTablegetColumnInfo in interface StarTablegetColumnInfo in class AbstractStarTableicol - the column for which header information is requiredicolpublic boolean isRandom()
AbstractStarTableAbstractStarTable implementation of this method
returns false.isRandom in interface StarTableisRandom in class AbstractStarTabletrue if table random access methods are availablepublic Object getCell(long irow, int icol) throws IOException
AbstractStarTableAbstractStarTable implementation of this method
throws an UnsupportedOperationException,
since unless otherwise provided there is no random access.getCell in interface StarTablegetCell in class AbstractStarTableirow - the index of the cell's rowicol - the index of the cell's columnIOException - if there is an error reading the datapublic RowSequence getRowSequence() throws IOException
StarTablegetRowSequence in interface StarTablegetRowSequence in class AbstractStarTableIOException - if there is an error providing accesspublic RowAccess getRowAccess() throws IOException
StarTablegetRowAccess in interface StarTablegetRowAccess in class AbstractStarTableIOException - if there is an error setting up accesspublic static String getStringEntry(uk.ac.bristol.star.cdf.VariableAttribute att, uk.ac.bristol.star.cdf.Variable var)
att - attributevar - variableCopyright © 2025 Central Laboratory of the Research Councils. All Rights Reserved.