예제 #1
0
        internal void Serialize(MemoryStream stream, object data)
        {
            MemoryDataBuffer buffer = new MemoryDataBuffer(stream);
            MProto           proto  = new MBinaryProto(buffer);

            Write(proto, data);
        }
예제 #2
0
        internal T Deserialize <T>(MemoryStream ms)
        {
            MemoryDataBuffer buffer = new MemoryDataBuffer(ms);
            MProto           proto  = new MBinaryProto(buffer);
            object           res    = Read(proto, typeof(T));

            return((T)res);
        }
예제 #3
0
        internal object Deserialize(MemoryStream ms, Mio meta)
        {
            MemoryDataBuffer buffer = new MemoryDataBuffer(ms);
            MProto           proto  = new MBinaryProto(buffer);
            object           res    = Read(proto, meta);

            return(res);
        }
예제 #4
0
 //  interfaces
 internal void Serialize(MemoryStream stream, Mio meta, object data)
 {
     MemoryDataBuffer buffer = new MemoryDataBuffer(stream);
     MProto proto = new MBinaryProto(buffer);
     Write(proto, meta, data);
 }
예제 #5
0
 internal object Deserialize(MemoryStream ms, Mio meta)
 {
     MemoryDataBuffer buffer = new MemoryDataBuffer(ms);
     MProto proto = new MBinaryProto(buffer);
     object res = Read(proto, meta);
     return res;
 }