module Bio.PDB.Type where
import Control.DeepSeq (NFData (..))
import Data.Map.Strict (Map)
import Data.Text (Text)
import Data.Vector (Vector)
import GHC.Generics (Generic)
data PDB = PDB { title :: Text
, models :: Vector Model
, remarks :: Map RemarkCode RemarkData
, otherFields :: Map FieldType FieldData
}
deriving (Show, Eq, Generic, NFData)
type RemarkCode = Maybe Int
type RemarkData = Vector Text
type FieldData = Vector Text
data FieldType
=
HEADER
| OBSLTE
| SPLT
| CAVEAT
| COMPND
| SOURCE
| KEYWDS
| EXPDTA
| NUMMDL
| MDLTYP
| AUTHOR
| REVDAT
| SPRSDE
| JRNL
| DBREF
| DBREF1
| DBREF2
| SEQADV
| SEQRES
| MODRES
| HET
| FORMUL
| HETNAM
| HETSYN
| HELIX
| SHEET
| SSBOND
| LINK
| CISPEP
| SITE
| CRYST1
| MTRIXn
| ORIGXn
| SCALEn
| MASTER
deriving (Show, Eq, Read, Generic, NFData)
type Model = Vector Chain
type Chain = Vector Atom
data Atom = Atom { atomSerial :: Int
, atomName :: Text
, atomAltLoc :: Char
, atomResName :: Text
, atomChainID :: Char
, atomResSeq :: Int
, atomICode :: Char
, atomX :: Float
, atomY :: Float
, atomZ :: Float
, atomOccupancy :: Float
, atomTempFactor :: Float
, atomElement :: Text
, atomCharge :: Text
}
deriving (Show, Eq, Generic, NFData)