module Options.Types
( OptionDefinitions(..)
, Group(..)
, OptionKey(..)
, Location(..)
, OptionInfo(..)
) where
data OptionDefinitions = OptionDefinitions [OptionInfo] [(String, [OptionInfo])]
data Group = Group
{
groupName :: String
, groupTitle :: String
, groupDescription :: String
}
deriving (Eq, Show)
data OptionKey
= OptionKey String
| OptionKeyHelpSummary
| OptionKeyHelpGroup String
| OptionKeyGenerated Integer
| OptionKeyIgnored
deriving (Eq, Ord, Show)
data Location = Location
{ locationPackage :: String
, locationModule :: String
, locationFilename :: String
, locationLine :: Integer
}
deriving (Eq, Show)
data OptionInfo = OptionInfo
{ optionInfoKey :: OptionKey
, optionInfoShortFlags :: [Char]
, optionInfoLongFlags :: [String]
, optionInfoDefault :: String
, optionInfoUnary :: Bool
, optionInfoUnaryOnly :: Bool
, optionInfoDescription :: String
, optionInfoGroup :: Maybe Group
, optionInfoLocation :: Maybe Location
, optionInfoTypeName :: String
}
deriving (Eq, Show)