module Telescope.Fits.Header
  ( lookup
  , Header (..)
  -- , Keyword
  , Value (..)
  -- , Comment
  , keyword
  , addComment
  ) where

import Data.Fits
import Data.Text (Text)
import Prelude hiding (lookup)


keyword :: Text -> Value -> Maybe Text -> HeaderRecord
keyword :: Text -> Value -> Maybe Text -> HeaderRecord
keyword Text
k Value
v Maybe Text
mc = KeywordRecord -> HeaderRecord
Keyword (KeywordRecord -> HeaderRecord) -> KeywordRecord -> HeaderRecord
forall a b. (a -> b) -> a -> b
$ Text -> Value -> Maybe Text -> KeywordRecord
KeywordRecord Text
k Value
v Maybe Text
mc


addComment :: Text -> KeywordRecord -> KeywordRecord
addComment :: Text -> KeywordRecord -> KeywordRecord
addComment Text
c KeywordRecord
kr = KeywordRecord
kr{_comment :: Maybe Text
_comment = Text -> Maybe Text
forall a. a -> Maybe a
Just Text
c}

-- addComment :: Comment -> Header -> Header
-- addComment c =