RelationalPropertyBuilderExtensions RelationalPropertyBuilderExtensions Class

Relational database specific extension methods for PropertyBuilder.

Syntax

Declaration

public static class RelationalPropertyBuilderExtensionsPublic Module RelationalPropertyBuilderExtensions

Inheritance Hierarchy

  • System.Object
    System.Object
  • RelationalPropertyBuilderExtensions
    RelationalPropertyBuilderExtensions

Inherited Members

ToString(),
ToString(),
Equals(Object),
Equals(Object),
Equals(Object, Object),
Equals(Object, Object),
ReferenceEquals(Object, Object),
ReferenceEquals(Object, Object),
GetHashCode(),
GetHashCode(),
GetType(),
GetType(),
MemberwiseClone()
MemberwiseClone()

Methods summary

Configures the column that the property maps to when targeting a relational database.

Configures the column that the property maps to when targeting a relational database.

Configures the data type of the column that the property maps to when targeting a relational database. This should be the complete type name, including precision, scale, length, etc.

Configures the data type of the column that the property maps to when targeting a relational database. This should be the complete type name, including precision, scale, length, etc.

Configures the property to map to a computed column when targeting a relational database.

Configures the property to map to a computed column when targeting a relational database.

Configures the default value for the column that the property maps to when targeting a relational database.

Configures the default value for the column that the property maps to when targeting a relational database.

Configures the default value expression for the column that the property maps to when targeting a relational database.

Configures the default value expression for the column that the property maps to when targeting a relational database.

Methods

  • HasColumnName(PropertyBuilder, String)
    HasColumnName(PropertyBuilder, String)

    Configures the column that the property maps to when targeting a relational database.

    public static PropertyBuilder HasColumnName(this PropertyBuilder propertyBuilder, string name)<ExtensionAttribute>
    Public Shared Function HasColumnName(propertyBuilder As PropertyBuilder, name As String) As PropertyBuilder

    Parameters

    • propertyBuilder

      The builder for the property being configured.

    • name
      System.String
      System.String

      The name of the column.

    Returns

  • HasColumnName<TProperty>(PropertyBuilder<TProperty>, String)
    HasColumnName(Of TProperty)(PropertyBuilder(Of TProperty), String)

    Configures the column that the property maps to when targeting a relational database.

    public static PropertyBuilder<TProperty> HasColumnName<TProperty>(this PropertyBuilder<TProperty> propertyBuilder, string name)<ExtensionAttribute>
    Public Shared Function HasColumnName(Of TProperty)(propertyBuilder As PropertyBuilder(Of TProperty), name As String) As PropertyBuilder(Of TProperty)

    Parameters

    Returns

  • HasColumnType(PropertyBuilder, String)
    HasColumnType(PropertyBuilder, String)

    Configures the data type of the column that the property maps to when targeting a relational database. This should be the complete type name, including precision, scale, length, etc.

    public static PropertyBuilder HasColumnType(this PropertyBuilder propertyBuilder, string typeName)<ExtensionAttribute>
    Public Shared Function HasColumnType(propertyBuilder As PropertyBuilder, typeName As String) As PropertyBuilder

    Parameters

    • propertyBuilder

      The builder for the property being configured.

    • typeName
      System.String
      System.String

      The name of the data type of the column.

    Returns

  • HasColumnType<TProperty>(PropertyBuilder<TProperty>, String)
    HasColumnType(Of TProperty)(PropertyBuilder(Of TProperty), String)

    Configures the data type of the column that the property maps to when targeting a relational database. This should be the complete type name, including precision, scale, length, etc.

    public static PropertyBuilder<TProperty> HasColumnType<TProperty>(this PropertyBuilder<TProperty> propertyBuilder, string typeName)<ExtensionAttribute>
    Public Shared Function HasColumnType(Of TProperty)(propertyBuilder As PropertyBuilder(Of TProperty), typeName As String) As PropertyBuilder(Of TProperty)

    Parameters

    Returns

  • HasComputedColumnSql(PropertyBuilder, String)
    HasComputedColumnSql(PropertyBuilder, String)

    Configures the property to map to a computed column when targeting a relational database.

    public static PropertyBuilder HasComputedColumnSql(this PropertyBuilder propertyBuilder, string sql)<ExtensionAttribute>
    Public Shared Function HasComputedColumnSql(propertyBuilder As PropertyBuilder, sql As String) As PropertyBuilder

    Parameters

    • propertyBuilder

      The builder for the property being configured.

    • sql
      System.String
      System.String

      The SQL expression that computes values for the column.

    Returns

  • HasComputedColumnSql<TProperty>(PropertyBuilder<TProperty>, String)
    HasComputedColumnSql(Of TProperty)(PropertyBuilder(Of TProperty), String)

    Configures the property to map to a computed column when targeting a relational database.

    public static PropertyBuilder<TProperty> HasComputedColumnSql<TProperty>(this PropertyBuilder<TProperty> propertyBuilder, string sql)<ExtensionAttribute>
    Public Shared Function HasComputedColumnSql(Of TProperty)(propertyBuilder As PropertyBuilder(Of TProperty), sql As String) As PropertyBuilder(Of TProperty)

    Parameters

    Returns

  • HasDefaultValue(PropertyBuilder, Object)
    HasDefaultValue(PropertyBuilder, Object)

    Configures the default value for the column that the property maps to when targeting a relational database.

    public static PropertyBuilder HasDefaultValue(this PropertyBuilder propertyBuilder, object value)<ExtensionAttribute>
    Public Shared Function HasDefaultValue(propertyBuilder As PropertyBuilder, value As Object) As PropertyBuilder

    Parameters

    • propertyBuilder

      The builder for the property being configured.

    • value
      System.Object
      System.Object

      The default value of the column.

    Returns

  • HasDefaultValue<TProperty>(PropertyBuilder<TProperty>, Object)
    HasDefaultValue(Of TProperty)(PropertyBuilder(Of TProperty), Object)

    Configures the default value for the column that the property maps to when targeting a relational database.

    public static PropertyBuilder<TProperty> HasDefaultValue<TProperty>(this PropertyBuilder<TProperty> propertyBuilder, object value)<ExtensionAttribute>
    Public Shared Function HasDefaultValue(Of TProperty)(propertyBuilder As PropertyBuilder(Of TProperty), value As Object) As PropertyBuilder(Of TProperty)

    Parameters

    Returns

  • HasDefaultValueSql(PropertyBuilder, String)
    HasDefaultValueSql(PropertyBuilder, String)

    Configures the default value expression for the column that the property maps to when targeting a relational database.

    public static PropertyBuilder HasDefaultValueSql(this PropertyBuilder propertyBuilder, string sql)<ExtensionAttribute>
    Public Shared Function HasDefaultValueSql(propertyBuilder As PropertyBuilder, sql As String) As PropertyBuilder

    Parameters

    • propertyBuilder

      The builder for the property being configured.

    • sql
      System.String
      System.String

      The SQL expression for the default value of the column.

    Returns

  • HasDefaultValueSql<TProperty>(PropertyBuilder<TProperty>, String)
    HasDefaultValueSql(Of TProperty)(PropertyBuilder(Of TProperty), String)

    Configures the default value expression for the column that the property maps to when targeting a relational database.

    public static PropertyBuilder<TProperty> HasDefaultValueSql<TProperty>(this PropertyBuilder<TProperty> propertyBuilder, string sql)<ExtensionAttribute>
    Public Shared Function HasDefaultValueSql(Of TProperty)(propertyBuilder As PropertyBuilder(Of TProperty), sql As String) As PropertyBuilder(Of TProperty)

    Parameters

    Returns

Details

Assembly

Microsoft.EntityFrameworkCore.Relational.dll