Set an Attribute in an Element
import org.w3c.dom.Element;
public class Utils {
/**
* Set an Attribute in an Element
* @param element the containing Element
* @param name the attribute name
* @param value the attribute value
*/
public static void setAttribute(Element element, String name, String value) {
element.setAttribute(name, value);
}
}
Related examples in the same category