public void Serialize(object obj, Stream stream)
        {
            var writer = new StreamBinaryWriter(stream, false, true);
            var ctx    = new MyBinarySerializerWriter(writer);

            ctx.WriteInstance(obj);
            writer.Flush();
            stream.Flush();
        }
Example #2
0
 public MyBinarySerializerWriter(StreamBinaryWriter writer)
 {
     _writer = writer;
 }