NetSamples.Common.IO
Class MessageWriter

A writer class that writes objects to a stream using the XML serializer.

Field Summary
System.Collections.Hashtable serializers
System.IO.BinaryWriter writer

Constructor Summary
MessageWriter(System.Type[] messagetypes)
         Constructor
MessageWriter(System.IO.Stream output, System.Type[] messagetypes)
         Constructor

Property Summary
System.IO.Stream BaseStream
         Gets / Sets the stream that the writer is using

Method Summary
void Write(object message)
         Writes an object to the stream using the XML serializer

Methods inherited from class System.Object
Equals, Finalize, GetHashCode, GetType, MemberwiseClone, ToString


Field Detail

serializers

private System.Collections.Hashtable serializers


writer

private System.IO.BinaryWriter writer

Constructor Detail

MessageWriter

public MessageWriter(System.Type[] messagetypes)

Constructor


MessageWriter

public MessageWriter(System.IO.Stream output,
                     System.Type[] messagetypes)

Constructor

Property Detail

BaseStream

public System.IO.Stream BaseStream

Gets / Sets the stream that the writer is using

Method Detail

Write

public void Write(object message)

Writes an object to the stream using the XML serializer