Пример #1
0
        private TMap ReadMap(IMsgPackReader reader, uint length)
        {
            var map = (TMap)Context.GetObjectActivator(typeof(TMap))();

            for (var i = 0u; i < length; i++)
            {
                var key   = KeyConverter.Read(reader);
                var value = ValueConverter.Read(reader);

                map[key] = value;
            }

            return(map);
        }