Evidence.Equals(Object) Método

Definición

Determina si el objeto Evidence especificado es igual al objeto Evidence actual.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

Parámetros

obj
Object

Objeto Evidence que se va a comparar con el objeto Evidence actual.The Evidence object to compare with the current Evidence.

Devoluciones

Es true si el objeto Evidence especificado es igual al objeto Evidence actual; en caso contrario, es false.true if the specified Evidence object is equal to the current Evidence; otherwise, false.

Atributos

Ejemplos

En el ejemplo de código siguiente se muestra el uso del método Equals.The following code example shows the use of the Equals method. Este ejemplo forma parte de un ejemplo más extenso proporcionado para la clase 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 ) );

Comentarios

Para obtener más información, vea Equals.For more information, see Equals.

Se aplica a