EleFits  4.0.1
A modern C++ API on top of CFitsIO

◆ readKeywordsValues()

std::map<std::string, std::string> Euclid::Fits::Header::readKeywordsValues ( KeywordCategory  categories = KeywordCategory::All) const

List keywords and their values.

Parameters
categoriesThe set of selected categories

Read or parse keywords or records depending on their categories: mandatory, reserved, user, or comment.

Categories can be combined, e.g.:

Example usages:

auto keywords = h.readKeywords(~KeywordCategory::Comment);
auto keyVals = h.readKeywordValues();
auto header = h.readAll();
auto records = h.parseAll(KeywordCategory::Reserved);

where h is a Header.

See also
KeywordCategory
Warning
If several records have the same keywords, the returned value is a line break-separated list.
Euclid::Fits::KeywordCategory::Reserved
static const KeywordCategory Reserved
Optional standard keywords excluding COMMENT and HISTORY.
Definition: KeywordCategory.h:44
Euclid::Fits::KeywordCategory::User
static const KeywordCategory User
User-defined keywords.
Definition: KeywordCategory.h:46
Euclid::Fits::KeywordCategory::Comment
static const KeywordCategory Comment
COMMENT and HISTORY keywords (non-valued reserved keywords).
Definition: KeywordCategory.h:45