阅读背景:

实体框架:WPF中的上下文与ASP.Net ...如何处理

来源:互联网 

Currently for ASP.Net stuff I use a request model where a context is created per request (Only when needed) and is disposed of at the end of that request. I've found this to be a good balance between not having to do the old Using per query model and not having a context around forever. Now the problem is that in WPF, I don't know of anything that could be used like the request model. Right now it looks like its to keep the same context forever (Which can be a nightmare) or go back to the annoying Using per query model that is a huge pain. I haven't seen a good answer on this yet. Currently for ASP.Net stuff I use a request mod




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: