Binding.BindingInformation 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
获取或设置当前绑定的绑定信息。
public:
property System::String ^ BindingInformation { System::String ^ get(); void set(System::String ^ value); };
public string BindingInformation { get; set; }
member this.BindingInformation : string with get, set
Public Property BindingInformation As String
属性值
当前绑定的 IP 地址、端口和主机名。
示例
以下示例演示 了 BindingInformation 属性。 此代码示例是为 Binding 类提供的一个更大示例的一部分。
bindingdisplay = bindingdisplay + " Binding:\n BindingInformation: " +
binding.BindingInformation;
注解
此属性的值是一个冒号分隔的字符串,其中包含绑定的 IP 地址、端口和主机名。 可以将主机名留空。 可以将 IP 地址设置为“*”,以指示绑定适用于所有变量。
例如,为端口 80 上所有 IP 地址设置且没有指定主机名的绑定从此属性返回“*:80:”。 为端口 8080 上的 IP 地址 192.168.1.150 设置的绑定返回“192.168.1.150:8080:”。 为名为“microsoft.com”的主机端口 80 上的所有 IP 地址设置的绑定将返回“*:80:microsoft.com”。
属性值 BindingInformation 保留在 ApplicationHost.config 文件中。
适用于
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈