Here you can find the source of firstChildNodeWithName(org.w3c.dom.Node node, String name)
static public org.w3c.dom.Node firstChildNodeWithName(org.w3c.dom.Node node, String name)
//package com.java2s; /* J_LZ_COPYRIGHT_BEGIN ******************************************************* * Copyright 2006-2008 Laszlo Systems, Inc. All Rights Reserved. * * Use is subject to license terms. * * J_LZ_COPYRIGHT_END *********************************************************/ public class Main { static public org.w3c.dom.Node firstChildNodeWithName(org.w3c.dom.Node node, String name) { org.w3c.dom.Node foundNode = null; org.w3c.dom.NodeList childNodes = node.getChildNodes(); final int n = childNodes.getLength(); for (int i = 0; i < n; i++) { org.w3c.dom.Node childNode = childNodes.item(i); if (childNode.getNodeName().equals(name)) { foundNode = childNode;/*from w w w .j a va 2 s . c o m*/ break; } } return foundNode; } }