use of org.camunda.bpm.model.xml.impl.util.XmlQName in project camunda-xml-model by camunda.
the class DomElementImpl method getAttribute.
public String getAttribute(String namespaceUri, String localName) {
synchronized (document) {
XmlQName xmlQName = new XmlQName(this, namespaceUri, localName);
String value;
if (xmlQName.hasLocalNamespace()) {
value = element.getAttributeNS(null, xmlQName.getLocalName());
} else {
value = element.getAttributeNS(xmlQName.getNamespaceUri(), xmlQName.getLocalName());
}
if (value.isEmpty()) {
return null;
} else {
return value;
}
}
}
use of org.camunda.bpm.model.xml.impl.util.XmlQName in project camunda-xml-model by camunda.
the class DomDocumentImpl method createElement.
public DomElement createElement(String namespaceUri, String localName) {
synchronized (document) {
XmlQName xmlQName = new XmlQName(this, namespaceUri, localName);
Element element = document.createElementNS(xmlQName.getNamespaceUri(), xmlQName.getPrefixedName());
return new DomElementImpl(element);
}
}
Aggregations