pactorsPython actors library | |
Download |
pactors Ranking & Summary
Advertisement
pactors Tags
pactors Description
pactors is a Python actors library.Usagefrom pactors.core import Actorclass MyActor(Actor): def __init__(self, name): self.name = name super(MyActor, self).__init__() def receive(self, message): print "%s received: %s" % (self.name, message) self.kill()a1 = MyActor("actor1")a1.start()a2 = MyActor("actor2")a2.start()a1.send(a2, {"sender": a1, "msg": "hi)"})a2.send(a1, "hello")Actor.wait_actors()Product's homepage
pactors Related Software