public override void ApplySecurityAndWriteHeaders(MessageHeaders headers, XmlDictionaryWriter writer, IPrefixGenerator prefixGenerator)
        {
            string[] headerIds;
            if (RequireMessageProtection || ShouldSignToHeader)
            {
                headerIds = headers.GetHeaderAttributes(UtilityStrings.IdAttribute,
                                                        StandardsManager.IdManager.DefaultIdNamespaceUri);
            }
            else
            {
                headerIds = null;
            }
            for (int i = 0; i < headers.Count; i++)
            {
                MessageHeader header = headers.GetMessageHeader(i);
                if (Version.Addressing == AddressingVersion.None && header.Namespace == AddressingVersion.None.Namespace)
                {
                    continue;
                }

                if (header != this)
                {
                    ApplySecurityAndWriteHeader(header, headerIds == null ? null : headerIds[i], writer, prefixGenerator);
                }
            }
        }
 public override void ApplySecurityAndWriteHeaders(MessageHeaders headers, XmlDictionaryWriter writer, IPrefixGenerator prefixGenerator)
 {
     string[] headerAttributes;
     if (base.RequireMessageProtection || base.ShouldSignToHeader)
     {
         headerAttributes = headers.GetHeaderAttributes("Id", base.StandardsManager.IdManager.DefaultIdNamespaceUri);
     }
     else
     {
         headerAttributes = null;
     }
     for (int i = 0; i < headers.Count; i++)
     {
         MessageHeader messageHeader = headers.GetMessageHeader(i);
         if (((base.Version.Addressing != AddressingVersion.None) || !(messageHeader.Namespace == AddressingVersion.None.Namespace)) && (messageHeader != this))
         {
             this.ApplySecurityAndWriteHeader(messageHeader, (headerAttributes == null) ? null : headerAttributes[i], writer, prefixGenerator);
         }
     }
 }
        public override void ApplySecurityAndWriteHeaders(MessageHeaders headers, XmlDictionaryWriter writer, IPrefixGenerator prefixGenerator)
        {
            string[] headerIds;
            if (this.RequireMessageProtection || this.ShouldSignToHeader)
            {
                headerIds = headers.GetHeaderAttributes(UtilityStrings.IdAttribute,
                    this.StandardsManager.IdManager.DefaultIdNamespaceUri);
            }
            else
            {
                headerIds = null;
            }
            for (int i = 0; i < headers.Count; i++)
            {
                MessageHeader header = headers.GetMessageHeader(i);
                if (this.Version.Addressing == AddressingVersion.None && header.Namespace == AddressingVersion.None.Namespace)
                {
                    continue;
                }

                if (header != this)
                {
                    ApplySecurityAndWriteHeader(header, headerIds == null ? null : headerIds[i], writer, prefixGenerator);
                }
            }
        }
 public override void ApplySecurityAndWriteHeaders(MessageHeaders headers, XmlDictionaryWriter writer, IPrefixGenerator prefixGenerator)
 {
     string[] headerAttributes;
     if (base.RequireMessageProtection || base.ShouldSignToHeader)
     {
         headerAttributes = headers.GetHeaderAttributes("Id", base.StandardsManager.IdManager.DefaultIdNamespaceUri);
     }
     else
     {
         headerAttributes = null;
     }
     for (int i = 0; i < headers.Count; i++)
     {
         MessageHeader messageHeader = headers.GetMessageHeader(i);
         if (((base.Version.Addressing != AddressingVersion.None) || !(messageHeader.Namespace == AddressingVersion.None.Namespace)) && (messageHeader != this))
         {
             this.ApplySecurityAndWriteHeader(messageHeader, (headerAttributes == null) ? null : headerAttributes[i], writer, prefixGenerator);
         }
     }
 }