-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | a remote procedure call framework -- -- A library and framework for making remote procedure calls in haskell -- easy and typesafe. See -- http:github.commmirmanhaskogeneous for more information. @package rpc-framework @version 0.0.0.0 module Network.Remote.RPC.Internal.MultiServer data ServiceID LocNumber :: Integer -> ServiceID LocName :: String -> ServiceID type Handlers = Map ServiceID (Handle -> AIO ()) type State = MVar (Handlers, Integer) newtype AIO a AIO :: (ReaderT State IO a) -> AIO a send :: (Show a, MonadIO m) => Handle -> a -> m () recv :: (Read a, MonadIO m) => Handle -> m a startServer :: Integer -> AIO a -> IO a safeFind :: (Ord k, Show k) => Map k a -> k -> a unsafePerformServer :: State -> AIO a -> a getHandlers :: AIO State addService :: (Handle -> AIO ()) -> AIO ServiceID addServiceByName :: String -> (Handle -> AIO ()) -> AIO ServiceID connectToService :: MonadIO m => String -> Integer -> ServiceID -> m Handle instance [incoherent] Show ServiceID instance [incoherent] Read ServiceID instance [incoherent] Ord ServiceID instance [incoherent] Eq ServiceID instance [incoherent] Monad AIO instance [incoherent] Functor AIO instance [incoherent] MonadIO AIO instance [incoherent] MonadReader State AIO module Network.Remote.RPC.Internal.Runtime data WIO w a world :: Host w => WIO w w realRemoteCall :: (Host w, RPC a w) => a -> String -> Initialize a w remoteCall :: RPC a w => a -> Initialize a w makeService :: Service a w => a -> String -> WIO w () class Host a getLocation :: Host a => a -> String getPort :: Host a => a -> Integer getValue :: Host a => a class Sendable a data Ref a -- | Lift a computation from the IO monad. liftIO :: MonadIO m => forall a. IO a -> m a -- | runServer runs a name server and doesn't return runServer :: Host w => WIO w () -> IO () -- | runServerBG runs a name server on a background thread and does -- return runServerBG :: Host w => WIO w () -> IO ThreadId instance [incoherent] MonadIO (WIO w) instance [incoherent] Functor (WIO w) instance [incoherent] Monad (WIO w) instance [incoherent] Show (Ref a) instance [incoherent] Read (Ref a) instance [incoherent] (Sendable a, Service b w) => Service (a -> b) w instance [incoherent] (Host w, Sendable a) => Service (WIO w a) w instance [incoherent] (Sendable a, RPC b w') => RPC (a -> b) w' instance [incoherent] (Sendable a, Host w, Host w') => RPC (WIO w a) w' instance [incoherent] (Sendable a, Sendable b) => Sendable (a -> b) instance [incoherent] (Read a, Show a) => Sendable a module Network.Remote.RPC.Internal.Templates build :: Q [Dec] -> Q [Dec] rpcCall :: Name -> Q Exp makeHost :: String -> String -> Integer -> Q [Dec] makeServices :: [Name] -> Q Exp autoService :: Name -> Q Exp instance [incoherent] MonadIO Q module Network.Remote.RPC