Here you can find the source of addAttribute(final Element element, final String attributeName, final String value)
public static Element addAttribute(final Element element, final String attributeName, final String value)
//package com.java2s; //License from project: Apache License import org.w3c.dom.Element; public class Main { public static Element addAttribute(final Element element, final String attributeName, final String value) { element.setAttribute(attributeName, value); return element; }/*from ww w.j a va 2s. com*/ }