DbContextModelAttribute クラス
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
特定のコンテキストに使用する必要がある RuntimeModel 実装を識別します。
[System.AttributeUsage(System.AttributeTargets.Assembly, AllowMultiple=true)]
[System.Runtime.CompilerServices.Nullable(0)]
public sealed class DbContextModelAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Assembly, AllowMultiple=true)>]
[<System.Runtime.CompilerServices.Nullable(0)>]
type DbContextModelAttribute = class
inherit Attribute
Public NotInheritable Class DbContextModelAttribute
Inherits Attribute
- 継承
-
DbContextModelAttribute
- 属性
注釈
通常、この属性はコンパイル済みモデルで生成されるため、コードで指定する必要はありません。
詳細と例については、 DbContext プールの使用 を参照してください。
コンストラクター
| Name | 説明 |
|---|---|
| DbContextModelAttribute(Type, Type) |
DbContextAttribute クラスの新しいインスタンスを初期化します。 |
プロパティ
| Name | 説明 |
|---|---|
| ContextType |
関連付けられているコンテキストを取得します。 |
| ModelType |
コンパイル済みモデルを取得します。 |
| ProviderName |
コンパイル済みモデルのビルドに使用されるデータベース プロバイダー名を取得します。 |