public object Deserialize(ObjectReader reader)
 {
     SessionStateItemCollection items = new SessionStateItemCollection();
     var count = reader.ReadInt32();
     for(int i = 0; i < count; i++)
     {
         var name = (string)reader.Deserialize();
         var value = reader.Deserialize();
         items[name] = value;
     }
     return items;
 }
Example #2
0
        public static Byte[] ReadByteArray(this ObjectReader reader)
        {
            var length = reader.ReadInt32();

            return(reader.ReadBuffer(length));
        }
Example #3
0
        public static object ReadReference(this ObjectReader reader)
        {
            var index = reader.ReadInt32();

            return(reader.ReferenceContainer[index]);
        }