WCF RIA Services: how can I explicitly set which entities should be generated to the client?
I created a Silverlig开发者_运维百科ht WCF RIA enabled application and added a model and a LinqToEntitiesDomainService to the web project.
I want to expose all (or some) of the entities in my model, even tho there is no Select queries available for it in my model.
Is there such a way?
RIA generates entities based on the following rules. Entities are visible if:
- They are returned from a query operation (in an IQueryable, IEnumerable, or singular)
- They can be reached from an entity returned from a query through properties marked with the [Include] attribute
Entities in that latter category may not get EntitySets generated for them in the DomainContext, but should still be generated on the client.
精彩评论