Are you saying that this is a way to force a pass by reference?
I can also do that with DRbUndumped.
Are these blocks of code equivalent in what they accomplish?
On 8/15/05, Eric Hodel <email@example.com> wrote:
On 14 Aug 2005, at 12:40, Mark Volkmann wrote:
> The source file lib\ruby\1.8\drb\drb.rb defines the class DRbObject. I
> don't understand the initialize method. Why would I ever want to pass
> something other than nil for the first parameter? The comment above
> the initialize method says that is used to create a proxy/stub for a
> local object. Why would I want to do that?
> The typical way to use this is
> proxy = DRbObject.new(nil, url)
You can pass DRbObjects across the wire, so you could wrap a local
object and pass the DRbObject across the wire to the other side. If
you look around in drb.rb you'll see several places where it is used.
R. Mark Volkmann
Partner, Object Computing, Inc.