It is possible to achieve that using the .MapType() method. Whenever you use the MapType method without specifying a lambda expression this would instruct our metadata reader that all properties in that types will be default mapped if no explicit mapping is specified.
If you however use a method like this:
ProductId = p.Id,
ProductName = p.Name,
Discontinued = p.Discontinued,
CategoryId = p.CategoryId
Only the Id,Name,Discontinued and CategoryId properties will receive default mapping unless other is not specified. All properties that are not mentioned in this lambda expression and do not have an explicit mapping provided with the HasProperty method will be regarded as transient.
The last possibility is to use this method with an empty lambda like this:
This would mean that no properties will receive default mapping and all will be considered to be transient unless explicit mapping is provided via the HasPropertyMethod.
I hope this was helpful to you.
All the best,
the Telerik team
Follow @OpenAccessORM Twitter channel to get first the latest updates on new releases, tips and tricks and sneak peeks at our product labs!