com.github.easai.text.XML Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of text Show documentation
Show all versions of text Show documentation
A text processing library for JSON, XML, RSS.
package com.github.easai.text;
import java.net.URL;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
public class XML {
/**
* Gets the first Node whose tag name is key.
*
* @param urlStr the URL
* @param key the key
* @return the top Node
*/
public static Node getFirstNode(String urlStr, String key)throws Exception{
Node node=null;
try {
NodeList list=getNodeList(urlStr, key);
if(0
© 2015 - 2025 Weber Informatics LLC | Privacy Policy