RelationalPropertyBuilderExtensions.CanSetColumnName Method

Definition

Overloads

CanSetColumnName(IConventionPropertyBuilder, String, Boolean)

Returns a value indicating whether the given column can be set for the property.

CanSetColumnName(IConventionPropertyBuilder, String, StoreObjectIdentifier, Boolean)

Returns a value indicating whether the given column for a particular table-like store object can be set for the property.

CanSetColumnName(IConventionPropertyBuilder, String, Boolean)

Returns a value indicating whether the given column can be set for the property.

public static bool CanSetColumnName (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder propertyBuilder, string name, bool fromDataAnnotation = false);
public static bool CanSetColumnName (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder propertyBuilder, string? name, bool fromDataAnnotation = false);
static member CanSetColumnName : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder * string * bool -> bool
<Extension()>
Public Function CanSetColumnName (propertyBuilder As IConventionPropertyBuilder, name As String, Optional fromDataAnnotation As Boolean = false) As Boolean

Parameters

propertyBuilder
IConventionPropertyBuilder

The builder for the property being configured.

name
String

The name of the column.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

true if the property can be mapped to the given column.

Remarks

See Modeling entity types and relationships for more information and examples.

Applies to

CanSetColumnName(IConventionPropertyBuilder, String, StoreObjectIdentifier, Boolean)

Returns a value indicating whether the given column for a particular table-like store object can be set for the property.

public static bool CanSetColumnName (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder propertyBuilder, string name, in Microsoft.EntityFrameworkCore.Metadata.StoreObjectIdentifier storeObject, bool fromDataAnnotation = false);
public static bool CanSetColumnName (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder propertyBuilder, string? name, in Microsoft.EntityFrameworkCore.Metadata.StoreObjectIdentifier storeObject, bool fromDataAnnotation = false);
static member CanSetColumnName : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder * string * StoreObjectIdentifier * bool -> bool
<Extension()>
Public Function CanSetColumnName (propertyBuilder As IConventionPropertyBuilder, name As String, ByRef storeObject As StoreObjectIdentifier, Optional fromDataAnnotation As Boolean = false) As Boolean

Parameters

propertyBuilder
IConventionPropertyBuilder

The builder for the property being configured.

name
String

The name of the column.

storeObject
StoreObjectIdentifier

The identifier of the store object.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

true if the property can be mapped to the given column.

Remarks

See Modeling entity types and relationships for more information and examples.

Applies to