CompositeDuplexBindingElement 類別

定義

表示繫結項目,這是當用戶端必須公開 (Expose) 服務的端點才能將訊息傳回用戶端時所使用的項目。Represents the binding element that is used when the client must expose an endpoint for the service to send messages back to the client.

public ref class CompositeDuplexBindingElement sealed : System::ServiceModel::Channels::BindingElement, System::ServiceModel::Description::IPolicyExportExtension
public sealed class CompositeDuplexBindingElement : System.ServiceModel.Channels.BindingElement, System.ServiceModel.Description.IPolicyExportExtension
type CompositeDuplexBindingElement = class
    inherit BindingElement
    interface IPolicyExportExtension
Public NotInheritable Class CompositeDuplexBindingElement
Inherits BindingElement
Implements IPolicyExportExtension
繼承
CompositeDuplexBindingElement
實作

備註

這個項目通常都是和本身不允許雙工通訊的傳輸一起使用,例如 HTTP。This is commonly used with transports, such as HTTP, that do not allow duplex communications natively. 相反地,TCP 本身就允許雙工通訊,因此不需要使用這個繫結項目也可讓服務將訊息傳回用戶端。TCP, by contrast, does allow duplex communications natively and so does not require the use of this binding element for the service to send messages back to a client.

用戶端必須公開服務能夠在該處連絡它以建立從服務至用戶端之連線的位址。The client must expose an address at which the service can contact it to establish a connection from the service to the client. 這個用戶端位址是由 ClientBaseAddress 屬性提供的。This client address is provided by the ClientBaseAddress property. 請注意, ClientBaseAddress如果使用者未明確設定, Windows Communication Foundation (WCF) 會自動產生。Note that Windows Communication Foundation (WCF) auto-generates a ClientBaseAddress if one is not explicitly set by the user.

建構函式

CompositeDuplexBindingElement()

初始化 CompositeDuplexBindingElement 類別的新執行個體。Initializes a new instance of the CompositeDuplexBindingElement class.

屬性

ClientBaseAddress

取得或設定用戶端的基底位址 (Base Address)。Gets or sets the base address for the client.

方法

BuildChannelFactory<TChannel>(BindingContext)

傳回可以建立複合雙工通道的通道處理站。Returns a channel factory that can create a composite duplex channel.

BuildChannelListener<TChannel>(BindingContext)

傳回可以接受複合雙工通道的通道接聽程式。Returns a channel listener that can accept a composite duplex channel.

CanBuildChannelFactory<TChannel>(BindingContext)

傳回值,這個值會指出繫結程序是否可以建置通道處理站,以產生符合內容需求的特定通道型別。Returns a value that indicates whether the binding can build the channel factory that produces a specific type of channel that satisfies the context requirements.

CanBuildChannelListener<TChannel>(BindingContext)

傳回值,這個值會指出繫結程序是否可以建置通道接聽項,以接受符合內容需求的特定通道型別。Returns a value that indicates whether the binding can build the channel listener that accepts a specific type of channel that satisfies the context requirements.

Clone()

傳回目前繫結項目的深層複製。Returns a deep clone of the current binding element.

Equals(Object)

判斷指定的物件是否等於目前的物件。Determines whether the specified object is equal to the current object.

(繼承來源 Object)
GetHashCode()

作為預設雜湊函數。Serves as the default hash function.

(繼承來源 Object)
GetProperty<T>(BindingContext)

從其中一個通道堆疊的適當層次傳回要求的型別物件。Returns a typed object requested from the appropriate layer in one of the channel stacks.

GetType()

取得目前執行個體的 TypeGets the Type of the current instance.

(繼承來源 Object)
MemberwiseClone()

建立目前 Object 的淺層複製。Creates a shallow copy of the current Object.

(繼承來源 Object)
ToString()

傳回代表目前物件的字串。Returns a string that represents the current object.

(繼承來源 Object)

明確介面實作

IPolicyExportExtension.ExportPolicy(MetadataExporter, PolicyConversionContext)

匯出有關繫結的自訂原則判斷提示,這些判斷提示表示該繫結中存在複合雙工。Exports custom policy assertions about bindings that represent the presence of composite duplex in the binding.

適用於