TcpTransportElement.PortSharingEnabled 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
取得或設定一個值,指定此連線是否啟用 TCP 埠共享。
public:
property bool PortSharingEnabled { bool get(); void set(bool value); };
[System.Configuration.ConfigurationProperty("portSharingEnabled", DefaultValue=false)]
public bool PortSharingEnabled { get; set; }
[<System.Configuration.ConfigurationProperty("portSharingEnabled", DefaultValue=false)>]
member this.PortSharingEnabled : bool with get, set
Public Property PortSharingEnabled As Boolean
屬性值
true 若啟用 TCP 埠共享; false 如果每個綁定都使用自己的專屬埠。 預設值為 false。
- 屬性
備註
此設定僅適用於服務。 客戶不會受影響。
使用此設定需啟用 Windows Communication Foundation(WCF)TCP 埠共享服務,並將啟動類型改為手動或自動。
關於 TCP 監聽器及啟動方法的更多資訊,請參見 TcpListener。