DiscoveryClientReferenceCollection.Remove(String) 方法

定義

將有指定 URL 的 DiscoveryReferenceDiscoveryClientReferenceCollection 中移除。

public:
 void Remove(System::String ^ url);
public void Remove (string url);
member this.Remove : string -> unit
Public Sub Remove (url As String)

參數

url
String

字串,表示要從 DiscoveryClientReferenceCollection 移除之物件的 URL。

範例

DiscoveryDocumentReference^ myDiscoveryDocumentReference = gcnew DiscoveryDocumentReference;
String^ myStringUrl = "http://www.contoso.com/service.disco";
myDiscoveryClientReferenceCollection->Add( myStringUrl, myDiscoveryDocumentReference );

myDiscoveryClientReferenceCollection->Remove( myStringUrl );
DiscoveryDocumentReference myDiscoveryDocumentReference =
    new DiscoveryDocumentReference();
string myStringUrl = "http://www.contoso.com/service.disco";
myDiscoveryClientReferenceCollection.Add(myStringUrl,
    myDiscoveryDocumentReference);
myDiscoveryClientReferenceCollection.Remove(myStringUrl);
Dim myDiscoveryDocumentReference As New DiscoveryDocumentReference()
Dim myStringUrl As String = "http://www.contoso.com/service.disco"
myDiscoveryClientReferenceCollection.Add(myStringUrl, _
    myDiscoveryDocumentReference)
myDiscoveryClientReferenceCollection.Remove(myStringUrl)

適用於