Class | Rinda::TupleSpaceProxy |
In: |
lib/rinda/rinda.rb
|
Parent: | Object |
TupleSpaceProxy allows a remote Tuplespace to appear as local.
Creates a new TupleSpaceProxy to wrap ts.
# File lib/rinda/rinda.rb, line 213 213: def initialize(ts) 214: @ts = ts 215: end
Registers for notifications of event ev on the proxied TupleSpace. See TupleSpace#notify
# File lib/rinda/rinda.rb, line 252 252: def notify(ev, tuple, sec=nil) 253: @ts.notify(ev, tuple, sec) 254: end
Reads tuple from the proxied TupleSpace. See TupleSpace#read.
# File lib/rinda/rinda.rb, line 236 236: def read(tuple, sec=nil, &block) 237: @ts.read(tuple, sec, &block) 238: end
Reads all tuples matching tuple from the proxied TupleSpace. See TupleSpace#read_all.
# File lib/rinda/rinda.rb, line 244 244: def read_all(tuple) 245: @ts.read_all(tuple) 246: end
Takes tuple from the proxied TupleSpace. See TupleSpace#take.
# File lib/rinda/rinda.rb, line 227 227: def take(tuple, sec=nil, &block) 228: port = [] 229: @ts.move(DRbObject.new(port), tuple, sec, &block) 230: port[0] 231: end
Adds tuple to the proxied TupleSpace. See TupleSpace#write.
# File lib/rinda/rinda.rb, line 220 220: def write(tuple, sec=nil) 221: @ts.write(tuple, sec) 222: end