C++开发博客CSDN
摘要: byte[] BytePara = 为从C++里取出的字节数组;InfoDataStruct 为结构,循环将Byte数组里的内容转换为结构InfoDataStruct* p = (InfoDataStruct*)(BytePara+ (i * 55));InfoDataStruct dataStruct= BytesToStruct<InfoDataStruct>(BytePara,(i * 55));///不使用泛型,会使得编码繁琐。 public static object BytesToStruct(byte[] bytes, int startIndex, Type str 阅读全文
posted @ 2012-12-11 11:09 纳凉亭子 阅读(1001) 评论(0) 推荐(0) 编辑