IEndpointBehavior.Validate(ServiceEndpoint) 方法

定義

您可以實作這個方法以確認端點符合某些預定的準則。

public:
 void Validate(System::ServiceModel::Description::ServiceEndpoint ^ endpoint);
public void Validate (System.ServiceModel.Description.ServiceEndpoint endpoint);
abstract member Validate : System.ServiceModel.Description.ServiceEndpoint -> unit
Public Sub Validate (endpoint As ServiceEndpoint)

參數

endpoint
ServiceEndpoint

要驗證的端點。

備註

您可以實作 Validate 方法來檢查結構,以確認任何一組條件。 使用這個方法,不需要在 ApplyClientBehaviorApplyDispatchBehavior 中執行任何自訂。 如果端點通過驗證,就會傳回,否則會擲回例外狀況。

例如,Validate 方法可用於確保所有的端點都使用經過認可的企業繫結。

適用於