Over the last few updates to Visual Studio 2017, we’ve been hard at work adding new features to boost your productivity while you’re writing code. Many of these are the result of your direct feedback coming from the UserVoice requests, Developer Community tickets, and direct feedback we’ve encountered while talking to developers like you.
یک همچین کدهایی هم باعث ایجاد دوباره پلن مربوط به کوئری خواهند شد:
معادل بهینه شده کد بالا:
در پروژه Decision خیلی از این نوع موارد پیاده سازی شده است که میبایست اصلاح شوند. برای مثال متد های GetPagedListAsync.
using (var context = new MyContext()) { var myObject = new NonMappedType(); var query = from entity in context.MyEntities where entity.Name.StartsWith(myObject.MyProperty) select entity; var results = query.ToList(); ... }
using (var context = new MyContext()) { var myObject = new NonMappedType(); var myValue = myObject.MyProperty; var query = from entity in context.MyEntities where entity.Name.StartsWith(myValue) select entity; var results = query.ToList(); ... }
اشتراکها
لیستی از افزونههای مفید VSCode
اشتراکها
چند نکته در ویژوال استدیو
اشتراکها