Class HeaderAccess
java.lang.Object
nom.tam.fits.compression.provider.param.api.HeaderAccess
- All Implemented Interfaces:
IHeaderAccess
Deprecated.
(for internal use) Access to FITS header values with runtime exceptions only. Regular header access throws
HeaderCardExceptions, which are hard exceptions. They really should have been softer runtime exceptions from
the start, but unfortunately that was choice this library made a very long time ago, and we therefore stick to it, at
least until the next major code revision (major version 2 at the earliest). So this class provides an alternative
access to headers converting any HeaderCardExceptions to IllegalArgumentException.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionHeaderAccess(Header header) Deprecated.Creates a new access to modifying aHeaderCardwithout the hard exceptions thatHeaderCardmay throw. -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface nom.tam.fits.compression.provider.param.api.IHeaderAccess
addValue, addValue, findCard, findCard
-
Constructor Details
-
HeaderAccess
Deprecated.Creates a new access to modifying a
HeaderCardwithout the hard exceptions thatHeaderCardmay throw.- Parameters:
header- the FITS header we wish to access and modify
-
-
Method Details
-
getHeader
Deprecated.Returns the header that this class is providing access to.- Specified by:
getHeaderin interfaceIHeaderAccess- Returns:
- the Header that we access through this class
- Since:
- 1.19
-
Headerthrew hardHeaderCardException, and this class was added so we can convert these into softIllegalArgumentExceptioninstead. However, now that we demotedHeaderCardExceptionto be soft exceptions itself, there is no reason to convert. It just adds confusion.