Export (0) Print
Expand All

WebMessageEncodingBindingElement Constructor

Initializes a new instance of the WebMessageEncodingBindingElement class.

Namespace:  System.ServiceModel.Channels
Assembly:  System.ServiceModel.Web (in System.ServiceModel.Web.dll)

public WebMessageEncodingBindingElement()

This constructor uses UTF8Encoding as the default character encoding. So use this constructor when you want this character encoding. If you want another character encoding, use the WebMessageEncodingBindingElement(Encoding) constructor.

This constructor sets default values on the maximum number of readers and writers that are allocated to pools and that are respectively available to process incoming and outgoing messages without allocating new readers or writers. There are 64 readers allocated by default for the MaxReadPoolSize property and there are 16 writers allocated by default for the MaxWritePoolSize property.

Default complexity constraints are also set by this constructor on the XmlDictionaryReaderQuotas associated with this message encoding by the ReaderQuotas property to protect against a class of denial of service (DOS) attacks that attempt to use message complexity to tie up endpoint processing resources. The properties that express these constraints and their default values (in bytes) are as follows:

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5

.NET Framework Client Profile

Supported in: 3.5 SP1
Show:
© 2015 Microsoft