EntityTypeConfiguration<TEntityType>.Ignore<TProperty> Method (Expression<Func<TEntityType, TProperty>>)
Excludes a property from the model so that it will not be mapped to the database.
Assembly: EntityFramework (in EntityFramework.dll)
[SuppressMessageAttribute("Microsoft.Design", "CA1011:ConsiderPassingBaseTypesAsParameters")] [SuppressMessageAttribute("Microsoft.Design", "CA1006:DoNotNestGenericTypesInMemberSignatures")] public EntityTypeConfiguration<TEntityType> Ignore<TProperty>( Expression<Func<TEntityType, TProperty>> propertyExpression )
Parameters
- propertyExpression
-
Type:
System.Linq.Expressions.Expression<Func<TEntityType, TProperty>>
A lambda expression representing the property to be configured. C#: t => t.MyProperty VB.Net: Function(t) t.MyProperty
Return Value
Type: System.Data.Entity.ModelConfiguration.EntityTypeConfiguration<TEntityType>The same EntityTypeConfiguration instance so that multiple calls can be chained.
Type Parameters
- TProperty
The type of the property to be ignored.