Share via


DbContext.GetType メソッド

[このページは、Entity Framework 6 に関するページです。最新バージョンは、'Entity Framework' NuGet パッケージとして入手できます。Entity Framework の詳細については、msdn.com/data/ef を参照してください。]

現在の DbContext の型を返します。

名前空間:  System.Data.Entity
アセンブリ:  EntityFramework (EntityFramework.dll 内)

構文

'宣言
<SuppressMessageAttribute("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")> _
<EditorBrowsableAttribute(EditorBrowsableState.Never)> _
Public Function GetType As Type
'使用
Dim instance As DbContext 
Dim returnValue As Type 

returnValue = instance.GetType()
[SuppressMessageAttribute("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
[EditorBrowsableAttribute(EditorBrowsableState.Never)]
public Type GetType()
[SuppressMessageAttribute(L"Microsoft.Design", L"CA1024:UsePropertiesWhereAppropriate")]
[EditorBrowsableAttribute(EditorBrowsableState::Never)]
public:
Type^ GetType()
[<SuppressMessageAttribute("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")>]
[<EditorBrowsableAttribute(EditorBrowsableState.Never)>]
member GetType : unit -> Type
public function GetType() : Type

戻り値

型 : System.Type
現在の DbContext の型。

参照

参照

DbContext クラス

System.Data.Entity 名前空間