private void AddDescendantAttributes(XMLList list, XML target)
{
if (target.IsElement())
{
AddMatchingAttributes(list, target);
XML[] children = target.GetChildren();
for (int i = 0; i < children.Length; i++)
{
AddDescendantAttributes(list, children[i]);
}
}
}