public class BinaryTableHDU extends TableHDU
BITPIX_BYTE, BITPIX_DOUBLE, BITPIX_FLOAT, BITPIX_INT, BITPIX_LONG, BITPIX_SHORT, isPrimary, myData, myHeader
Constructor and Description |
---|
BinaryTableHDU(Header hdr,
Data datum) |
Modifier and Type | Method and Description |
---|---|
int |
addColumn(Object data)
Add a column without any associated header information.
|
static Data |
encapsulate(Object o)
Encapsulate data in a BinaryTable data type
|
void |
info()
Print out some information about this HDU.
|
static boolean |
isData(Object o) |
boolean |
isHeader()
Check that this HDU has a valid header.
|
static boolean |
isHeader(Header header)
Check that this is a valid binary table header.
|
Data |
manufactureData()
Create a Data object to correspond to the header description.
|
static Data |
manufactureData(Header header)
Create data from a binary table header.
|
static Header |
manufactureHeader(Data data)
Build a binary table HDU from the supplied data.
|
void |
write(ArrayDataOutput ado)
Write the contents of the element to a data sink.
|
addRow, findColumn, getColumn, getColumn, getColumnFormat, getColumnName, getElement, getNCols, getNRows, getRow, setColumn, setColumn, setColumnName, setCurrentColumn, setElement, setRow
addValue, addValue, addValue, addValue, getAuthor, getAxes, getBitPix, getBlankValue, getBScale, getBUnit, getBZero, getCreationDate, getData, getDummyHDU, getEpoch, getEquinox, getFileOffset, getGroupCount, getHeader, getInstrument, getKernel, getMaximumValue, getMinimumValue, getObject, getObservationDate, getObserver, getOrigin, getParameterCount, getReference, getSize, getTelescope, getTrimmedString, read, readData, rewrite, rewriteable, skipData, skipData
public static Data manufactureData(Header header) throws FitsException
header
- the template specifying the binary table.FitsException
- if there was a problem with the header.public Data manufactureData() throws FitsException
BasicHDU
FitsException
- if the Data object could not be created
from this HDU's Headerpublic static Header manufactureHeader(Data data) throws FitsException
table
- the array used to build the binary table.FitsException
- if there was a problem with the data.public static Data encapsulate(Object o) throws FitsException
FitsException
public static boolean isHeader(Header header)
header
- to validate.true
if this is a binary table header.public boolean isHeader()
true
if this HDU has a valid header.public static boolean isData(Object o)
public int addColumn(Object data) throws FitsException
addColumn
in class TableHDU
data
- The column data to be added. Data should be an Object[] where
type of all of the constituents is identical. The length
of data should match the other columns. Note: It is
valid for data to be a 2 or higher dimensionality primitive
array. In this case the column index is the first (in Java speak)
index of the array. E.g., if called with int[30][20][10], the
number of rows in the table should be 30 and this column
will have elements which are 2-d integer arrays with TDIM = (10,20).FitsException
- the column could not be added.public void write(ArrayDataOutput ado) throws FitsException
FitsElement
write
in interface FitsElement
write
in class BasicHDU
ado
- The data sink.FitsException
Copyright © 2024 Central Laboratory of the Research Councils. All Rights Reserved.