Example #1
0
        public static byte[] Serialize(WResponse workload)
        {
            var s   = new BinaryFormatter();
            var str = new MemoryStream();

            s.Serialize(str, workload);
            str.Position = 0;
            var b = new byte[str.Length];

            str.Read(b, 0, (int)str.Length);

            return(b);
        }
Example #2
0
 public static byte[] Serialize(this WResponse src)
 {
     return(WResponse.Serialize(src));
 }