hsp-0.5.1: Haskell Server Pages is a library for writing dynamic server-side web pages.




type HSP = HSPT IOSource

The HSP monad is a reader wrapper around the IO monad, but extended with an XMLGenerator wrapper. type HSP' = ReaderT HSPEnv IO type HSP = XMLGenT HSP'

type HSPT m = XMLGenT (HSPT' m)Source

runHSP :: Maybe XMLMetaData -> HSP a -> HSPEnv -> IO (Maybe XMLMetaData, a)Source

Runs a HSP computation in a particular environment. Since HSP wraps the IO monad, the result of running it will be an IO computation.

getEnv :: HSP HSPEnvSource

Supplies the HSP environment.

doIO :: IO a -> HSP aSource

Execute an IO computation within the HSP monad.

catch :: HSP a -> (Exception -> HSP a) -> HSP aSource

Catch a user-caused exception.

module HSP.Env

module HSP.XML

module HSP.HTML

class Monad m => IsAttrValue m a whereSource

extract :: GetAttrValue a => Name -> Attributes -> (Maybe a, Attributes)Source

genElement :: XMLGen m => Name -> [XMLGenT m [Attribute m]] -> [XMLGenT m [Child m]] -> XMLGenT m (XML m)

genEElement :: XMLGen m => Name -> [XMLGenT m [Attribute m]] -> XMLGenT m (XML m)