共用方式為


RelationalEntityTypeExtensions.SetJsonPropertyName 方法

定義

多載

SetJsonPropertyName(IMutableEntityType, String)

設定用於對應至 JSON 資料行之指定實體的 JSON 屬性名稱值。

SetJsonPropertyName(IConventionEntityType, String, Boolean)

設定用於對應至 JSON 資料行之指定實體的 JSON 屬性名稱值。

SetJsonPropertyName(IMutableEntityType, String)

設定用於對應至 JSON 資料行之指定實體的 JSON 屬性名稱值。

public static void SetJsonPropertyName (this Microsoft.EntityFrameworkCore.Metadata.IMutableEntityType entityType, string? name);
static member SetJsonPropertyName : Microsoft.EntityFrameworkCore.Metadata.IMutableEntityType * string -> unit
<Extension()>
Public Sub SetJsonPropertyName (entityType As IMutableEntityType, name As String)

參數

entityType
IMutableEntityType

實體類型。

name
String

要使用的名稱。

適用於

SetJsonPropertyName(IConventionEntityType, String, Boolean)

設定用於對應至 JSON 資料行之指定實體的 JSON 屬性名稱值。

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

參數

entityType
IConventionEntityType

實體類型。

name
String

要使用的名稱。

fromDataAnnotation
Boolean

指出是否已使用資料批註指定組態。

傳回

已設定的值。

適用於