module Language.Drasil.Choices (
Choices(..), Architecture (..), makeArchit, DataInfo(..), makeData, Maps(..),
makeMaps, spaceToCodeType, Constraints(..), makeConstraints, ODE(..), makeODE,
DocConfig(..), makeDocConfig, LogConfig(..), makeLogConfig, OptionalFeatures(..),
makeOptFeats, ExtLib(..), Modularity(..), Structure(..),
ConstantStructure(..), ConstantRepr(..), ConceptMatchMap, MatchedConceptMap,
CodeConcept(..), matchConcepts, SpaceMatch, matchSpaces, ImplementationType(..),
ConstraintBehaviour(..), Comments(..), Verbosity(..), Visibility(..),
Logging(..), AuxFile(..), getSampleData, hasSampleInput, defaultChoices,
choicesSent, showChs, InternalConcept(..)) where
import Language.Drasil hiding (None, Var)
import Language.Drasil.Code.Code (spaceToCodeType)
import Language.Drasil.Code.Lang (Lang(..))
import Language.Drasil.Data.ODEInfo (ODEInfo)
import Language.Drasil.Data.ODELibPckg (ODELibPckg)
import Language.Drasil.Mod (Name)
import Data.Map (Map)
import qualified Data.Map as Map
import Drasil.GOOL (CodeType)
import Control.Lens ((^.))
data Choices = Choices {
Choices -> [Lang]
lang :: [Lang],
Choices -> Architecture
architecture :: Architecture,
Choices -> DataInfo
dataInfo :: DataInfo,
Choices -> Maps
maps :: Maps,
Choices -> OptionalFeatures
optFeats :: OptionalFeatures,
Choices -> Constraints
srsConstraints :: Constraints,
Choices -> [ExtLib]
extLibs :: [ExtLib],
Choices -> InternalConcept -> Name
icNames :: InternalConcept -> Name,
Choices -> Int
folderVal :: Int
}
class RenderChoices a where
showChs :: a -> Sentence
showChsList :: [a] -> Sentence
showChsList [] = Name -> Sentence
S Name
"None"
showChsList [a]
lst = [Sentence] -> Sentence
foldlSent_ ((a -> Sentence) -> [a] -> [Sentence]
forall a b. (a -> b) -> [a] -> [b]
map a -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs [a]
lst)
data Architecture = Archt {
Architecture -> Modularity
modularity :: Modularity,
Architecture -> ImplementationType
impType :: ImplementationType
}
makeArchit :: Modularity -> ImplementationType -> Architecture
makeArchit :: Modularity -> ImplementationType -> Architecture
makeArchit = Modularity -> ImplementationType -> Architecture
Archt
data Modularity = Modular
| Unmodular
instance RenderChoices Modularity where
showChs :: Modularity -> Sentence
showChs Modularity
Unmodular = Name -> Sentence
S Name
"Unmodular"
showChs Modularity
Modular = Name -> Sentence
S Name
"Modular"
data ImplementationType = Library
| Program
instance RenderChoices ImplementationType where
showChs :: ImplementationType -> Sentence
showChs ImplementationType
Library = Name -> Sentence
S Name
"Library"
showChs ImplementationType
Program = Name -> Sentence
S Name
"Program"
data DataInfo = DataInfo {
DataInfo -> Structure
inputStructure :: Structure,
DataInfo -> ConstantStructure
constStructure :: ConstantStructure,
DataInfo -> ConstantRepr
constRepr :: ConstantRepr
}
makeData :: Structure -> ConstantStructure -> ConstantRepr -> DataInfo
makeData :: Structure -> ConstantStructure -> ConstantRepr -> DataInfo
makeData = Structure -> ConstantStructure -> ConstantRepr -> DataInfo
DataInfo
data Structure = Unbundled
| Bundled
instance RenderChoices Structure where
showChs :: Structure -> Sentence
showChs Structure
Unbundled = Name -> Sentence
S Name
"Unbundled"
showChs Structure
Bundled = Name -> Sentence
S Name
"Bundled"
data ConstantStructure = Inline
| WithInputs
| Store Structure
instance RenderChoices ConstantStructure where
showChs :: ConstantStructure -> Sentence
showChs ConstantStructure
Inline = Name -> Sentence
S Name
"Inline"
showChs ConstantStructure
WithInputs = Name -> Sentence
S Name
"WithInputs"
showChs (Store Structure
Unbundled) = Name -> Sentence
S Name
"Store Unbundled"
showChs (Store Structure
Bundled) = Name -> Sentence
S Name
"Store Bundled"
data ConstantRepr = Var
| Const
instance RenderChoices ConstantRepr where
showChs :: ConstantRepr -> Sentence
showChs ConstantRepr
Var = Name -> Sentence
S Name
"Var"
showChs ConstantRepr
Const = Name -> Sentence
S Name
"Const"
data Maps = Maps {
Maps -> ConceptMatchMap
conceptMatch :: ConceptMatchMap,
Maps -> SpaceMatch
spaceMatch :: SpaceMatch
}
makeMaps :: ConceptMatchMap -> SpaceMatch -> Maps
makeMaps :: ConceptMatchMap -> SpaceMatch -> Maps
makeMaps = ConceptMatchMap -> SpaceMatch -> Maps
Maps
type ConceptMatchMap = Map UID [CodeConcept]
type MatchedConceptMap = Map UID CodeConcept
data CodeConcept = Pi deriving CodeConcept -> CodeConcept -> Bool
(CodeConcept -> CodeConcept -> Bool)
-> (CodeConcept -> CodeConcept -> Bool) -> Eq CodeConcept
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: CodeConcept -> CodeConcept -> Bool
== :: CodeConcept -> CodeConcept -> Bool
$c/= :: CodeConcept -> CodeConcept -> Bool
/= :: CodeConcept -> CodeConcept -> Bool
Eq
instance RenderChoices CodeConcept where
showChs :: CodeConcept -> Sentence
showChs CodeConcept
Pi = Name -> Sentence
S Name
"Pi"
matchConcepts :: (HasUID c) => [(c, [CodeConcept])] -> ConceptMatchMap
matchConcepts :: forall c. HasUID c => [(c, [CodeConcept])] -> ConceptMatchMap
matchConcepts = [(UID, [CodeConcept])] -> ConceptMatchMap
forall k a. Ord k => [(k, a)] -> Map k a
Map.fromList ([(UID, [CodeConcept])] -> ConceptMatchMap)
-> ([(c, [CodeConcept])] -> [(UID, [CodeConcept])])
-> [(c, [CodeConcept])]
-> ConceptMatchMap
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((c, [CodeConcept]) -> (UID, [CodeConcept]))
-> [(c, [CodeConcept])] -> [(UID, [CodeConcept])]
forall a b. (a -> b) -> [a] -> [b]
map (\(c
cnc,[CodeConcept]
cdc) -> (c
cnc c -> Getting UID c UID -> UID
forall s a. s -> Getting a s a -> a
^. Getting UID c UID
forall c. HasUID c => Getter c UID
Getter c UID
uid, [CodeConcept]
cdc))
type SpaceMatch = Space -> [CodeType]
matchSpace :: Space -> [CodeType] -> SpaceMatch -> SpaceMatch
matchSpace :: Space -> [CodeType] -> SpaceMatch -> SpaceMatch
matchSpace Space
_ [] SpaceMatch
_ = Name -> SpaceMatch
forall a. HasCallStack => Name -> a
error Name
"Must match each Space to at least one CodeType"
matchSpace Space
s [CodeType]
ts SpaceMatch
sm = \Space
sp -> if Space
sp Space -> Space -> Bool
forall a. Eq a => a -> a -> Bool
== Space
s then [CodeType]
ts else SpaceMatch
sm Space
sp
matchSpaces :: [(Space, [CodeType])] -> SpaceMatch
matchSpaces :: [(Space, [CodeType])] -> SpaceMatch
matchSpaces [(Space, [CodeType])]
spMtchs = [(Space, [CodeType])] -> SpaceMatch -> SpaceMatch
matchSpaces' [(Space, [CodeType])]
spMtchs SpaceMatch
spaceToCodeType
where matchSpaces' :: [(Space, [CodeType])] -> SpaceMatch -> SpaceMatch
matchSpaces' ((Space
s,[CodeType]
ct):[(Space, [CodeType])]
sms) SpaceMatch
sm = [(Space, [CodeType])] -> SpaceMatch -> SpaceMatch
matchSpaces' [(Space, [CodeType])]
sms (SpaceMatch -> SpaceMatch) -> SpaceMatch -> SpaceMatch
forall a b. (a -> b) -> a -> b
$ Space -> [CodeType] -> SpaceMatch -> SpaceMatch
matchSpace Space
s [CodeType]
ct SpaceMatch
sm
matchSpaces' [] SpaceMatch
sm = SpaceMatch
sm
data OptionalFeatures = OptFeats{
OptionalFeatures -> DocConfig
docConfig :: DocConfig,
OptionalFeatures -> LogConfig
logConfig :: LogConfig,
OptionalFeatures -> [AuxFile]
auxFiles :: [AuxFile]
}
makeOptFeats :: DocConfig -> LogConfig -> [AuxFile] -> OptionalFeatures
makeOptFeats :: DocConfig -> LogConfig -> [AuxFile] -> OptionalFeatures
makeOptFeats = DocConfig -> LogConfig -> [AuxFile] -> OptionalFeatures
OptFeats
data DocConfig = DocConfig {
:: [Comments],
DocConfig -> Verbosity
doxVerbosity :: Verbosity,
DocConfig -> Visibility
dates :: Visibility
}
makeDocConfig :: [Comments] -> Verbosity -> Visibility -> DocConfig
makeDocConfig :: [Comments] -> Verbosity -> Visibility -> DocConfig
makeDocConfig = [Comments] -> Verbosity -> Visibility -> DocConfig
DocConfig
data =
|
|
deriving Comments -> Comments -> Bool
(Comments -> Comments -> Bool)
-> (Comments -> Comments -> Bool) -> Eq Comments
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Comments -> Comments -> Bool
== :: Comments -> Comments -> Bool
$c/= :: Comments -> Comments -> Bool
/= :: Comments -> Comments -> Bool
Eq
instance RenderChoices Comments where
showChs :: Comments -> Sentence
showChs Comments
CommentFunc = Name -> Sentence
S Name
"CommentFunc"
showChs Comments
CommentClass = Name -> Sentence
S Name
"CommentClass"
showChs Comments
CommentMod = Name -> Sentence
S Name
"CommentMod"
data Verbosity = Verbose | Quiet
instance RenderChoices Verbosity where
showChs :: Verbosity -> Sentence
showChs Verbosity
Verbose = Name -> Sentence
S Name
"Verbose"
showChs Verbosity
Quiet = Name -> Sentence
S Name
"Quiet"
data Visibility = Show
| Hide
instance RenderChoices Visibility where
showChs :: Visibility -> Sentence
showChs Visibility
Show = Name -> Sentence
S Name
"Show"
showChs Visibility
Hide = Name -> Sentence
S Name
"Hide"
data LogConfig = LogConfig {
LogConfig -> [Logging]
logging :: [Logging],
LogConfig -> Name
logFile :: FilePath
}
makeLogConfig :: [Logging] -> FilePath -> LogConfig
makeLogConfig :: [Logging] -> Name -> LogConfig
makeLogConfig = [Logging] -> Name -> LogConfig
LogConfig
data Logging = LogFunc
| LogVar
deriving Logging -> Logging -> Bool
(Logging -> Logging -> Bool)
-> (Logging -> Logging -> Bool) -> Eq Logging
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Logging -> Logging -> Bool
== :: Logging -> Logging -> Bool
$c/= :: Logging -> Logging -> Bool
/= :: Logging -> Logging -> Bool
Eq
instance RenderChoices Logging where
showChs :: Logging -> Sentence
showChs Logging
LogFunc = Name -> Sentence
S Name
"LogFunc"
showChs Logging
LogVar = Name -> Sentence
S Name
"LogVar"
data AuxFile = SampleInput FilePath
| ReadME
deriving AuxFile -> AuxFile -> Bool
(AuxFile -> AuxFile -> Bool)
-> (AuxFile -> AuxFile -> Bool) -> Eq AuxFile
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AuxFile -> AuxFile -> Bool
== :: AuxFile -> AuxFile -> Bool
$c/= :: AuxFile -> AuxFile -> Bool
/= :: AuxFile -> AuxFile -> Bool
Eq
instance RenderChoices AuxFile where
showChs :: AuxFile -> Sentence
showChs (SampleInput Name
fp) = Name -> Sentence
S Name
"SampleInput" Sentence -> Sentence -> Sentence
+:+ Name -> Sentence
S Name
fp
showChs AuxFile
ReadME = Name -> Sentence
S Name
"ReadME"
getSampleData :: Choices -> Maybe FilePath
getSampleData :: Choices -> Maybe Name
getSampleData Choices
chs = [AuxFile] -> Maybe Name
getSampleData' (OptionalFeatures -> [AuxFile]
auxFiles (OptionalFeatures -> [AuxFile]) -> OptionalFeatures -> [AuxFile]
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs)
where getSampleData' :: [AuxFile] -> Maybe Name
getSampleData' [] = Maybe Name
forall a. Maybe a
Nothing
getSampleData' (SampleInput Name
fp:[AuxFile]
_) = Name -> Maybe Name
forall a. a -> Maybe a
Just Name
fp
getSampleData' (AuxFile
_:[AuxFile]
xs) = [AuxFile] -> Maybe Name
getSampleData' [AuxFile]
xs
hasSampleInput :: [AuxFile] -> Bool
hasSampleInput :: [AuxFile] -> Bool
hasSampleInput [] = Bool
False
hasSampleInput (SampleInput Name
_:[AuxFile]
_) = Bool
True
hasSampleInput (AuxFile
_:[AuxFile]
xs) = [AuxFile] -> Bool
hasSampleInput [AuxFile]
xs
data Constraints = Constraints{
Constraints -> ConstraintBehaviour
onSfwrConstraint :: ConstraintBehaviour,
Constraints -> ConstraintBehaviour
onPhysConstraint :: ConstraintBehaviour
}
makeConstraints :: ConstraintBehaviour -> ConstraintBehaviour -> Constraints
makeConstraints :: ConstraintBehaviour -> ConstraintBehaviour -> Constraints
makeConstraints = ConstraintBehaviour -> ConstraintBehaviour -> Constraints
Constraints
data ConstraintBehaviour = Warning
| Exception
instance RenderChoices ConstraintBehaviour where
showChs :: ConstraintBehaviour -> Sentence
showChs ConstraintBehaviour
Warning = Name -> Sentence
S Name
"Warning"
showChs ConstraintBehaviour
Exception = Name -> Sentence
S Name
"Exception"
newtype ExtLib = Math ODE
data ODE = ODE{
ODE -> [ODEInfo]
odeInfo :: [ODEInfo],
ODE -> [ODELibPckg]
odeLib :: [ODELibPckg]
}
makeODE :: [ODEInfo] -> [ODELibPckg] -> ODE
makeODE :: [ODEInfo] -> [ODELibPckg] -> ODE
makeODE = [ODEInfo] -> [ODELibPckg] -> ODE
ODE
defaultChoices :: Choices
defaultChoices :: Choices
defaultChoices = Choices {
lang :: [Lang]
lang = [Lang
Python],
architecture :: Architecture
architecture = Modularity -> ImplementationType -> Architecture
makeArchit Modularity
Modular ImplementationType
Program,
dataInfo :: DataInfo
dataInfo = Structure -> ConstantStructure -> ConstantRepr -> DataInfo
makeData Structure
Bundled ConstantStructure
Inline ConstantRepr
Const,
maps :: Maps
maps = ConceptMatchMap -> SpaceMatch -> Maps
makeMaps
([(SimpleQDef, [CodeConcept])] -> ConceptMatchMap
forall c. HasUID c => [(c, [CodeConcept])] -> ConceptMatchMap
matchConcepts ([] :: [(SimpleQDef, [CodeConcept])]))
SpaceMatch
spaceToCodeType,
optFeats :: OptionalFeatures
optFeats = DocConfig -> LogConfig -> [AuxFile] -> OptionalFeatures
makeOptFeats
([Comments] -> Verbosity -> Visibility -> DocConfig
makeDocConfig [] Verbosity
Verbose Visibility
Hide)
([Logging] -> Name -> LogConfig
makeLogConfig [] Name
"log.txt")
[AuxFile
ReadME],
srsConstraints :: Constraints
srsConstraints = ConstraintBehaviour -> ConstraintBehaviour -> Constraints
makeConstraints ConstraintBehaviour
Exception ConstraintBehaviour
Warning,
extLibs :: [ExtLib]
extLibs = [],
icNames :: InternalConcept -> Name
icNames = InternalConcept -> Name
defaultICName,
folderVal :: Int
folderVal = Int
4
}
choicesSent :: Choices -> [Sentence]
choicesSent :: Choices -> [Sentence]
choicesSent Choices
chs = ((Sentence, Sentence) -> Sentence)
-> [(Sentence, Sentence)] -> [Sentence]
forall a b. (a -> b) -> [a] -> [b]
map (Sentence, Sentence) -> Sentence
chsFieldSent [
(Name -> Sentence
S Name
"Languages", [Sentence] -> Sentence
foldlSent_ ([Sentence] -> Sentence) -> [Sentence] -> Sentence
forall a b. (a -> b) -> a -> b
$ (Lang -> Sentence) -> [Lang] -> [Sentence]
forall a b. (a -> b) -> [a] -> [b]
map (Name -> Sentence
S (Name -> Sentence) -> (Lang -> Name) -> Lang -> Sentence
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Lang -> Name
forall a. Show a => a -> Name
show) ([Lang] -> [Sentence]) -> [Lang] -> [Sentence]
forall a b. (a -> b) -> a -> b
$ Choices -> [Lang]
lang Choices
chs),
(Name -> Sentence
S Name
"Modularity", Modularity -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (Modularity -> Sentence) -> Modularity -> Sentence
forall a b. (a -> b) -> a -> b
$ Architecture -> Modularity
modularity (Architecture -> Modularity) -> Architecture -> Modularity
forall a b. (a -> b) -> a -> b
$ Choices -> Architecture
architecture Choices
chs),
(Name -> Sentence
S Name
"Input Structure", Structure -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (Structure -> Sentence) -> Structure -> Sentence
forall a b. (a -> b) -> a -> b
$ DataInfo -> Structure
inputStructure (DataInfo -> Structure) -> DataInfo -> Structure
forall a b. (a -> b) -> a -> b
$ Choices -> DataInfo
dataInfo Choices
chs),
(Name -> Sentence
S Name
"Constant Structure", ConstantStructure -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (ConstantStructure -> Sentence) -> ConstantStructure -> Sentence
forall a b. (a -> b) -> a -> b
$ DataInfo -> ConstantStructure
constStructure (DataInfo -> ConstantStructure) -> DataInfo -> ConstantStructure
forall a b. (a -> b) -> a -> b
$ Choices -> DataInfo
dataInfo Choices
chs),
(Name -> Sentence
S Name
"Constant Representation", ConstantRepr -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (ConstantRepr -> Sentence) -> ConstantRepr -> Sentence
forall a b. (a -> b) -> a -> b
$ DataInfo -> ConstantRepr
constRepr (DataInfo -> ConstantRepr) -> DataInfo -> ConstantRepr
forall a b. (a -> b) -> a -> b
$ Choices -> DataInfo
dataInfo Choices
chs),
(Name -> Sentence
S Name
"Implementation Type", ImplementationType -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (ImplementationType -> Sentence) -> ImplementationType -> Sentence
forall a b. (a -> b) -> a -> b
$ Architecture -> ImplementationType
impType (Architecture -> ImplementationType)
-> Architecture -> ImplementationType
forall a b. (a -> b) -> a -> b
$ Choices -> Architecture
architecture Choices
chs),
(Name -> Sentence
S Name
"Software Constraint Behaviour", ConstraintBehaviour -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (ConstraintBehaviour -> Sentence)
-> ConstraintBehaviour -> Sentence
forall a b. (a -> b) -> a -> b
$ Constraints -> ConstraintBehaviour
onSfwrConstraint (Constraints -> ConstraintBehaviour)
-> Constraints -> ConstraintBehaviour
forall a b. (a -> b) -> a -> b
$ Choices -> Constraints
srsConstraints Choices
chs),
(Name -> Sentence
S Name
"Physical Constraint Behaviour", ConstraintBehaviour -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (ConstraintBehaviour -> Sentence)
-> ConstraintBehaviour -> Sentence
forall a b. (a -> b) -> a -> b
$ Constraints -> ConstraintBehaviour
onPhysConstraint (Constraints -> ConstraintBehaviour)
-> Constraints -> ConstraintBehaviour
forall a b. (a -> b) -> a -> b
$ Choices -> Constraints
srsConstraints Choices
chs),
(Name -> Sentence
S Name
"Comments", [Comments] -> Sentence
forall a. RenderChoices a => [a] -> Sentence
showChsList ([Comments] -> Sentence) -> [Comments] -> Sentence
forall a b. (a -> b) -> a -> b
$ DocConfig -> [Comments]
comments (DocConfig -> [Comments]) -> DocConfig -> [Comments]
forall a b. (a -> b) -> a -> b
$ OptionalFeatures -> DocConfig
docConfig (OptionalFeatures -> DocConfig) -> OptionalFeatures -> DocConfig
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs),
(Name -> Sentence
S Name
"Dox Verbosity", Verbosity -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (Verbosity -> Sentence) -> Verbosity -> Sentence
forall a b. (a -> b) -> a -> b
$ DocConfig -> Verbosity
doxVerbosity (DocConfig -> Verbosity) -> DocConfig -> Verbosity
forall a b. (a -> b) -> a -> b
$ OptionalFeatures -> DocConfig
docConfig (OptionalFeatures -> DocConfig) -> OptionalFeatures -> DocConfig
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs),
(Name -> Sentence
S Name
"Dates", Visibility -> Sentence
forall a. RenderChoices a => a -> Sentence
showChs (Visibility -> Sentence) -> Visibility -> Sentence
forall a b. (a -> b) -> a -> b
$ DocConfig -> Visibility
dates (DocConfig -> Visibility) -> DocConfig -> Visibility
forall a b. (a -> b) -> a -> b
$ OptionalFeatures -> DocConfig
docConfig (OptionalFeatures -> DocConfig) -> OptionalFeatures -> DocConfig
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs),
(Name -> Sentence
S Name
"Log File Name", Name -> Sentence
S (Name -> Sentence) -> Name -> Sentence
forall a b. (a -> b) -> a -> b
$ LogConfig -> Name
logFile (LogConfig -> Name) -> LogConfig -> Name
forall a b. (a -> b) -> a -> b
$ OptionalFeatures -> LogConfig
logConfig (OptionalFeatures -> LogConfig) -> OptionalFeatures -> LogConfig
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs),
(Name -> Sentence
S Name
"Logging", [Logging] -> Sentence
forall a. RenderChoices a => [a] -> Sentence
showChsList ([Logging] -> Sentence) -> [Logging] -> Sentence
forall a b. (a -> b) -> a -> b
$ LogConfig -> [Logging]
logging (LogConfig -> [Logging]) -> LogConfig -> [Logging]
forall a b. (a -> b) -> a -> b
$ OptionalFeatures -> LogConfig
logConfig (OptionalFeatures -> LogConfig) -> OptionalFeatures -> LogConfig
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs),
(Name -> Sentence
S Name
"Auxiliary Files", [AuxFile] -> Sentence
forall a. RenderChoices a => [a] -> Sentence
showChsList ([AuxFile] -> Sentence) -> [AuxFile] -> Sentence
forall a b. (a -> b) -> a -> b
$ OptionalFeatures -> [AuxFile]
auxFiles (OptionalFeatures -> [AuxFile]) -> OptionalFeatures -> [AuxFile]
forall a b. (a -> b) -> a -> b
$ Choices -> OptionalFeatures
optFeats Choices
chs)
]
chsFieldSent :: (Sentence, Sentence) -> Sentence
chsFieldSent :: (Sentence, Sentence) -> Sentence
chsFieldSent (Sentence
rec, Sentence
chc) = Sentence
rec Sentence -> Sentence -> Sentence
+:+ Name -> Sentence
S Name
"selected as" Sentence -> Sentence -> Sentence
+:+. Sentence
chc
data InternalConcept =
InputConstraintsFn
| InputConstraintsMod
| WriteOutput
| DerivedValuesFn
| DerivedValuesMod
| GetInput
| InputParameters
| InputFormat
| OutputFormat
| Calculations
| Constants
deriving (InternalConcept -> InternalConcept -> Bool
(InternalConcept -> InternalConcept -> Bool)
-> (InternalConcept -> InternalConcept -> Bool)
-> Eq InternalConcept
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: InternalConcept -> InternalConcept -> Bool
== :: InternalConcept -> InternalConcept -> Bool
$c/= :: InternalConcept -> InternalConcept -> Bool
/= :: InternalConcept -> InternalConcept -> Bool
Eq, Eq InternalConcept
Eq InternalConcept =>
(InternalConcept -> InternalConcept -> Ordering)
-> (InternalConcept -> InternalConcept -> Bool)
-> (InternalConcept -> InternalConcept -> Bool)
-> (InternalConcept -> InternalConcept -> Bool)
-> (InternalConcept -> InternalConcept -> Bool)
-> (InternalConcept -> InternalConcept -> InternalConcept)
-> (InternalConcept -> InternalConcept -> InternalConcept)
-> Ord InternalConcept
InternalConcept -> InternalConcept -> Bool
InternalConcept -> InternalConcept -> Ordering
InternalConcept -> InternalConcept -> InternalConcept
forall a.
Eq a =>
(a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
$ccompare :: InternalConcept -> InternalConcept -> Ordering
compare :: InternalConcept -> InternalConcept -> Ordering
$c< :: InternalConcept -> InternalConcept -> Bool
< :: InternalConcept -> InternalConcept -> Bool
$c<= :: InternalConcept -> InternalConcept -> Bool
<= :: InternalConcept -> InternalConcept -> Bool
$c> :: InternalConcept -> InternalConcept -> Bool
> :: InternalConcept -> InternalConcept -> Bool
$c>= :: InternalConcept -> InternalConcept -> Bool
>= :: InternalConcept -> InternalConcept -> Bool
$cmax :: InternalConcept -> InternalConcept -> InternalConcept
max :: InternalConcept -> InternalConcept -> InternalConcept
$cmin :: InternalConcept -> InternalConcept -> InternalConcept
min :: InternalConcept -> InternalConcept -> InternalConcept
Ord)
defaultICName :: InternalConcept -> Name
defaultICName :: InternalConcept -> Name
defaultICName InternalConcept
InputConstraintsFn = Name
"input_constraints"
defaultICName InternalConcept
InputConstraintsMod = Name
"InputConstraints"
defaultICName InternalConcept
WriteOutput = Name
"write_output"
defaultICName InternalConcept
DerivedValuesFn = Name
"derived_values"
defaultICName InternalConcept
DerivedValuesMod = Name
"DerivedValues"
defaultICName InternalConcept
GetInput = Name
"get_input"
defaultICName InternalConcept
InputParameters = Name
"InputParameters"
defaultICName InternalConcept
InputFormat = Name
"InputFormat"
defaultICName InternalConcept
OutputFormat = Name
"OutputFormat"
defaultICName InternalConcept
Calculations = Name
"Calculations"
defaultICName InternalConcept
Constants = Name
"Constants"