DbModelBuilder.Ignore Method
Assembly: EntityFramework (in EntityFramework.dll)
Name | Description | |
---|---|---|
![]() | Ignore(IEnumerable<Type>) | Excludes the specified type(s) from the model. This is used to remove types from the model that were added by convention during initial model discovery. |
![]() | Ignore<T>() | Excludes a type from the model. This is used to remove types from the model that were added by convention during initial model discovery. |
DbModelBuilder.Ignore Method (IEnumerable<Type>)
Excludes the specified type(s) from the model. This is used to remove types from the model that were added by convention during initial model discovery.
Parameters
- types
-
Type:
System.Collections.Generic.IEnumerable<Type>
The types to be excluded from the model.
Return Value
Type: System.Data.Entity.DbModelBuilderThe same DbModelBuilder instance so that multiple calls can be chained.
DbModelBuilder.Ignore<T> Method ()
Excludes a type from the model. This is used to remove types from the model that were added by convention during initial model discovery.
[SuppressMessageAttribute("Microsoft.Design", "CA1004:GenericMethodsShouldProvideTypeParameter")] public virtual DbModelBuilder Ignore<T>() where T : class
Return Value
Type: System.Data.Entity.DbModelBuilderThe same DbModelBuilder instance so that multiple calls can be chained.
Type Parameters
- T
The type to be excluded.