[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

DRb: nested remote objects?

Xavier Noria

11/4/2006 6:31:00 PM

I have followed a couple of intros and played around without luck. Given

account = DRbObject.new(nil, 'druby://localhost:9000')

can I get into nested attributes and have them as remote objects?

puts account.company.address.city

Or in DRb you design a "procedural" API with all you need around a
single remote object so to speak?

-- fxn


1 Answer

Xavier Noria

11/4/2006 6:46:00 PM

0

On Nov 4, 2006, at 7:31 PM, Xavier Noria wrote:

> I have followed a couple of intros and played around without luck.
> Given
>
> account = DRbObject.new(nil, 'druby://localhost:9000')
>
> can I get into nested attributes and have them as remote objects?
>
> puts account.company.address.city

Nevermind, I opened drb/drb.rb and saw the comments there. For the
archives, the classes Company and Address suggested in the example
above have to include the DRb::DRbUndumped mixin module.

-- fxn