Interface ICompressParameters
- All Known Implementing Classes:
BundledParameters
,CompressParameters
,HCompressParameters
,QuantizeParameters
,RiceCompressParameters
public interface ICompressParameters
(for internal use) Group of parameters that must be synchronized with the hdu meta data for a specific compression algorithm.
NOTE, this interface is meant for internal use only. Implementing it externally to this library might not result in
the desired behavior. If you feed the need to implement compression parameters externally to what is privided by this
library, you are advised to extend the abstract CompressParameters
class or of of its known subclasses
instead
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Add the columns that hold the metadata for the parameters that are column based to the dhu.copy
(ICompressOption option) create a copy of this parameter for another option (normally a copy of the current option).void
getValuesFromColumn
(int index) extract the option data from the column and set it in the option.void
getValuesFromHeader
(IHeaderAccess header) extract the option values that are represented by headers from the hdu header.void
initializeColumns
(int length) initialize the column based parameter to the specified column length.void
initializeColumns
(IHeaderAccess header, BinaryTable binaryTable, int size) initialize the column based options of the compression algorithm from the binary table.void
setTileIndex
(int index) Initialize parameters for the given tile indexdefault void
setValueInColumn
(int index) Deprecated.Old, inconsistent method naming.void
setValuesInColumn
(int index) set the option values, that are column based, into the columns at the specified index.void
setValuesInHeader
(IHeaderAccess header) set the options values, that are hdu based, into the header.
-
Method Details
-
addColumnsToTable
Add the columns that hold the metadata for the parameters that are column based to the dhu.- Parameters:
hdu
- the hdu to add the column- Throws:
FitsException
- if the column could not be added.
-
copy
create a copy of this parameter for another option (normally a copy of the current option).- Parameters:
option
- the new option for the copied parameter- Returns:
- this (builder pattern)
-
setTileIndex
void setTileIndex(int index) Initialize parameters for the given tile index- Parameters:
index
- the 0-based tile index
-
getValuesFromColumn
void getValuesFromColumn(int index) extract the option data from the column and set it in the option.- Parameters:
index
- the index in the column.
-
getValuesFromHeader
extract the option values that are represented by headers from the hdu header.- Parameters:
header
- the header to extract the option values.
-
initializeColumns
void initializeColumns(IHeaderAccess header, BinaryTable binaryTable, int size) throws FitsException initialize the column based options of the compression algorithm from the binary table.- Parameters:
header
- the header of the hdubinaryTable
- the table of the hdusize
- the column size- Throws:
FitsException
- if the column could not be initialized
-
initializeColumns
void initializeColumns(int length) initialize the column based parameter to the specified column length.- Parameters:
length
- the column length.
-
setValuesInColumn
void setValuesInColumn(int index) set the option values, that are column based, into the columns at the specified index.- Parameters:
index
- the index in the columns to set.
-
setValueInColumn
Deprecated.Old, inconsistent method naming. UsesetValuesInColumn(int)
instead. set the option values, that are column based, into the columns at the specified index.- Parameters:
index
- the index in the columns to set.
-
setValuesInHeader
set the options values, that are hdu based, into the header.- Parameters:
header
- the header to set the option value- Throws:
HeaderCardException
- if the header could not be set.
-