class AbnormalExit(exceptions.Exception):
An actor will raise this exception if it terminated by means of an uncaught exception.
class AbstractActor(__builtin__.object):
QueueClass = <class parley.actor.AbstractQueue>
def _handle_signal(self, signal):
If this function is called, we know that a signal is waiting. Depending on the value of self.trap_exceptions, we either raise the signal as an exception or return it as a message.def _next_message(self, msg_filter, wait):
def go(self):
Spawn self.run in a new frame of execution. This function is called by the controller when the created actor is to be spawned.def recv(self, msg_filter=None, wait=True):
def register_id(self):
Register self.id such that it can be retrieved by controller._get_current_actor_id() (e.g. by storing it in threadlocals).def run(self):
Hand off control to self.target. This function will be spawned in a new frame of execution.
class AbstractQueue:
Controllers should define a queue implementation having this interface.def get(self):
def get_nowait(self):
def put(self, o):