RelationalPropertyExtensions.TryGetDefaultValue 方法

定義

多載

TryGetDefaultValue(IReadOnlyProperty, Object)

傳回物件,這個物件會當做這個屬性所對應之資料行的預設值。

TryGetDefaultValue(IReadOnlyProperty, StoreObjectIdentifier, Object)

傳回物件,這個物件會當做這個屬性所對應之資料行的預設值。

TryGetDefaultValue(IReadOnlyProperty, Object)

傳回物件,這個物件會當做這個屬性所對應之資料行的預設值。

public static bool TryGetDefaultValue (this Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty property, out object? defaultValue);
static member TryGetDefaultValue : Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty * obj -> bool
<Extension()>
Public Function TryGetDefaultValue (property As IReadOnlyProperty, ByRef defaultValue As Object) As Boolean

參數

property
IReadOnlyProperty

屬性。

defaultValue
Object

預設值,如果未設定明確的預設值,則為 CLR 預設值。

傳回

true 如果已明確設定預設值,則為 ; false 否則。

適用於

TryGetDefaultValue(IReadOnlyProperty, StoreObjectIdentifier, Object)

傳回物件,這個物件會當做這個屬性所對應之資料行的預設值。

public static bool TryGetDefaultValue (this Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty property, in Microsoft.EntityFrameworkCore.Metadata.StoreObjectIdentifier storeObject, out object? defaultValue);
static member TryGetDefaultValue : Microsoft.EntityFrameworkCore.Metadata.IReadOnlyProperty * StoreObjectIdentifier * obj -> bool
<Extension()>
Public Function TryGetDefaultValue (property As IReadOnlyProperty, ByRef storeObject As StoreObjectIdentifier, ByRef defaultValue As Object) As Boolean

參數

property
IReadOnlyProperty

屬性。

storeObject
StoreObjectIdentifier

包含資料行之類似資料表的存放區物件的識別碼。

defaultValue
Object

預設值,如果未設定明確的預設值,則為 CLR 預設值。

傳回

true 如果已明確設定預設值,則為 ; false 否則。

適用於