次の方法で共有


IConventionEntityTypeBuilder.CreateUniqueProperty メソッド

定義

既存のプロパティとは異なる名前のプロパティを作成します。

public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder CreateUniqueProperty (Type propertyType, string basePropertyName, bool required);
public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder? CreateUniqueProperty (Type propertyType, string basePropertyName, bool required);
abstract member CreateUniqueProperty : Type * string * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder
Public Function CreateUniqueProperty (propertyType As Type, basePropertyName As String, required As Boolean) As IConventionPropertyBuilder

パラメーター

propertyType
Type

プロパティが保持する値の型。

basePropertyName
String

目的のプロパティ名。

required
Boolean

プロパティが必要かどうかを示す値。

戻り値

エンティティ型 null に存在する場合は、プロパティを構成するために使用できるオブジェクト。それ以外の場合は 。

適用対象