-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: EntitySet & EntityRef
PostPosted: Fri Sep 23, 2005 2:51 pm 
I want to make use of the new features in .Net 2 to allow something like:

Code:
public Blog(){
    posts = new EntitySet<Post>(delegate(Post p) { p.Blog = this; }, delegate(Post p) { p.Blog = null; }})
}

Assume that EntitySet is a collection that inherit from PersistantCollection.

The prolem is that when loading from a database, I get the default implementation, which obviously is not good enough since it doesn't have the proper add/remove methods.
How do I make NHib understand that I added a new collection and
How do I make NHib use the instance that I created in the class ctor?


Top
  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.