The GW provides a synchronized store for participants in the gateway to communicate.
Class Methods
.
3.3
View on GitHub
# File tmp/rubies/ruby-3.3.0/lib/drb/gw.rb, line 51
def initialize
super()
@hash = {}
end
Creates a new GW
Instance Methods
#
3.3
View on GitHub
# File tmp/rubies/ruby-3.3.0/lib/drb/gw.rb, line 58
def [](key)
synchronize do
@hash[key]
end
end
Retrieves key from the GW
3.3
View on GitHub
# File tmp/rubies/ruby-3.3.0/lib/drb/gw.rb, line 66
def []=(key, v)
synchronize do
@hash[key] = v
end
end
Stores value v at key in the GW