DiscoveryClientReferenceCollection.Contains(String) 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.
Determines if the DiscoveryClientReferenceCollection contains a DiscoveryReference with the specified URL.
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
The URL for the DiscoveryReference to locate within the DiscoveryClientReferenceCollection.
Returns
true
if the DiscoveryClientReferenceCollection contains a DiscoveryReference with the specified URL; otherwise, false
.
Examples
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
Applies to
שתף איתנו פעולה ב- GitHub
ניתן למצוא את המקור לתוכן זה ב- GitHub, שם ניתן גם ליצור ולסקור בעיות ולמשוך בקשות. לקבלת מידע נוסף, עיין במדריך התורמים שלנו.