Guest User

Untitled

a guest
Oct 15th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.74 KB | None | 0 0
  1. diff --git a/SkyNET/Exo.py b/SkyNET/Exo.py
  2. index 8bef615..9002324 100644
  3. --- a/SkyNET/Exo.py
  4. +++ b/SkyNET/Exo.py
  5. @@ -28,6 +28,14 @@ class ExoParticipant(Participant):
  6. def __init__(self, exo=None, *args, **kwargs):
  7. super(ExoParticipant,self).__init__(*args, **kwargs)
  8. self.exo=exo
  9. + if "handle_reply_to_engine" in dir(self.exo.handler):
  10. + def func(wi): self.handle_reply_to_engine(wi)
  11. + self.exo.reply_to_engine = func
  12. +
  13. + def handle_reply_to_engine(wi):
  14. + self.workitem = wi
  15. + super(ExoParticipant,self).reply_to_engine()
  16.  
  17. def consume(self):
  18. self.exo.handler.handle_wi(self.workitem)
Add Comment
Please, Sign In to add comment