class VisualSupervisor(Supervisor): def birth(self, parent): Supervisor.birth(self, parent) self.gui = SupervisorGUI(self) def child_died(self, child): self.gui.child_died(child) def child_migrated(self, child, to): self.gui.child_migrated(child, to) def child_errored(self, child, error): self.gui.child_errored(child, error) def forceerror(self): None.foo() def arrived(self): Supervisor.arrived(self) self.gui.imigrated(here()) self.gui.migrate_to(here())
def birth(self, parent): Supervisor.birth(self, parent) self.gui = SupervisorGUI(self)