Printer Friendly Version      Send     
Click to Rate and Give Feedback
TechNet
TechNet Library
BizTalk Server
BizTalk Server 2004
SDK
Microsoft BizTalk Server 2004
IDataReader Interface

Converts a native document to XML.

For a list of all members of this type, see IDataReader Members.

[Visual Basic]
Public Interface IDataReader
[C#]
public interface IDataReader
[C++]
public __gc __interface IDataReader
[JScript]
public interface IDataReader

Classes that Implement IDataReader

Class Description
DataReader Normalizes data from various encoding mechanisms, such as UTF-8, ANSI, and MBCS, into USC-2.

Remarks

To customize input sent to BizTalk Server, you can choose to implement either System.IO.Encoding, System.IO.TextReader or IDataReader.

To customize output from BizTalk Server, you should implement the System.IO.Encoding base class.

Use the following code to parse input using System.IO.Encoding:

XmlReader reader = docspec.Parse(new DataReader(new StreamReader(inputStream, new MyEncoding())));

Use the following code to serialize output using System.IO.Encoding:

Stream stm = docspec.Serialize(xmlReader, new MyEncoding());

If you choose to derive your class from System.IO.TextReader, you must pass your class into the class constructor for DataReader when you invoke the Parse method on the schema. Use the following code in this situation:

XmlReader reader = docspec.Parse(new DataReader(new MyTextReader()));

Alternatively, if you implement IDataReader directly, use the following code:

XmlReader reader = docspec.Parse(new MyDataReader());

Requirements

Namespace: Microsoft.BizTalk.ParsingEngine

Platforms: Windows 2000, Windows XP Professional, Windows Server 2003

Assembly:  Biztalk Pipeline Interop (in Microsoft.Biztalk.Pipeline.dll)

See Also

IDataReader Members | Microsoft.BizTalk.ParsingEngine Namespace

To download updated BizTalk Server 2004 Help from www.microsoft.com, go to http://go.microsoft.com/fwlink/?linkid=20616.

© 2008 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker