|
ifw-daq
1.0.0
IFW Data Acquisition modules
|
Go to the documentation of this file.
8 #ifndef DAQ_OCM_DAQ_FITS_KEYWORD_HPP_
9 #define DAQ_OCM_DAQ_FITS_KEYWORD_HPP_
28 using ValueType = std::variant<std::string, int64_t, uint64_t, double, bool>;
50 template <
class Trait>
56 char const* string_value,
57 std::optional<std::
string>
comment = std::nullopt);
60 std::optional<std::
string>
comment = std::nullopt) noexcept;
119 template <
class Trait>
120 std::ostream&
operator<<(std::ostream& os, BasicKeyword<Trait>
const& kw);
122 template <
class Trait>
174 #endif // #ifndef DAQ_OCM_DAQ_KEYWORD_HPP_
std::variant< ValueKeyword, EsoKeyword > KeywordVariant
The different variants of keywords that are supported.
BasicKeyword(BasicKeyword &&) noexcept=default
BasicKeyword(BasicKeyword const &)=default
bool NameEquals(KeywordVariant const &lhs, KeywordVariant const &rhs) noexcept
Compare keyword names of keyword of the same type.
void UpdateKeywords(KeywordVector &to, KeywordVector const &from)
Updates a with keywords from b.
std::variant< std::string, int64_t, uint64_t, double, bool > ValueType
bool operator<(BasicKeyword const &rhs) const noexcept
Uses name property as the sorting index.
A type safe version of FormattedKeyword that consist of the three basic components of a FITS keyword ...
std::optional< std::string > comment
std::ostream & operator<<(std::ostream &os, BasicKeyword< Trait > const &kw)
Non template base class that is purely used to avoid type-deduction issues of ValueType.
std::vector< KeywordVariant > KeywordVector
Vector of keywords.