Is this a NHibernate bug or by design? -


i have following in mapping code file contact entity, lazy default:

        this.bag<int>(             "prioritycodes",             map =>             {                 map.access(accessor.field);                 map.table("prioritycodes");                 map.key(k => k.column("contactid"));                 map.cascade(cascade.all);             },             r => r.element(m => m.column("prioritycode"))); 

the code in entity class is:

    private readonly ilist<int> prioritycodes= new list<int>(); 

when contact list obtained repository, notice contactproxy has interceptor field contains targetinstance. contactproxy inherits contact class, , base class contains private prioritycodes field.

the thing don't understand targetinstance private prioritycodes field empty, whereas base class prioritycodes field populated?

i have expected targetinstance contain populated private field, calls delegated targetinstance.

please explain if bug or, if not, reasoning behind this.


Comments

Popular posts from this blog

codeigniter - Fatal error: Call to undefined function lang() in CI Merchant using CardSave -

python - Received unregistered task using Celery with Django -

c# - Delving into the world of XML (Windows Phone) Error I dont understand (The ' ' character, hexadecimal value 0x20, cannot be included in a name.) -