AdapterExtendedEntity with LLBL 1.0.2005.1

Posts   
 
    
omar avatar
omar
User
Posts: 569
Joined: 15-Oct-2004
# Posted on: 12-Nov-2005 16:24:01   

After upgrading to LLBL2005 I am having a strange problem with my BL classes that use AdapterExtendedEntity code. Example: SECUserEntity relates (Many-to-Many) to SECGroupEntity <-- DAL class SECUser relates (Many-to-Many) to SECGroup <-- BL class uses adapter extended entity

The SECUser has a shadowed property ([SECGroupCollectionViaSECUserGroup]). If I fetch a SECUser object using code like this

Dim prefetch As IPrefetchPath2 = New PrefetchPath2(EntityType.SECUserEntity)
        prefetch.Add(SECUser.PrefetchPathSECUserGroupCollection)
        prefetch.Add(SECUser.PrefetchPathSECGroupCollectionViaSECUserGroup)

        Dim dbUser As SECUser = SECUser.Fetch(userName, prefetch)

After installing the new LLBL, at run-time the [SECGroupCollectionViaSECUserGroup] of SECUser containes objects of type SECUserEntity instead of objects of type SECUser. With the old LLBL the same collection property conatined objects of type SECUser (not SECUserEntity).

I made sure that I am using the new AdapterExtendedEntity templates (not the old ones) so I don't know whats wrong??? confused

omar avatar
omar
User
Posts: 569
Joined: 15-Oct-2004
# Posted on: 12-Nov-2005 17:34:09   

Ok.. don't bother.. I got it... forgot to fix the code in the factory so that it would create SECUser instead of creating SECUserEntity... simple_smile