/// <summary> /// This method supports the Fluorine infrastructure and is not intended to be used directly from your code. /// </summary> /// <returns></returns> public AMFMessage ReadAMFMessage() { // Version stored in the first two bytes. ushort version = base.ReadUInt16(); AMFMessage message = new AMFMessage(version); // Read header count. int headerCount = base.ReadUInt16(); for (int i = 0; i < headerCount; i++) { message.AddHeader(this.ReadHeader()); } // Read header count. int bodyCount = base.ReadUInt16(); for (int i = 0; i < bodyCount; i++) { AMFBody amfBody = this.ReadBody(); if (amfBody != null) //not failed { message.AddBody(amfBody); } } return(message); }
/// <summary> /// This method supports the Fluorine infrastructure and is not intended to be used directly from your code. /// </summary> /// <returns></returns> public AMFMessage ReadAMFMessage() { // Version stored in the first two bytes. var version = ReadUInt16(); var message = new AMFMessage(version); // Read header count. int headerCount = ReadUInt16(); for (var i = 0; i < headerCount; i++) { message.AddHeader(ReadHeader()); } // Read header count. int bodyCount = ReadUInt16(); for (var i = 0; i < bodyCount; i++) { var amfBody = ReadBody(); if (amfBody != null) //not failed { message.AddBody(amfBody); } } return(message); }
public AMFMessage ReadAMFMessage() { int num3; AMFMessage message = new AMFMessage(base.ReadUInt16()); int num2 = base.ReadUInt16(); for (num3 = 0; num3 < num2; num3++) { message.AddHeader(this.ReadHeader()); } int num4 = base.ReadUInt16(); for (num3 = 0; num3 < num4; num3++) { AMFBody body = this.ReadBody(); if (body != null) { message.AddBody(body); } } return(message); }