Code example for Element

Methods: getLocalName

0
	 *            The element. 
	 * @return The element name. 
	 */ 
	public static String getName(Element element)
	{ 
		String name=element.getLocalName();
 
		if(name!=null)
		{ 
			return name;
		} 
		else 
		{ 
			return element.getTagName();
		} 
	} 
 
	/** 
	 * Get attribute value, returning <code>null</code> if unset. 
	 * <p/> 
	 * Some DOM implementations return an empty string for an unset attribute.