次の方法で共有


EndpointAddress.Equality(EndpointAddress, EndpointAddress) 演算子

定義

指定した 2 つのエンドポイント アドレスが等しいかどうかを示す値を返します。

public:
 static bool operator ==(System::ServiceModel::EndpointAddress ^ address1, System::ServiceModel::EndpointAddress ^ address2);
public static bool operator == (System.ServiceModel.EndpointAddress address1, System.ServiceModel.EndpointAddress address2);
static member ( = ) : System.ServiceModel.EndpointAddress * System.ServiceModel.EndpointAddress -> bool
Public Shared Operator == (address1 As EndpointAddress, address2 As EndpointAddress) As Boolean

パラメーター

address1
EndpointAddress

比較する EndpointAddress オブジェクトの 1 つ。

address2
EndpointAddress

比較する EndpointAddress オブジェクトの 1 つ。

戻り値

Boolean

2 つのエンドポイント アドレスが同等である場合は true、それ以外の場合は false

EndpointAddress endpointAddress = new EndpointAddress(
    new Uri("http://localhost:8003/servicemodelsamples/service/incode/identity"), addressHeaders);
EndpointAddress endpointAddress2 = new EndpointAddress(
   new Uri("http://localhost:8003/servicemodelsamples/service/incode/identity"), addressHeaders);

if (endpointAddress == endpointAddress2)
    Console.WriteLine("The two endpoint addresses are equal");
else
    Console.WriteLine("The two endpoint addresses are not equal");

注釈

この演算子の同等のメソッドは .EndpointAddress.Equals

適用対象