博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

2011年11月1日

摘要: public static TestStruct FromFileStream(FileStream fs) { //Create Buffer byte[] buff = new byte[Marshal.SizeOf(typeof(TestStruct))]; int amt = 0; //Loop until we've read enough bytes (usually once) while(amt < buff.Length) amt += fs.Read(buff, amt, buff.Length-amt); ... 阅读全文

posted @ 2011-11-01 01:05 freewzx2005 阅读(576) 评论(0) 推荐(0) 编辑