public void Read(ReadContext c)
 {
     var id = new ItemDescription(DescriptionSource.File);
     var r = c.Reader;
     id.ItemSize = r.ReadInt32();
     id.ItemTypeName = r.ReadText();
     var fieldCount = r.ReadInt32();
     fieldCount.Times(() =>
         {
             var f = id.NewField();
             f.FieldType = (FieldType)r.ReadInt32();
             f.Offset = r.ReadInt32();
             f.Name = r.ReadText();
         });
     c.Description.ItemDescription = id;
 }
示例#2
0
        public void Read(ReadContext c)
        {
            var id = new ItemDescription(DescriptionSource.File);
            var r  = c.Reader;

            id.ItemSize     = r.ReadInt32();
            id.ItemTypeName = r.ReadText();
            var fieldCount = r.ReadInt32();

            fieldCount.Times(() =>
            {
                var f       = id.NewField();
                f.FieldType = (FieldType)r.ReadInt32();
                f.Offset    = r.ReadInt32();
                f.Name      = r.ReadText();
            });
            c.Description.ItemDescription = id;
        }