Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Models
Description
This module defines the core data types and structures used throughout the application for representing chemical reactions, mechanisms, and interactants. It includes various identifiers, relationship types, and masks for data handling, as well as details on the process and health checks.
Exports
ReactionID
,CatalystID
,MoleculeID
- Unique identifiers for reactions, catalysts, and molecules.ACCELERATE
,PRODUCT_FROM
,REAGENT_IN
- Relationship types that define connections between reactions and interactants.Reaction
,Catalyst
,Molecule
- Data types representing different chemical entities and their relationships.Interactant
,Explain
- Types for handling interactants and mechanism explanations in the context of reactions.NodeMask
,PathMask
,RawMechanismDetailsMask
,RawReactionDetailsMask
,RelMask
- WEB masks to abstract away direct types from the Hasbolt library for better type safety and ease of use.ReactionDetails
,MechanismDetails
,ProcessDetails
- Data types that encapsulate detailed information about reactions and mechanisms.ReactionNode
,MechanismNode
,RawReactionDetails
,RawMechanismDetails
- Nodes representing the raw data structures in the graph database.MechanismID
,StageID
- Identifiers for mechanisms and stages within those mechanisms.HealthCheck
- Type used for performing health checks on the database connection.
Synopsis
- type ReactionID = Int
- type CatalystID = Int
- type MoleculeID = Int
- data ACCELERATE = ACCELERATE {
- temperature :: [Float]
- pressure :: [Float]
- data Catalyst = Catalyst {}
- data Molecule = Molecule {}
- newtype PRODUCT_FROM = PRODUCT_FROM {}
- newtype REAGENT_IN = REAGENT_IN {}
- data Reaction = Reaction {}
- data Interactant
- data Explain
- newtype NodeMask = NodeMask {}
- data PathMask = PathMask {}
- data RawMechanismDetailsMask = RawMechanismDetailsMask {}
- data RawReactionDetailsMask = RawReactionDetailsMask {
- rawReactionMask :: NodeMask
- rawReagentsMask :: [NodeMask]
- rawProductsMask :: [NodeMask]
- rawInboundMask :: [RelMask]
- rawOutboundMask :: [RelMask]
- rawAccelerateMask :: [RelMask]
- rawCatalystsMask :: [NodeMask]
- newtype RelMask = RelMask {
- relPropsMask :: Map Text Value
- data ReactionDetails = ReactionDetails {
- reaction :: Reaction
- inboundReagents :: [(REAGENT_IN, Molecule)]
- outboundProducts :: [(PRODUCT_FROM, Molecule)]
- conditions :: [(ACCELERATE, Catalyst)]
- data MechanismDetails = MechanismDetails {
- mechanismContext :: (Mechanism, FOLLOW)
- stageInteractants :: [(Stage, [Interactant])]
- data ProcessDetails = ProcessDetails {}
- type ReactionNode = Node
- type MechanismNode = Node
- data RawReactionDetails = RawReactionDetails {
- rawReaction :: Node
- rawReagents :: [Node]
- rawProducts :: [Node]
- rawInbound :: [Relationship]
- rawOutbound :: [Relationship]
- rawAccelerate :: [Relationship]
- rawCatalysts :: [Node]
- data RawMechanismDetails = RawMechanismDetails {
- rawMechanism :: Node
- rawInteractants :: [Node]
- rawInclude :: [Relationship]
- rawStages :: [Node]
- rawFollow :: Relationship
- type MechanismID = Int
- type StageID = Int
- data Mechanism = Mechanism {}
- newtype FOLLOW = FOLLOW {}
- data Stage = Stage {}
- data INCLUDE = INCLUDE
- data HealthCheck = HealthCheck {}
Documentation
type ReactionID = Int #
type CatalystID = Int #
type MoleculeID = Int #
data ACCELERATE #
def
- the default value for ACCELERATE
corresponds to Standard Temperature and Pressure (STP):
- temperature
= 273.15 K (Kelvin)
- pressure
= 101.325 kPa (kilopascals)
Constructors
ACCELERATE | |
Fields
|
Instances
Constructors
Catalyst | |
Fields |
Instances
FromJSON Catalyst # | |
Defined in Models.Chemical | |
ToJSON Catalyst # | |
Generic Catalyst # | |
Show Catalyst # | |
Default Catalyst # | |
Defined in Models.Chemical | |
Eq Catalyst # | |
ElemInteractant (Catalyst, Identity) # | Converts a Neo4j node with label Catalyst to a Haskell |
Defined in Domain.Converter.Instances Methods exactInteractant :: Elem -> Either ParsingError (Catalyst, Identity) # | |
type Rep Catalyst # | |
Defined in Models.Chemical type Rep Catalyst = D1 ('MetaData "Catalyst" "Models.Chemical" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Catalyst" 'PrefixI 'True) (S1 ('MetaSel ('Just "catalystId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 CatalystID) :*: (S1 ('MetaSel ('Just "catalystSmiles") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String) :*: S1 ('MetaSel ('Just "catalystName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe String))))) |
Constructors
Molecule | |
Fields |
Instances
FromJSON Molecule # | |
Defined in Models.Chemical | |
ToJSON Molecule # | |
Generic Molecule # | |
Show Molecule # | |
Eq Molecule # | |
ElemInteractant (Molecule, Identity) # | Converts a Neo4j node with label Molecule to a Haskell |
Defined in Domain.Converter.Instances Methods exactInteractant :: Elem -> Either ParsingError (Molecule, Identity) # | |
type Rep Molecule # | |
Defined in Models.Chemical type Rep Molecule = D1 ('MetaData "Molecule" "Models.Chemical" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Molecule" 'PrefixI 'True) (S1 ('MetaSel ('Just "moleculeId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 MoleculeID) :*: (S1 ('MetaSel ('Just "moleculeSmiles") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String) :*: S1 ('MetaSel ('Just "moleculeIupacName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String)))) |
newtype PRODUCT_FROM #
Constructors
PRODUCT_FROM | |
Fields |
Instances
newtype REAGENT_IN #
Constructors
REAGENT_IN | |
Fields |
Instances
Constructors
Reaction | |
Fields |
Instances
FromJSON Reaction # | |
Defined in Models.Chemical | |
ToJSON Reaction # | |
Generic Reaction # | |
Show Reaction # | |
Eq Reaction # | |
ElemInteractant (Reaction, Identity) # | Converts a Neo4j node with label Reaction to a Haskell |
Defined in Domain.Converter.Instances Methods exactInteractant :: Elem -> Either ParsingError (Reaction, Identity) # | |
type Rep Reaction # | |
Defined in Models.Chemical type Rep Reaction = D1 ('MetaData "Reaction" "Models.Chemical" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Reaction" 'PrefixI 'True) (S1 ('MetaSel ('Just "reactionId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ReactionID) :*: S1 ('MetaSel ('Just "reactionName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String))) |
data Interactant #
Primary type for Reaction explanation
Constructors
IAccelerate ACCELERATE | |
ICatalyst Catalyst | |
IMolecule Molecule | |
IProductFrom PRODUCT_FROM | |
IReagentIn REAGENT_IN | |
IReaction Reaction |
Instances
Primary type for Mechanism explanation
Constructors
EMechanism Mechanism | |
EStage Stage |
Instances
Generic Explain # | |
Show Explain # | |
Eq Explain # | |
type Rep Explain # | |
Defined in Models.Interactant type Rep Explain = D1 ('MetaData "Explain" "Models.Interactant" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "EMechanism" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Mechanism)) :+: C1 ('MetaCons "EStage" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Stage))) |
Constructors
NodeMask | |
Fields |
Constructors
PathMask | |
Fields
|
Instances
FromJSON PathMask # | |
Defined in Models.Mask | |
ToJSON PathMask # | |
Generic PathMask # | |
Show PathMask # | |
ElemInteractant PathMask # | Converts a Neo4j path to a Haskell |
Defined in Domain.Converter.Instances Methods | |
Eq PathMask # | |
type Rep PathMask # | |
Defined in Models.Mask type Rep PathMask = D1 ('MetaData "PathMask" "Models.Mask" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "PathMask" 'PrefixI 'True) (S1 ('MetaSel ('Just "pathNodesMask") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Interactant]) :*: (S1 ('MetaSel ('Just "pathRelationshipsMask") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Interactant]) :*: S1 ('MetaSel ('Just "pathSequenceMask") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Int])))) |
data RawMechanismDetailsMask #
Constructors
RawMechanismDetailsMask | |
Fields
|
Instances
Show RawMechanismDetailsMask # | |
Defined in Models.Mask Methods showsPrec :: Int -> RawMechanismDetailsMask -> ShowS # show :: RawMechanismDetailsMask -> String # showList :: [RawMechanismDetailsMask] -> ShowS # | |
Eq RawMechanismDetailsMask # | |
Defined in Models.Mask Methods (==) :: RawMechanismDetailsMask -> RawMechanismDetailsMask -> Bool # (/=) :: RawMechanismDetailsMask -> RawMechanismDetailsMask -> Bool # |
data RawReactionDetailsMask #
Constructors
RawReactionDetailsMask | |
Fields
|
Instances
Show RawReactionDetailsMask # | |
Defined in Models.Mask Methods showsPrec :: Int -> RawReactionDetailsMask -> ShowS # show :: RawReactionDetailsMask -> String # showList :: [RawReactionDetailsMask] -> ShowS # | |
Eq RawReactionDetailsMask # | |
Defined in Models.Mask Methods (==) :: RawReactionDetailsMask -> RawReactionDetailsMask -> Bool # (/=) :: RawReactionDetailsMask -> RawReactionDetailsMask -> Bool # |
Constructors
RelMask | |
Fields
|
data ReactionDetails #
Constructors
ReactionDetails | |
Fields
|
Instances
data MechanismDetails #
Constructors
MechanismDetails | |
Fields
|
Instances
data ProcessDetails #
Constructors
ProcessDetails | |
Instances
type ReactionNode = Node #
Represents a node in a reaction graph
type MechanismNode = Node #
Represents a node in a mechanism graph
data RawReactionDetails #
Constructors
RawReactionDetails | |
Fields
|
Instances
Show RawReactionDetails # | |
Defined in Models.Graph Methods showsPrec :: Int -> RawReactionDetails -> ShowS # show :: RawReactionDetails -> String # showList :: [RawReactionDetails] -> ShowS # | |
Eq RawReactionDetails # | |
Defined in Models.Graph Methods (==) :: RawReactionDetails -> RawReactionDetails -> Bool # (/=) :: RawReactionDetails -> RawReactionDetails -> Bool # |
data RawMechanismDetails #
Constructors
RawMechanismDetails | |
Fields
|
Instances
Show RawMechanismDetails # | |
Defined in Models.Graph Methods showsPrec :: Int -> RawMechanismDetails -> ShowS # show :: RawMechanismDetails -> String # showList :: [RawMechanismDetails] -> ShowS # | |
Eq RawMechanismDetails # | |
Defined in Models.Graph Methods (==) :: RawMechanismDetails -> RawMechanismDetails -> Bool # (/=) :: RawMechanismDetails -> RawMechanismDetails -> Bool # |
type MechanismID = Int #
Constructors
Mechanism | |
Fields |
Instances
Constructors
FOLLOW | |
Fields |
Instances
FromJSON FOLLOW # | |
Defined in Models.Mechanism | |
ToJSON FOLLOW # | |
Generic FOLLOW # | |
Show FOLLOW # | |
Eq FOLLOW # | |
ElemInteractant (FOLLOW, Identity) # | Converts a Neo4j relationship of type FOLLOW to a Haskell |
Defined in Domain.Converter.Instances Methods exactInteractant :: Elem -> Either ParsingError (FOLLOW, Identity) # | |
type Rep FOLLOW # | |
Defined in Models.Mechanism |
Constructors
Stage | |
Fields
|
Instances
FromJSON Stage # | |
Defined in Models.Mechanism | |
ToJSON Stage # | |
Generic Stage # | |
Show Stage # | |
Eq Stage # | |
ElemInteractant (Stage, Identity) # | Converts a Neo4j node with label Stage to a Haskell |
Defined in Domain.Converter.Instances Methods exactInteractant :: Elem -> Either ParsingError (Stage, Identity) # | |
type Rep Stage # | |
Defined in Models.Mechanism type Rep Stage = D1 ('MetaData "Stage" "Models.Mechanism" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "Stage" 'PrefixI 'True) ((S1 ('MetaSel ('Just "stageOrder") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 StageID) :*: S1 ('MetaSel ('Just "stageName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String)) :*: (S1 ('MetaSel ('Just "stageDescription") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String) :*: S1 ('MetaSel ('Just "stageProducts") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [String])))) |
Constructors
INCLUDE |
Instances
FromJSON INCLUDE # | |
Defined in Models.Mechanism | |
ToJSON INCLUDE # | |
Generic INCLUDE # | |
Show INCLUDE # | |
Eq INCLUDE # | |
ElemInteractant (INCLUDE, Identity, Identity) # | Converts a Neo4j relationship of type INCLUDE to a Haskell |
Defined in Domain.Converter.Instances Methods exactInteractant :: Elem -> Either ParsingError (INCLUDE, Identity, Identity) # | |
type Rep INCLUDE # | |
data HealthCheck #
Constructors
HealthCheck | |
Instances
FromJSON HealthCheck # | |
Defined in Models.Common | |
ToJSON HealthCheck # | |
Defined in Models.Common Methods toJSON :: HealthCheck -> Value # toEncoding :: HealthCheck -> Encoding # toJSONList :: [HealthCheck] -> Value # toEncodingList :: [HealthCheck] -> Encoding # omitField :: HealthCheck -> Bool # | |
Generic HealthCheck # | |
Defined in Models.Common Associated Types type Rep HealthCheck :: Type -> Type # | |
Show HealthCheck # | |
Defined in Models.Common Methods showsPrec :: Int -> HealthCheck -> ShowS # show :: HealthCheck -> String # showList :: [HealthCheck] -> ShowS # | |
type Rep HealthCheck # | |
Defined in Models.Common type Rep HealthCheck = D1 ('MetaData "HealthCheck" "Models.Common" "chemist-preprocessor-0.1.0.0-inplace" 'False) (C1 ('MetaCons "HealthCheck" 'PrefixI 'True) (S1 ('MetaSel ('Just "status") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String) :*: S1 ('MetaSel ('Just "message") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 String))) |