共用方式為


WebHttpBindingElement.HostNameComparisonMode 屬性

定義

取得或設定值,這個值會指出在比對 URI 時此主機名稱是否會用來取用服務。

public:
 property System::ServiceModel::HostNameComparisonMode HostNameComparisonMode { System::ServiceModel::HostNameComparisonMode get(); void set(System::ServiceModel::HostNameComparisonMode value); };
[System.Configuration.ConfigurationProperty("hostNameComparisonMode", DefaultValue=System.ServiceModel.HostNameComparisonMode.StrongWildcard)]
[System.ServiceModel.Configuration.ServiceModelEnumValidator(typeof(System.ServiceModel.HostNameComparisonModeHelper))]
public System.ServiceModel.HostNameComparisonMode HostNameComparisonMode { get; set; }
[<System.Configuration.ConfigurationProperty("hostNameComparisonMode", DefaultValue=System.ServiceModel.HostNameComparisonMode.StrongWildcard)>]
[<System.ServiceModel.Configuration.ServiceModelEnumValidator(typeof(System.ServiceModel.HostNameComparisonModeHelper))>]
member this.HostNameComparisonMode : System.ServiceModel.HostNameComparisonMode with get, set
Public Property HostNameComparisonMode As HostNameComparisonMode

屬性值

HostNameComparisonMode

HostNameComparisonMode 值,指出在比對 URI 時此主機名稱是否會用來取用服務。 預設值為 StrongWildcard,表示比對時忽略主機名稱。

屬性
ConfigurationPropertyAttribute ServiceModelEnumValidatorAttribute

例外狀況

設定的值不是有效的 HostNameComparisonMode 值。

適用於