Evidence.Equals(Object) Evidence.Equals(Object) Evidence.Equals(Object) Evidence.Equals(Object) Method

定義

指定した Evidence オブジェクトが、現在の Evidence と等しいかどうかを判断します。Determines whether the specified Evidence object is equal to the current Evidence.

public:
 override bool Equals(System::Object ^ obj);
[System.Runtime.InteropServices.ComVisible(false)]
public override bool Equals (object obj);
override this.Equals : obj -> bool
Public Overrides Function Equals (obj As Object) As Boolean

パラメーター

obj
Object Object Object Object

現在の Evidence と比較する Evidence オブジェクト。The Evidence object to compare with the current Evidence.

戻り値

指定した Evidence オブジェクトが現在の Evidence と等しい場合は true。それ以外の場合は false。true if the specified Evidence object is equal to the current Evidence; otherwise, false.

次のコード例では、Equals メソッドの使用を示します。The following code example shows the use of the Equals method. この例が示されている例の一部、Evidenceクラス。This example is part of a larger example provided for the Evidence class.

Console.WriteLine(ControlChars.Lf & "Make a copy of the current evidence.")
Dim evidenceCopy As New Evidence(myEvidence)
Console.WriteLine(("Count of new evidence items = " & evidenceCopy.Count.ToString()))
Console.WriteLine(("Does the copy equal the current evidence? " & myEvidence.Equals(evidenceCopy)))
Console.WriteLine("\nMake a copy of the current evidence.");
Evidence evidenceCopy = new Evidence(myEvidence);
Console.WriteLine("Count of new evidence items = " + evidenceCopy.Count);
Console.WriteLine("Does the copy equal the current evidence? " + myEvidence.Equals(evidenceCopy));
Console::WriteLine( "\nMake a copy of the current evidence." );
Evidence^ evidenceCopy = gcnew Evidence( myEvidence );
Console::WriteLine( "Count of new evidence items = {0}", evidenceCopy->Count );
Console::WriteLine( "Does the copy equal the current evidence? {0}", myEvidence->Equals( evidenceCopy ) );

注釈

詳細については、「Equals」を参照してください。For more information, see Equals.

適用対象