DiscoveryClientReferenceCollection.Contains(String) Methode
Definitie
Belangrijk
Bepaalde informatie heeft betrekking op een voorlopige productversie die aanzienlijk kan worden gewijzigd voordat deze wordt uitgebracht. Microsoft biedt geen enkele expliciete of impliciete garanties met betrekking tot de informatie die hier wordt verstrekt.
Bepaalt of het DiscoveryClientReferenceCollection een DiscoveryReference met de opgegeven URL bevat.
public:
bool Contains(System::String ^ url);
public bool Contains(string url);
member this.Contains : string -> bool
Public Function Contains (url As String) As Boolean
Parameters
- url
- String
De URL voor de DiscoveryReference te vinden url binnen de DiscoveryClientReferenceCollection.
Retouren
true als het DiscoveryClientReferenceCollection een DiscoveryReference met de opgegeven URL bevat; falseanders.
Voorbeelden
String^ myStringUrl1 = "http://localhost/dataservice.disco";
if ( myDiscoveryClientReferenceCollection->Contains( myStringUrl1 ) )
{
Console::WriteLine( "The document reference {0} is part of the collection.", myStringUrl1 );
}
string myStringUrl1 = "http://localhost/dataservice.disco";
if (myDiscoveryClientReferenceCollection.Contains(myStringUrl1))
{
Console.WriteLine("The document reference {0} is part of the"
+ " collection.", myStringUrl1);
}
Dim myStringUrl1 As String = "http://localhost/dataservice.disco"
If myDiscoveryClientReferenceCollection.Contains(myStringUrl1) Then
Console.WriteLine("The document reference {0} is part of the" + _
" collection.", myStringUrl1)
End If