Share via


AssertFailedException コンストラクター (SerializationInfo, StreamingContext)

シリアル化したデータを使用して、AssertFailedException クラスの新しいインスタンスを初期化します。

名前空間:  Microsoft.VisualStudio.TestTools.UnitTesting
アセンブリ:  Microsoft.VisualStudio.QualityTools.UnitTestFramework (Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll 内)

構文

'宣言
Protected Sub New ( _
    info As SerializationInfo, _
    context As StreamingContext _
)
protected AssertFailedException(
    SerializationInfo info,
    StreamingContext context
)
protected:
AssertFailedException(
    SerializationInfo^ info, 
    StreamingContext context
)
new : 
        info:SerializationInfo * 
        context:StreamingContext -> AssertFailedException
protected function AssertFailedException(
    info : SerializationInfo, 
    context : StreamingContext
)

パラメーター

  • info
    型 : SerializationInfo

    スローされている例外に関するシリアル化済みオブジェクト データを保持している SerializationInfo

  • context
    型 : StreamingContext

    転送元または転送先に関するコンテキスト情報を含んでいる StreamingContext

例外

例外 条件
ArgumentNullException

info は nullnull 参照 (Visual Basic では Nothing) なので、

SerializationException

クラス名が nullnull 参照 (Visual Basic では Nothing) であるか、または HResult が 0 です。

.NET Framework セキュリティ

  • 直前の呼び出し元に対する完全な信頼。このメンバーは、部分的に信頼されているコードから使用することはできません。詳細については、「部分信頼コードからのライブラリの使用」を参照してください。

参照

関連項目

AssertFailedException クラス

AssertFailedException オーバーロード

Microsoft.VisualStudio.TestTools.UnitTesting 名前空間

その他の技術情報

Assert クラスの使用