MutableModelExtensions.SetPropertyAccessMode Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
SetPropertyAccessMode(IMutableModel, Nullable<PropertyAccessMode>) |
Sets the PropertyAccessMode to use for properties of all entity types in this model. Note that individual entity types can override this access mode, and individual properties of entity types can override the access mode set on the entity type. The value set here will be used for any property for which no override has been specified. |
SetPropertyAccessMode(IMutableModel, Nullable<PropertyAccessMode>) |
Sets the PropertyAccessMode to use for properties of all entity types in this model. Note that individual entity types can override this access mode, and individual properties of entity types can override the access mode set on the entity type. The value set here will be used for any property for which no override has been specified. |
SetPropertyAccessMode(IMutableModel, Nullable<PropertyAccessMode>)
Sets the PropertyAccessMode to use for properties of all entity types in this model.
Note that individual entity types can override this access mode, and individual properties of entity types can override the access mode set on the entity type. The value set here will be used for any property for which no override has been specified.
public static void SetPropertyAccessMode (this Microsoft.EntityFrameworkCore.Metadata.IMutableModel model, Microsoft.EntityFrameworkCore.Metadata.PropertyAccessMode? propertyAccessMode);
static member SetPropertyAccessMode : Microsoft.EntityFrameworkCore.Metadata.IMutableModel * Nullable<Microsoft.EntityFrameworkCore.Metadata.PropertyAccessMode> -> unit
<Extension()>
Public Sub SetPropertyAccessMode (model As IMutableModel, propertyAccessMode As Nullable(Of PropertyAccessMode))
Parameters
- model
- IMutableModel
The model to set the access mode for.
- propertyAccessMode
- Nullable<PropertyAccessMode>
The PropertyAccessMode, or null to clear the mode set.
Applies to
SetPropertyAccessMode(IMutableModel, Nullable<PropertyAccessMode>)
Sets the PropertyAccessMode to use for properties of all entity types in this model.
Note that individual entity types can override this access mode, and individual properties of entity types can override the access mode set on the entity type. The value set here will be used for any property for which no override has been specified.
public static void SetPropertyAccessMode (this Microsoft.EntityFrameworkCore.Metadata.IMutableModel model, Microsoft.EntityFrameworkCore.PropertyAccessMode? propertyAccessMode);
static member SetPropertyAccessMode : Microsoft.EntityFrameworkCore.Metadata.IMutableModel * Nullable<Microsoft.EntityFrameworkCore.PropertyAccessMode> -> unit
<Extension()>
Public Sub SetPropertyAccessMode (model As IMutableModel, propertyAccessMode As Nullable(Of PropertyAccessMode))
Parameters
- model
- IMutableModel
The model to set the access mode for.
- propertyAccessMode
- Nullable<PropertyAccessMode>
The PropertyAccessMode, or null
to clear the mode set.
Applies to
Entity Framework