for (int i = 0; i < sourceChildren.getLength(); i++)
{
org.w3c.dom.Node child = sourceChildren.item(i);
if (child.getNodeType() != org.w3c.dom.Node.TEXT_NODE)
{
Node newTarget = target.create(child.getNodeName());
if (onlyTextChildren(child))
{
newTarget.text(child.getTextContent());
readAttributes(newTarget, child);
}
else
{
readRecursive(newTarget, child);