Projection to custom class

Posts   
 
    
RP
User
Posts: 6
Joined: 01-Nov-2006
# Posted on: 06-Nov-2006 19:04:43   

I would like to project a collection with its related entity onto a custom class. Is it possible?

Thanks.

Jessynoo avatar
Jessynoo
Support Team
Posts: 296
Joined: 19-Aug-2004
# Posted on: 07-Nov-2006 01:58:38   

Hi,

the general procedure for handling projection is exposed in the manual in the section "Generated code - Fetching DataReaders and projections"

you can use the EntityView(2).createProjection to perform in memory projection, and for the related entities properties, I guess you can provide your own implementation of IEntityPropertyProjector (whereas EntityPropertyProjector only deals with EntityField properties)

Cheers