-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | type safe rpcs provided as basic IO actions -- -- Given an address of a server sharing a set of functions, this rpc -- library generates functions of the same name for a client, preformed -- within the IO monad. Calling these results in the original function -- being executed server side. The pseudo-functions generated maintain -- their original server side type (except for the added IO). @package rpc @version 0.0.0 module Network.RPC.Types data Req GetTypes :: Req CallFunc :: String -> Req data FuncSpec FuncSpec :: String -> TypeSpec -> FuncSpec data TypeSpec SForallT :: [TyVarBndrSpec] -> [PredSpec] -> TypeSpec -> TypeSpec SVarT :: String -> TypeSpec SConT :: String -> TypeSpec STupleT :: Int -> TypeSpec SArrowT :: TypeSpec SListT :: TypeSpec SAppT :: TypeSpec -> TypeSpec -> TypeSpec data Bin Bin :: a -> Bin typeToSpec :: Type -> TypeSpec specToType :: TypeSpec -> Type instance Lift PredSpec instance Lift Kind instance Lift TyVarBndrSpec instance Lift TypeSpec instance Lift Address instance Serialize PredSpec instance Serialize Kind instance Serialize TyVarBndrSpec instance Serialize TypeSpec instance Serialize FuncSpec instance Serialize Req instance Show PredSpec instance Show TyVarBndrSpec instance Show TypeSpec instance Show FuncSpec module Data.Serialize.Send -- | Serializes an object to the given handle hSerialize :: (Serialize a) => Handle -> a -> IO () -- | Deserializes an object to the given handle hDeserialize :: (Serialize a) => Handle -> IO a module Network.RPC.Client -- | Splices in rpc calls to a given IP. Function names and types will -- remain the same as on the server side, with the result encapsulated in -- the IO monad. Usage: -- --
-- $(fetch (IP "127.0.0.1" 9000)) --fetch :: Address -> Q [Dec] data Address :: * -- | Host name and port, either IPv4 or IPv6. IP :: HostName -> Int -> Address -- | Host name and port, only IPv4. IPv4 :: HostName -> Int -> Address -- | Host name and port, only IPv6 IPv6 :: HostName -> Int -> Address -- | Local unix socket, not supported on Windows. Unix :: FilePath -> Address module Network.RPC.Server -- | Template haskell magic to share a set of functions on a given port to -- be spliced into a main declaration. This function never returns. For -- example: -- --
-- main = $(share 9000 [ 'fn1, 'fn2, 'fn3 ]) --share :: Int -> [Name] -> Q Exp