I have not been able to find much documentation on this subject.

I have a property Customer.Address:

[BelongsTo("AddressID", Lazy = FetchWhen.OnInvoke)]
public Address { get; set; }


This doesn't work.  The only way to make this work is described here:
http://stackoverflow.com/questions/2282967/lazy-loading-belongsto-relation-with-castle-active-record

1. make Customer class, all the methods and properties virtual and
then add:
2. Update class with [ActiveRecord(Lazy=true)]


Is there another way to do this without making everything virtual
(since many properties shouldn't be virtual from requirements
perspective).  I can see how adding virtual would work for simple
properties like strings, int through the Proxy described here:
http://www.castleproject.org/activerecord/documentation/v1rc1/usersguide/lazy.html

But for sub-classes like Address, shouldn't it work the same way as
for HasMany relationships?

Eric



-- 
You received this message because you are subscribed to the Google Groups 
"Castle Project Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/castle-project-users?hl=en.

Reply via email to