TransactionFlowBindingElement::CanBuildChannelListener<TChannel> Method (BindingContext^)
Returns a value that indicates whether the specified binding context can build a channel listener for accepting channels of a specified type.
Assembly: System.ServiceModel (in System.ServiceModel.dll)
public: generic<typename TChannel> where TChannel : ref class, IChannel virtual bool CanBuildChannelListener( BindingContext^ context ) override
Parameters
- context
-
Type:
System.ServiceModel.Channels::BindingContext^
The BindingContext that should be used to determine if a channel listener can be built.
Return Value
Type: System::Booleantrue if a channel listener for the specified type of channel can be built from context; otherwise, false.
Type Parameters
- TChannel
The channel type.
| Exception | Condition |
|---|---|
| ArgumentNullException | context is null. |
You should call this method to check that the channel listener for channels of type of TChannel can be built for the specified context, before attempting to actually build the listener. Note that BuildChannelListener<TChannel> throws an exception if it cannot build a channel listener for the specified channel type.
Available since 3.0