The FitsTableBuilder
class
can read FITS binary (BINTABLE) and ASCII (TABLE) table extensions.
Unless told otherwise the StarTableFactory.makeStarTable
method
will find the first table extension in the named FITS file.
If the name supplied to the StarTableFactory
ends in a "#" sign followed by an identifier however, it means that the
requested table is in the indicated extension of a multi-extension FITS file.
This identifier may be given in one of two forms:
To retrieve all the tables in a multi-extension FITS files,
use one of the makeStarTables
methods of
StarTableFactory
instead.
If the table is stored in a FITS binary table extension in a file
on local disk in uncompressed form, then the file will be mapped
rather than read when the StarTable
is constructed,
which means that constructing the StarTable is very fast.
If you want to inhibit this behaviour, you can refer to the file as a URL,
for instance using the designation 'file:spec23.fits' rather
than 'spec23.fits';
this fools the handler into thinking that the file cannot be mapped.
Header cards in the table's HDU header will be
made available as table parameters
(see getParameters
).
Only header cards which are not used to specify the table format itself
are visible as parameters (e.g. NAXIS, TTYPE* etc cards are not).
HISTORY and COMMENT cards are run together as one multi-line value.
Currently, binary tables are read more efficiently than ASCII ones.
The FitsPlusTableBuilder
handler also reads a variant of the FITS format - see Section 3.6.2.
This handler can read tables with more than the BINTABLE limit of 999 columns, as discussed in Section 3.8.1.
There is some support for the semi-standard
HEALPix-FITS convention.
The information in the FITS headers defined by that convention,
if present, is stored as values of the HPX_*_INFO
parameters defined by class
HealpixTableInfo
.
These headers can thus be round-tripped if the file is output in
FITS format - see Section 3.6.1.
Support for this convention is not perfect; the BAD_DATA
keyword is ignored, and the 1024-element array-valued column variant
is not understood.