1

In C# I am reading a binary message buffer from a socket and I want to try to map this binary array to an actual class method with getter/setters for each data member. What is the best to try to map the byte[] data into a class? I have an ICD which specifies the size and offset of each message field. I want to take a byte array the constrtor input and then I need to parse out the correct message fields. Is there any slick way to do that besides getting the data at the particular offset and copying the data into the correct field?

That just seems to be too labor intesive to do it for every message field. Also, what are the best methods for parsing byte data?

Thanks yous

user3470688
  • 539
  • 6
  • 21

0 Answers0