why Silverlight 4 uses WCF RIA service for Entity Framework?
I want to u开发者_Python百科se Entity framework in silverlight , But with out RIA service .
Is there any way ?
If WCF RIA is mandatory than why so ?
Silverlight is a client side runtime (Code is not executed on the server). And therefore you cannot use Entity Framework to call a DB directly from it. RIA Services essentially create a web service layer that Silverlight can talk to. On the client side proxy classes are created to interact with the service layer. RIA Data Services is designed to make it appear as if you are interrogating EF directly.
To use EF without RIA services you can create a basic service class and have all your business logic in it, and from within this service you can use Entity Framework. You would make calls to this service layer just like any other service.
精彩评论