NotImplementedException クラス
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
要求されたメソッドまたは操作が実装されていない場合にスローされる例外。
public ref class NotImplementedException : Exception
public ref class NotImplementedException : SystemException
public class NotImplementedException : Exception
public class NotImplementedException : SystemException
[System.Serializable]
public class NotImplementedException : SystemException
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public class NotImplementedException : SystemException
type NotImplementedException = class
inherit Exception
type NotImplementedException = class
inherit SystemException
[<System.Serializable>]
type NotImplementedException = class
inherit SystemException
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type NotImplementedException = class
inherit SystemException
Public Class NotImplementedException
Inherits Exception
Public Class NotImplementedException
Inherits SystemException
- 継承
- 継承
- 属性
例
次の例では、開発されていないメソッドに対してこの例外をスローします。
static void Main(string[] args)
{
try
{
FutureFeature();
}
catch (NotImplementedException notImp)
{
Console.WriteLine(notImp.Message);
}
}
static void FutureFeature()
{
// Not developed yet.
throw new NotImplementedException();
}
open System
let futureFeature () =
// Not developed yet.
raise (NotImplementedException())
[<EntryPoint>]
let main _ =
try
futureFeature ()
with :? NotImplementedException as notImp ->
printfn $"{notImp.Message}"
0
Sub Main()
Try
FutureFeature()
Catch NotImp As NotImplementedException
Console.WriteLine(NotImp.Message)
End Try
End Sub
Sub FutureFeature()
' not developed yet.
Throw New NotImplementedException()
End Sub
注釈
この API の詳細については、「 NotImplementedException の補足 API 解説」を参照してください。
コンストラクター
| 名前 | 説明 |
|---|---|
| NotImplementedException() |
既定のプロパティを使用して、 NotImplementedException クラスの新しいインスタンスを初期化します。 |
| NotImplementedException(SerializationInfo, StreamingContext) |
古い.
シリアル化されたデータを使用して、 NotImplementedException クラスの新しいインスタンスを初期化します。 |
| NotImplementedException(String, Exception) |
指定したエラー メッセージと、この例外の原因である内部例外への参照を使用して、 NotImplementedException クラスの新しいインスタンスを初期化します。 |
| NotImplementedException(String) |
指定したエラー メッセージを使用して、 NotImplementedException クラスの新しいインスタンスを初期化します。 |
プロパティ
| 名前 | 説明 |
|---|---|
| Data |
例外に関する追加のユーザー定義情報を提供するキーと値のペアのコレクションを取得します。 (継承元 Exception) |
| HelpLink |
この例外に関連付けられているヘルプ ファイルへのリンクを取得または設定します。 (継承元 Exception) |
| HResult |
特定の例外に割り当てられるコード化された数値である HRESULT を取得または設定します。 (継承元 Exception) |
| InnerException |
現在の例外の原因となった Exception インスタンスを取得します。 (継承元 Exception) |
| Message |
現在の例外を説明するメッセージを取得します。 (継承元 Exception) |
| Source |
エラーの原因となるアプリケーションまたはオブジェクトの名前を取得または設定します。 (継承元 Exception) |
| StackTrace |
呼び出し履歴のイミディエイト フレームの文字列表現を取得します。 (継承元 Exception) |
| TargetSite |
現在の例外をスローするメソッドを取得します。 (継承元 Exception) |
メソッド
| 名前 | 説明 |
|---|---|
| Equals(Object) |
指定したオブジェクトが現在のオブジェクトと等しいかどうかを判断します。 (継承元 Object) |
| GetBaseException() |
派生クラスでオーバーライドされた場合、1 つ以上の後続の例外の根本原因である Exception を返します。 (継承元 Exception) |
| GetHashCode() |
既定のハッシュ関数として機能します。 (継承元 Object) |
| GetObjectData(SerializationInfo, StreamingContext) |
古い.
派生クラスでオーバーライドされた場合は、例外に関する情報を使用して SerializationInfo を設定します。 (継承元 Exception) |
| GetType() |
現在のインスタンスのランタイム型を取得します。 (継承元 Exception) |
| MemberwiseClone() |
現在の Objectの簡易コピーを作成します。 (継承元 Object) |
| ToString() |
現在の例外の文字列形式を作成して返します。 (継承元 Exception) |
イベント
| 名前 | 説明 |
|---|---|
| SerializeObjectState |
古い.
例外に関するシリアル化されたデータを含む例外状態オブジェクトを作成するために例外がシリアル化されるときに発生します。 (継承元 Exception) |