Here you can find the source of createRealNodeList(NodeList nodeList)
protected static List<Node> createRealNodeList(NodeList nodeList)
//package com.java2s; // it under the terms of the GNU Lesser General Public License as published by import java.util.LinkedList; import java.util.List; import org.w3c.dom.Node; import org.w3c.dom.NodeList; public class Main { protected static List<Node> createRealNodeList(NodeList nodeList) { List<Node> realNodeList = new LinkedList<Node>(); if (null != nodeList && nodeList.getLength() > 0) { for (int i = 0; i < nodeList.getLength(); ++i) { Node nextNode = nodeList.item(i); realNodeList.add(nextNode); }/*w w w.ja va 2 s.c o m*/ } return realNodeList; } }