viff

changeset 1220:5a815629d825

Added method for expecting data on the network using a specified programcounter.
author Janus Dam Nielsen <janus.nielsen@alexandra.dk>
date Tue, 06 Oct 2009 10:05:24 +0200
parents 8a5eb6550111
children 53d198cdf14c
files viff/runtime.py
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line diff
     1.1 --- a/viff/runtime.py	Tue Oct 06 10:04:36 2009 +0200
     1.2 +++ b/viff/runtime.py	Tue Oct 06 10:05:24 2009 +0200
     1.3 @@ -726,6 +726,9 @@
     1.4          # Convert self.program_counter to a hashable value in order to
     1.5          # use it as a key in self.protocols[peer_id].incoming_data.
     1.6          pc = tuple(self.program_counter)
     1.7 +        return self._expect_data_with_pc(pc, peer_id, data_type, deferred)
     1.8 +
     1.9 +    def _expect_data_with_pc(self, pc, peer_id, data_type, deferred):
    1.10          key = (pc, data_type)
    1.11  
    1.12          if key in self.protocols[peer_id].incoming_data: