Java XML Attribute from Element getStringAttributeValue(final Element element, final String attributeName)

Here you can find the source of getStringAttributeValue(final Element element, final String attributeName)

Description

get String Attribute Value

License

Open Source License

Declaration

public static String getStringAttributeValue(final Element element, final String attributeName) 

Method Source Code

//package com.java2s;

import org.w3c.dom.Element;

public class Main {
    /**//  w ww  . j  ava  2 s  . co m
     * @see #getDoubleAttributeValue(Element, String)
     */
    public static String getStringAttributeValue(final Element element, final String attributeName) {
        if (null == element) {
            return null;
        }
        final String str = element.getAttribute(attributeName);
        return str;
    }
}

Related

  1. getIntegerAttribute(Element element, String name)
  2. getStringAttr(Element element, String name, String def)
  3. getStringAttribute(Element e, String name, String def)
  4. getStringAttribute(Element el, String attribute)
  5. getStringAttributeValue(Element element, String attribute)
  6. getStringAttributeValue(final Element element, final String attributeName)
  7. getTagAttribute(String sTag, String sAtt, Element eElement)
  8. getTagAttribute(XMLStreamReader xmler, String attribute, String defaultValue)
  9. getTagAttributeRecursive(String sTag, String sAtt, Element eElement)