/// <summary>
        /// Parse the RecipientRow structure.
        /// </summary>
        /// <param name="s">A stream containing the RecipientRow structure</param>
        public override void Parse(Stream s)
        {
            base.Parse(s);
            this.RecipientFlags = new RecipientFlags();
            this.RecipientFlags.Parse(s);
            if (this.RecipientFlags.Type == AddressTypeEnum.X500DN)
            {
                this.AddressPrefixUsed = ReadByte();
                this.DisplayType = (DisplayType)ReadByte();
                this.X500DN = new MAPIString(Encoding.ASCII);
                this.X500DN.Parse(s);

            }
            else if (this.RecipientFlags.Type == AddressTypeEnum.PersonalDistributionList1 || this.RecipientFlags.Type == AddressTypeEnum.PersonalDistributionList2)
            {
                this.EntryIdSize = ReadUshort();
                this.EntryID = new AddressBookEntryID();
                this.EntryID.Parse(s);
                this.SearchKeySize = ReadUshort();
                this.SearchKey = ConvertArray(ReadBytes((int)this.SearchKeySize));
            }
            else if (this.RecipientFlags.Type == AddressTypeEnum.NoType && this.RecipientFlags.O == 0x1)
            {
                this.AddressType = new MAPIString(Encoding.ASCII);
                this.AddressType.Parse(s);

            }

            if (RecipientFlags.E == 0x1)
            {
                this.EmailAddress = new MAPIString((RecipientFlags.U == 0x1) ? Encoding.Unicode : Encoding.ASCII);
                this.EmailAddress.Parse(s);

            }

            if (RecipientFlags.D == 0x1)
            {
                this.DisplayName = new MAPIString((RecipientFlags.U == 0x1) ? Encoding.Unicode : Encoding.ASCII);
                this.DisplayName.Parse(s);

            }

            if (RecipientFlags.I == 0x1)
            {
                this.SimpleDisplayName = new MAPIString((RecipientFlags.U == 0x1) ? Encoding.Unicode : Encoding.ASCII);
                this.SimpleDisplayName.Parse(s);
            }

            if (RecipientFlags.T == 0x1)
            {
                this.TransmittableDisplayName = new MAPIString((RecipientFlags.U == 0x1) ? Encoding.Unicode : Encoding.ASCII);
                this.TransmittableDisplayName.Parse(s);
            }
            this.RecipientColumnCount = ReadUshort();
            PropertyRow tempPropertyRow = new PropertyRow(PropTags);
            this.RecipientProperties = tempPropertyRow;
            this.RecipientProperties.Parse(s);
        }
        /// <summary>
        /// Parse the RopFindRowResponse structure.
        /// </summary>
        /// <param name="s">An stream containing RopFindRowResponse structure.</param>
        public override void Parse(Stream s)
        {
            base.Parse(s);

            this.RopId = (RopIdType)ReadByte();
            this.InputHandleIndex = ReadByte();
            HelpMethod help = new HelpMethod();
            this.ReturnValue = help.FormatErrorCode(ReadUint());

            if ((ErrorCodes)ReturnValue == ErrorCodes.Success)
            {
                this.RowNoLongerVisible = ReadBoolean();
                this.HasRowData = ReadBoolean();
                if ((bool)HasRowData)
                {
                    PropertyRow tempPropertyRow = new PropertyRow(propertiesBySetColum);
                    this.RowData = tempPropertyRow;
                    this.RowData.Parse(s);
                }
            }
        }
        /// <summary>
        /// Parse the RopExpandRowResponse structure.
        /// </summary>
        /// <param name="s">An stream containing RopExpandRowResponse structure.</param>
        public override void Parse(Stream s)
        {
            base.Parse(s);

            this.RopId = (RopIdType)ReadByte();
            this.InputHandleIndex = ReadByte();
            HelpMethod help = new HelpMethod();
            this.ReturnValue = help.FormatErrorCode(ReadUint());

            if ((ErrorCodes)ReturnValue == ErrorCodes.Success)
            {
                this.ExpandedRowCount = ReadUint();
                this.RowCount = ReadUshort();
                List<PropertyRow> tempPropertyRows = new List<PropertyRow>();
                for (int i = 0; i < RowCount; i++)
                {
                    PropertyRow tempPropertyRow = new PropertyRow(this.propertiesBySetColum);
                    tempPropertyRow.Parse(s);
                    tempPropertyRows.Add(tempPropertyRow);
                }
                this.RowData = tempPropertyRows.ToArray();
            }
        }
        /// <summary>
        /// Parse the RopGetReceiveFolderTableResponse structure.
        /// </summary>
        /// <param name="s">An stream containing RopGetReceiveFolderTableResponse structure.</param>
        public override void Parse(Stream s)
        {
            base.Parse(s);

            this.RopId = (RopIdType)ReadByte();
            this.InputHandleIndex = ReadByte();
            List<PropertyRow> TmpRows = new List<PropertyRow>();
            HelpMethod help = new HelpMethod();
            this.ReturnValue = help.FormatErrorCode(ReadUint());
            if ((ErrorCodes)ReturnValue == ErrorCodes.Success)
            {
                this.RowCount = ReadUint();

                for (int i = 0; i < this.RowCount; i++)
                {
                    // PidTagMessageClass is defined as PtypString8 due to Open Specification said all characters in this property MUST be from the
                    // ASCII characters 0x20 through 0x7F.
                    PropertyTag[] Properties_GetReceiveFolderTable = new PropertyTag[3]
                    { new PropertyTag(PropertyDataType.PtypInteger64, PidTagPropertyEnum.PidTagFolderId),
                      new PropertyTag(PropertyDataType.PtypString8, PidTagPropertyEnum.PidTagMessageClass),
                      new PropertyTag(PropertyDataType.PtypTime, PidTagPropertyEnum.PidTagLastModificationTime)
                    };
                    PropertyRow ProRow = new PropertyRow(Properties_GetReceiveFolderTable);
                    ProRow.Parse(s);
                    TmpRows.Add(ProRow);
                }
                this.Rows = TmpRows.ToArray();
            }
        }
        /// <summary>
        /// Parse the NotificationData structure.
        /// </summary>
        /// <param name="s">An stream containing NotificationData structure.</param>
        public override void Parse(Stream s)
        {
            base.Parse(s);
            this.NotificationFlags = new NotificationFlags();
            this.NotificationFlags.Parse(s);
            if (this.NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified)
            {
                this.TableEventType = (TableEventTypeEnum)ReadUshort();
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowDeleted || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.TableRowFolderID = new FolderID();
                this.TableRowFolderID.Parse(s);
            }
            if ((((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) != 0) && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowDeleted || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.TableRowMessageID = new MessageID();
                this.TableRowMessageID.Parse(s);
            }
            if ((((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) != 0) && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowDeleted || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.TableRowInstance = ReadUint();
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.InsertAfterTableRowFolderID = new FolderID();
                this.InsertAfterTableRowFolderID.Parse(s);
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified && (((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) != 0) && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.InsertAfterTableRowID = new MessageID();
                this.InsertAfterTableRowID.Parse(s);
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified && (((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) != 0) && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.InsertAfterTableRowInstance = ReadUint();
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                this.TableRowDataSize = ReadUshort();
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.TableModified && (TableEventType == TableEventTypeEnum.TableRowAdded || TableEventType == TableEventTypeEnum.TableRowModified))
            {
                if (DecodingContext.SetColumnProTagMap_Handle != null && DecodingContext.SetColumnProTagMap_Handle.ContainsKey(this.NotificationHandle) )
                {
                    propertiesBySetColum = DecodingContext.SetColumnProTagMap_Handle[this.NotificationHandle];
                }
                else
                {
                    throw new MissingInformationException("Missing PropertyTags information for RopNotifyResponse", (ushort)RopIdType.RopNotify, new uint[] {0,NotificationHandle });
                }
                this.TableRowData = new PropertyRow(propertiesBySetColum);
                this.TableRowData.Parse(s);
            }
            if (NotificationFlags.Value.NotificationType != NotificationTypesEnum.TableModified && NotificationFlags.Value.NotificationType != NotificationTypesEnum.Extended)
            {

                this.FolderId = new FolderID();
                this.FolderId.Parse(s);
            }
            if (NotificationFlags.Value.NotificationType != NotificationTypesEnum.TableModified && NotificationFlags.Value.NotificationType != NotificationTypesEnum.Extended && (((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) != 0))
            {
                this.MessageId = new MessageID();
                this.MessageId.Parse(s);
            }
            if ((NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectCreated || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectDeleted || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectMoved || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectCopied) && ((((int)NotificationFlags.Value.NotificationDataAvailability) & 0xC000) == 0xC000 || (((int)NotificationFlags.Value.NotificationDataAvailability) & 0xC000) == 0))
            {
                this.ParentFolderId = new FolderID();
                this.ParentFolderId.Parse(s);
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectMoved || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectCopied)
            {

                this.OldFolderId = new FolderID();
                this.OldFolderId.Parse(s);
            }
            if ((NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectMoved || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectCopied) && (((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) != 0))
            {
                this.OldMessageId = new MessageID();
                this.OldMessageId.Parse(s);
            }
            if ((NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectMoved || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectCopied) && (((int)NotificationFlags.Value.NotificationDataAvailability & 0x8000) == 0))
            {
                this.OldParentFolderId = new MessageID();
                this.OldParentFolderId.Parse(s);
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectCreated || NotificationFlags.Value.NotificationType == NotificationTypesEnum.ObjectModified)
            {
                this.TagCount = ReadUshort();
                if (TagCount != 0x0000 && TagCount != 0xFFFF)
                {
                    List<PropertyTag> listTags = new List<PropertyTag>();
                    for (int i = 0; i < this.TagCount; i++)
                    {
                        PropertyTag tempTag = new PropertyTag();
                        tempTag.Parse(s);
                        listTags.Add(tempTag);
                    }
                    this.Tags = listTags.ToArray();
                }
            }
            if (((int)NotificationFlags.Value.NotificationDataAvailability & 0x1000) != 0)
            {
                this.TotalMessageCount = ReadUint();
            }
            if (((int)NotificationFlags.Value.NotificationDataAvailability & 0x2000) != 0)
            {
                this.UnreadMessageCount = ReadUint();
            }
            if (NotificationFlags.Value.NotificationType == NotificationTypesEnum.NewMail)
            {
                this.MessageFlags = ReadUint();
                this.UnicodeFlag = ReadByte();
                this.MessageClass = new MAPIString(Encoding.ASCII);
                this.MessageClass.Parse(s);
            }
        }
        /// <summary>
        /// Parse the RopGetPropertiesSpecificResponse structure.
        /// </summary>
        /// <param name="s">An stream containing RopGetPropertiesSpecificResponse structure.</param>
        public override void Parse(Stream s)
        {
            base.Parse(s);

            this.RopId = (RopIdType)ReadByte();
            this.InputHandleIndex = ReadByte();
            HelpMethod help = new HelpMethod();
            this.ReturnValue = help.FormatErrorCode(ReadUint());
            if ((ErrorCodes)ReturnValue == ErrorCodes.Success)
            {
                this.RowData = new PropertyRow(DecodingContext.GetPropertiesSpec_propertyTags[MapiInspector.MAPIInspector.currentParsingSessionID][this.InputHandleIndex]);
                this.RowData.Parse(s);
            }
        }