-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Minimal akka-inspired actor library
--
-- Minimal akka-inspired actor library
@package hakka
@version 0.2.0
module Hakka.Actor
-- | Serializable handle to an Actor
data ActorRef m
-- | Actions which actors execute in response to a received message run
-- within the ActorIO monad.
data ActorIO m a
-- | Empty actor action
noop :: ActorIO m ()
-- | Lift a computation from the IO monad.
liftIO :: MonadIO m => forall a. IO a -> m a
-- | Create a new child actor in the current context (actor system or
-- actor).
actor :: Show m => String -> (m -> ActorIO m ()) -> ActorIO m (ActorRef m)
-- | Send a message to an actor. Does not block (immediately returns
-- control flow).
tell :: ActorRef m -> m -> ActorRef m -> ActorIO m ()
-- | Like tell but the sender will be the actor which executes the
-- action.
(!) :: ActorRef m -> m -> ActorIO m ()
-- | Like tell but the sender will be the sender of the currently
-- processed message.
forward :: ActorRef m -> m -> ActorIO m ()
-- | Schedule the delivery of a message in the future
schedule :: Int -> Int -> ActorRef m -> m -> ActorIO m Cancellable
-- | Schedule the delivery of a message in the future
scheduleOnce :: Int -> ActorRef m -> m -> ActorIO m Cancellable
-- | Obtain the reference to the sender of the currently processed message
sender :: ActorIO m (ActorRef m)
-- | Obtain the reference to the actor executing the action
self :: ActorIO m (ActorRef m)
-- | Obtain the reference to the parent of self
parent :: ActorIO m (ActorRef m)
-- | Log a message. Log messages will be sequentialized.
log :: Severity -> String -> ActorIO m ()
-- | Log message severity
data Severity
Debug :: Severity
Info :: Severity
Warn :: Severity
Error :: Severity
-- | Switch the behavior of the current actor
become :: (m -> ActorIO m ()) -> ActorIO m ()
-- | Stop this actor
stop :: ActorIO m ()
-- | Create a new actor system
actorSystem :: Show m => String -> ActorIO m a -> IO ActorSystem
-- | An ActorSystem serves as the root of an actor hierarchy
data ActorSystem
-- | Terminate the actor System
terminate :: ActorSystem -> IO ()
data Cancellable
cancel :: Cancellable -> ActorIO m ()
instance GHC.Base.Functor (Hakka.Actor.ActorIO m)
instance GHC.Base.Applicative (Hakka.Actor.ActorIO m)
instance Control.Monad.IO.Class.MonadIO (Hakka.Actor.ActorIO m)
instance GHC.Base.Monad (Hakka.Actor.ActorIO m)
instance GHC.Show.Show Hakka.Actor.Severity
instance GHC.Show.Show m => GHC.Show.Show (Hakka.Actor.Envelope m)
instance GHC.Show.Show m => GHC.Show.Show (Hakka.Actor.Message m)
instance GHC.Show.Show Hakka.Actor.Signal
instance GHC.Classes.Eq (Hakka.Actor.ActorRef m)
instance GHC.Classes.Eq Hakka.Actor.ActorPath
instance GHC.Show.Show Hakka.Actor.ActorPath
instance GHC.Show.Show (Hakka.Actor.ActorRef m)