/** * Set an Android-namespaced XML attribute on the given node. * * @param node Node in which to set the attribute; must be part of a document * @param localName Non-prefixed attribute name * @param value value of the attribute */ private static void setAndroidAttribute(Element node, String localName, String value) { String prefix = findOrInstallNamespacePrefix(node, SdkConstants.ANDROID_URI, SdkConstants.ANDROID_NS_NAME); node.setAttributeNS(SdkConstants.ANDROID_URI, prefix + ":" + localName, value); }