This documentation is archived and is not being maintained.

XmlDictionaryReader.CreateMtomReader Method (Byte[], Int32, Int32, Encoding[], String, XmlDictionaryReaderQuotas, Int32, OnXmlDictionaryReaderClose)

Creates an instance of XmlDictionaryReader that reads XML in the MTOM format.

Namespace: System.Xml
Assembly: System.Runtime.Serialization (in system.runtime.serialization.dll)

'Declaration
Public Shared Function CreateMtomReader ( _
	buffer As Byte(), _
	offset As Integer, _
	count As Integer, _
	encodings As Encoding(), _
	contentType As String, _
	quotas As XmlDictionaryReaderQuotas, _
	maxBufferSize As Integer, _
	onClose As OnXmlDictionaryReaderClose _
) As XmlDictionaryReader
'Usage
Dim buffer As Byte()
Dim offset As Integer
Dim count As Integer
Dim encodings As Encoding()
Dim contentType As String
Dim quotas As XmlDictionaryReaderQuotas
Dim maxBufferSize As Integer
Dim onClose As OnXmlDictionaryReaderClose
Dim returnValue As XmlDictionaryReader

returnValue = XmlDictionaryReader.CreateMtomReader(buffer, offset, count, encodings, contentType, quotas, maxBufferSize, onClose)
public static XmlDictionaryReader CreateMtomReader (
	byte[] buffer, 
	int offset, 
	int count, 
	Encoding[] encodings, 
	String contentType, 
	XmlDictionaryReaderQuotas quotas, 
	int maxBufferSize, 
	OnXmlDictionaryReaderClose onClose
)
public static function CreateMtomReader (
	buffer : byte[], 
	offset : int, 
	count : int, 
	encodings : Encoding[], 
	contentType : String, 
	quotas : XmlDictionaryReaderQuotas, 
	maxBufferSize : int, 
	onClose : OnXmlDictionaryReaderClose
) : XmlDictionaryReader
Not applicable.

Parameters

buffer

The buffer from which to read.

offset

The starting position from which to read in buffer.

count

The number of bytes that can be read from buffer.

encodings

The possible character encodings of the input.

contentType

The Content-Type MIME type of the message.

quotas

The XmlDictionaryReaderQuotas to apply to the reader.

maxBufferSize

The maximum allowed size of the buffer.

onClose

The delegate to be called when the reader is closed.

Return Value

An instance of XmlDictionaryReader.

This method reads from a buffer with a specified offset and count, using one of the character encodings specified by encodings, an array of instances of Encoding. The message is of the specified MIME type. If contentType is a null reference (Nothing in Visual Basic), the Content-Type MIME header must be present in the message.

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0
Show: