Hets - the Heterogeneous Tool Set

Copyrightuni-bremen and DFKI
LicenseGPLv2 or higher, see LICENSE.txt
Maintainerr.pascanu@jacobs-university.de
Stabilityprovisional
Portabilityportable
Safe HaskellNone

PGIP.XMLparsing

Description

PGIP.XMLparsing contains commands for parsing or creating XML messages

Synopsis

Documentation

addPGIPHandshake :: CmdlPgipState -> CmdlPgipState

Generates the XML packet that contains information about what commands can the interface respond to

communicationStep :: CmdlPgipState -> CmdlState -> IO (CmdlPgipState, CmdlState)

The function executes a communication step, i.e. waits for input, processes the message and outputs the answer

timeoutReadPacket :: Int -> CmdlPgipState -> IO (Maybe String)

Reads from a handle, it waits only for a certain amount of time, if no input comes it will return Nothing

readPacket :: String -> Handle -> IO String

Waits until it reads an entire XML packet

cmdlRunXMLShell :: CmdlState -> IO CmdlState

Runs a shell in which the communication is expected to be through XML packets

processInput :: HetcatsOpts -> [FilePath] -> CmdlState -> IO CmdlState

Processes a list of input files

processCmds :: [CmdlXMLcommands] -> CmdlState -> CmdlPgipState -> IO (CmdlState, CmdlPgipState)

Executes given commands and returns output message and the new state