Example #1
0
 /// <summary>
 /// Upack the message data into this Generic type.
 /// </summary>
 /// <param name="MessageData">Incoming message data</param>
 public override void unpack(byte[] MessageData)
 {
     //##It would be nice to improve this code a little - NH
     //populate DDMLValue from MessageData
     DDMLValue.setData(MessageData, MessageData.Length, 0);
     for (uint i = 1; i <= DDMLValue.count(); i++) //for each member
     {
         byte[] b = new byte[DDMLValue.item(i).sizeBytes()];
         DDMLValue.getData(ref b);
         Fields[(int)i - 1].unpack(b);       //unpack each field
     }
 }