Quantcast
Channel: Entity Framework
Viewing all articles
Browse latest Browse all 10318

Created Feature: Consider adding Ignore method directly on lightweight property configurations [1347]

$
0
0
This is based on customer feedback located [here](http://blogs.msdn.com/b/adonet/archive/2013/05/30/ef6-beta-1-available.aspx?wa=wsignin1.0#10430343).

The idea is to enable doing something like this:
```
modelBuilder.Properties()
.Where(p => p.GetCustomAttribute<ColumnAttribute>() == null))
.Configure(p => p.Ignore());
```

Instead of having to do something like this:

```
modelBuilder
.Entities()
.Configure(conf => conf
.ClrType
.GetProperties()
.Where(p => p.GetCustomAttribute<ColumnAttribute>() == null)
.ToList()
.ForEach(p => conf.Ignore(p)));
```

Viewing all articles
Browse latest Browse all 10318

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>