On Fri, Aug 13, 2010 at 12:06 PM, Valeriu Caraulean <[email protected]> wrote:
> cliff, thanks for suggestion.
> But that is how I designed my domain: property is initialized trough
> constructor and it's read-only for the rest of the world. I want to enforce
> this rule.
> protected First() { }
> public First(Second second)
> {
> // ...
> }
> public virtual Second Second { get; private set; }
>

I understand, but you should at least make the setter internal, so
that your domain model can use it with the pattern i've suggested
before.  It really is, IMHO, the proper way to do things

-- 
thanks

cliff

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" 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/nhusers?hl=en.

Reply via email to