DiscoveryClientReferenceCollection::Contains Method (String^)

 

Determines if the DiscoveryClientReferenceCollection contains a DiscoveryReference with the specified URL.

Namespace:   System.Web.Services.Discovery
Assembly:  System.Web.Services (in System.Web.Services.dll)

public:
bool Contains(
	String^ url
)

Parameters

url
Type: System::String^

The URL for the DiscoveryReference to locate within the DiscoveryClientReferenceCollection.

Return Value

Type: System::Boolean

true if the DiscoveryClientReferenceCollection contains a DiscoveryReference with the specified URL; otherwise, false.

String^ myStringUrl1 = "http://localhost/dataservice.disco";
if ( myDiscoveryClientReferenceCollection->Contains( myStringUrl1 ) )
{
   Console::WriteLine( "The document reference {0} is part of the  collection.", myStringUrl1 );
}

.NET Framework
Available since 1.1
Return to top
Show: