System.Xml.Xsl.XsltOld.SequentialOutput.WriteAttributes C# (CSharp) Method

WriteAttributes() private method

private WriteAttributes ( ArrayList list, int count, HtmlElementProps htmlElementsProps ) : void
list System.Collections.ArrayList
count int
htmlElementsProps HtmlElementProps
return void
        private void WriteAttributes(ArrayList list, int count, HtmlElementProps htmlElementsProps) {
            Debug.Assert(count <= list.Count);
            for (int attrib = 0; attrib < count; attrib ++) {
                Debug.Assert(list[attrib] is BuilderInfo);
                BuilderInfo attribute = (BuilderInfo) list[attrib];
                string attrValue = attribute.Value;
                bool abr = false, uri = false; {
                    if(htmlElementsProps != null && attribute.Prefix.Length == 0) {
                        HtmlAttributeProps htmlAttrProps = attribute.htmlAttrProps;
                        if (htmlAttrProps == null && attribute.search) {
                            htmlAttrProps = HtmlAttributeProps.GetProps(attribute.LocalName);
                        }
                        if(htmlAttrProps != null) {
                            abr = htmlElementsProps.AbrParent  && htmlAttrProps.Abr;
                            uri = htmlElementsProps.UriParent  && ( htmlAttrProps.Uri ||
								  htmlElementsProps.NameParent && htmlAttrProps.Name
							);
                        }
                    }
                }
                Write(s_Space);
                WriteName(attribute.Prefix, attribute.LocalName);
                if(abr && 0 == string.Compare(attribute.LocalName, attrValue, StringComparison.OrdinalIgnoreCase) ) {
                    // Since the name of the attribute = the value of the attribute, 
                    // this is a boolean attribute whose value should be suppressed
                    continue; 
                }
                Write(s_EqualQuote);
                if(uri) {
                    WriteHtmlUri(attrValue);
                }
                else if(this.isHtmlOutput) {
                    WriteHtmlAttributeValue(attrValue);
                }
                else {
                    WriteXmlAttributeValue(attrValue);
                }
                Write(s_Quote);
            }
        }