{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE FunctionalDependencies #-}
module Drasil.GProc.RendererClassesProc (
ProcRenderSym, RenderFile(..), RenderMod(..), ModuleElim(..),
ProcRenderMethod(..)
) where
import Drasil.Shared.InterfaceCommon (Label, Block, MethodSym)
import qualified Drasil.GProc.InterfaceProc as IP (FileSym(..), ModuleSym)
import Drasil.Shared.State (FS, MS)
import Drasil.Shared.AST (ParamData)
import Text.PrettyPrint.HughesPJ (Doc)
import Drasil.Shared.RendererClassesCommon (CommonRenderSym, BlockCommentSym(..),
RenderMethod(..), MSMthdType)
class (CommonRenderSym r vis stmt mthd bod block, MethodSym r vis mthd bod,
IP.ModuleSym r mod mthd, IP.FileSym r file mod, RenderFile r file mod,
RenderMod r mod, ModuleElim r mod, ProcRenderMethod r vis mthd bod
) => ProcRenderSym r vis stmt mthd file mod bod block
class (BlockCommentSym r) => RenderFile r file mod | r -> file mod where
top :: r mod -> r Block
bottom :: r Block
:: FS (r file) -> FS (r Doc) -> FS (r file)
fileFromData :: FilePath -> FS (r mod) -> FS (r file)
class RenderMod r mod | r -> mod where
modFromData :: String -> FS Doc -> FS (r mod)
updateModuleDoc :: (Doc -> Doc) -> r mod -> r mod
class ModuleElim r mod | r -> mod where
module' :: r mod -> Doc
class (RenderMethod r mthd) => ProcRenderMethod r vis mthd bod | r -> vis bod where
intFunc :: Bool -> Label -> r vis -> MSMthdType r ->
[MS (r ParamData)] -> MS (r bod) -> MS (r mthd)