OperationCollection.Contains(Operation) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns a value indicating whether the specified Operation is a member of the OperationCollection.
public:
bool Contains(System::Web::Services::Description::Operation ^ operation);
public bool Contains (System.Web.Services.Description.Operation operation);
member this.Contains : System.Web.Services.Description.Operation -> bool
Public Function Contains (operation As Operation) As Boolean
Parameters
Returns
true
if operation
is a member of the OperationCollection; otherwise, false
.
Examples
The following example demonstrates the use of the Contains
method.
if ( myOperationCollection->Contains( myOperation ) == true )
{
Console::WriteLine( "The index of the added 'myOperation' operation is : {0}", myOperationCollection->IndexOf( myOperation ) );
}
if(myOperationCollection.Contains(myOperation) == true)
{
Console.WriteLine("The index of the added 'myOperation' " +
"operation is : " +
myOperationCollection.IndexOf(myOperation));
}
If myOperationCollection.Contains(myOperation) = True Then
Console.WriteLine("The index of the added 'myOperation' " + _
"operation is : " + _
myOperationCollection.IndexOf(myOperation).ToString)
End If
Applies to
Colaborar conosco no GitHub
A fonte deste conteúdo pode ser encontrada no GitHub, onde você também pode criar e revisar problemas e solicitações de pull. Para obter mais informações, confira o nosso guia para colaboradores.