Exemplo n.º 1
0
        public static void Read <T>(this IDictionary <string, T> _this, EndianStream stream)
            where T : IStreamReadable, new()
        {
            int count = stream.ReadInt32();

            for (int i = 0; i < count; i++)
            {
                string key   = stream.ReadStringAligned();
                T      value = new T();
                value.Read(stream);
                _this.Add(key, value);
            }
        }