astGetFits <X >

Get a named keyword value from a FitsChan


This is a family of functions which gets a value for a named keyword, or the value of the current card, from a FitsChan using one of several different data types. The data type of the returned value is selected by replacing <X > in the function name by one of the following strings representing the recognised FITS data types:

The data type of the " value" parameter

depends on <X > as follows:


int astGetFits <X >( AstFitsChan this, const char name, <X >type value )


Pointer to the FitsChan.
Pointer to a null-terminated character string containing the FITS keyword name. This may be a complete FITS header card, in which case the keyword to use is extracted from it. No more than 80 characters are read from this string. If NULL is supplied, the value of the current card is returned.
A pointer to a buffer to receive the keyword value. The data type depends on <X > as described above. The conents of the buffer on entry are left unchanged if the keyword is not found.

Returned Value

astGetFits <X > <X >()
A value of zero is returned if the keyword was not found in the FitsChan (no error is reported). Otherwise, a value of one is returned.