MatchName(nsIContent *aContent, const nsString& aName)
MatchName(nsIContent *aContent, const nsAReadableString& aName)
MatchName(nsIContent *aContent, const nsString& aName){  nsAutoString value;  nsIContent *result = nsnull;  PRInt32 ns;  aContent->GetNameSpaceID(ns);  if (kNameSpaceID_HTML == ns) {    if ((NS_CONTENT_ATTR_HAS_VALUE == aContent->GetAttribute(kNameSpaceID_None, nsHTMLAtoms::id, value)) &&        aName.Equals(value)) {      return aContent;    }    else if ((NS_CONTENT_ATTR_HAS_VALUE == aContent->GetAttribute(kNameSpaceID_None, nsHTMLAtoms::name, value)) &&             aName.Equals(value)) {      return aContent;    }  }    PRInt32 i, count;  aContent->ChildCount(count);  for (i = 0; i < count && result == nsnull; i++) {    nsIContent *child;    aContent->ChildAt(i, child);    result = MatchName(child, aName);    NS_RELEASE(child);  }    return result;}