MessageEncodingBindingElement 构造函数

定义

初始化 MessageEncodingBindingElement 类的新实例。

重载

MessageEncodingBindingElement()

初始化 MessageEncodingBindingElement 类的新实例。

MessageEncodingBindingElement(MessageEncodingBindingElement)

初始化从现有元素初始化的 MessageEncodingBindingElement 类的新实例。

MessageEncodingBindingElement()

Source:
MessageEncodingBindingElement.cs
Source:
MessageEncodingBindingElement.cs
Source:
MessageEncodingBindingElement.cs

初始化 MessageEncodingBindingElement 类的新实例。

protected:
 MessageEncodingBindingElement();
protected MessageEncodingBindingElement ();
Protected Sub New ()

适用于

MessageEncodingBindingElement(MessageEncodingBindingElement)

Source:
MessageEncodingBindingElement.cs
Source:
MessageEncodingBindingElement.cs
Source:
MessageEncodingBindingElement.cs

初始化从现有元素初始化的 MessageEncodingBindingElement 类的新实例。

protected:
 MessageEncodingBindingElement(System::ServiceModel::Channels::MessageEncodingBindingElement ^ elementToBeCloned);
protected MessageEncodingBindingElement (System.ServiceModel.Channels.MessageEncodingBindingElement elementToBeCloned);
new System.ServiceModel.Channels.MessageEncodingBindingElement : System.ServiceModel.Channels.MessageEncodingBindingElement -> System.ServiceModel.Channels.MessageEncodingBindingElement
Protected Sub New (elementToBeCloned As MessageEncodingBindingElement)

参数

示例

下面的代码演示如何实现此构造函数:

CustomTextMessageBindingElement(CustomTextMessageBindingElement binding)
    : this(binding.Encoding, binding.MediaType, binding.MessageVersion)
{
    this.readerQuotas = new XmlDictionaryReaderQuotas();
    binding.ReaderQuotas.CopyTo(this.readerQuotas);
}

适用于