Here you can find the source of getAttributeValue(NamedNodeMap attributes, String name)
private static String getAttributeValue(NamedNodeMap attributes, String name)
//package com.java2s; /************************************************************************************* * Copyright (c) 2008-2011 Red Hat, Inc. and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * // w w w . ja v a 2 s.c om * Contributors: * JBoss by Red Hat - Initial implementation. ************************************************************************************/ import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; public class Main { private static String getAttributeValue(NamedNodeMap attributes, String name) { String value = null; Node node = attributes.getNamedItem(name); if (node != null) { value = node.getNodeValue(); } return value; } }