diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2012-06-02 22:26:58 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2012-06-02 22:26:58 +0200 |
commit | 4df07172fef440f24945149b2490c0c60e72e72e (patch) | |
tree | c082fc5d5319ed5ab77b5b3df4cbaeb7256eb3b4 /lib/iotas/room.rb | |
parent | 50b9b41e1e8b3012c165ea6a4c383273afe37ac3 (diff) | |
download | edoors-ruby-4df07172fef440f24945149b2490c0c60e72e72e.zip edoors-ruby-4df07172fef440f24945149b2490c0c60e72e72e.tar.gz |
set direct routing through action parameter to Door#send_p and Door#send_sys_p
Diffstat (limited to 'lib/iotas/room.rb')
-rw-r--r-- | lib/iotas/room.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/iotas/room.rb b/lib/iotas/room.rb index f3d0cfa..b32168c 100644 --- a/lib/iotas/room.rb +++ b/lib/iotas/room.rb @@ -134,6 +134,10 @@ module Iotas # def send_p p puts " * send_p #{(p.next_dst.nil? ? 'no dst' : p.next_dst)} ..." if @spin.debug_routing + if p.dst + puts " -> #{p.dst.path}#{Iotas::ACT_SEP}#{p.action}" if @spin.debug_routing + return @spin.post_p p + end if p.src.nil? # do not route orphan particles !! p.error! Iotas::ERROR_ROUTE_NS, @spin @@ -156,6 +160,10 @@ module Iotas # def send_sys_p p puts " * send_sys_p #{(p.next_dst.nil? ? 'no dst' : p.next_dst)} ..." if @spin.debug_routing + if p.dst + puts " -> #{p.dst.path}#{Iotas::ACT_SEP}#{p.action}" if @spin.debug_routing + return @spin.post_sys_p p + end if p.next_dst p.split_dst! if p.door |