Java tutorial
//package com.java2s; import org.w3c.dom.*; public class Main { public static String getPath(Node node) { NamedNodeMap nodeMap = node.getAttributes(); Node pathNode = nodeMap.getNamedItem("path"); if (pathNode != null) { return pathNode.getNodeValue(); } else return null; } }