nu.xom.Element.removeAttribute()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(2.4k)|赞(0)|评价(0)|浏览(155)

本文整理了Java中nu.xom.Element.removeAttribute()方法的一些代码示例,展示了Element.removeAttribute()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Element.removeAttribute()方法的具体详情如下:
包路径:nu.xom.Element
类名称:Element
方法名:removeAttribute

Element.removeAttribute介绍

暂无

代码示例

代码示例来源:origin: concordion/concordion

public void removeAttribute(String name) {
  xomElement.removeAttribute(xomElement.getAttribute(name));
}

代码示例来源:origin: org.jboss.teiid/teiid-engine

/**
 * Delete this node (that is, detach it from its parent)
 */
public void delete() throws XPathException {
  if (parent != null) {
    if (nodeKind == Type.ATTRIBUTE) {
      ((Element) parent.node).removeAttribute((Attribute) node);
    } else {
      ((ParentNode) parent.node).removeChild(node);
    }
  }
}

代码示例来源:origin: org.concordion/concordion

public void removeAttribute(String localName, String namespaceURI) {
  xomElement.removeAttribute(xomElement.getAttribute(localName, namespaceURI));
}

代码示例来源:origin: concordion/concordion

public void removeAttribute(String localName, String namespaceURI) {
  xomElement.removeAttribute(xomElement.getAttribute(localName, namespaceURI));
}

代码示例来源:origin: org.concordion/concordion

public void removeAttribute(String name) {
  xomElement.removeAttribute(xomElement.getAttribute(name));
}

代码示例来源:origin: org.concordion/concordion

public void moveAttributesTo(Element element) {
  for (int i=0; i<xomElement.getAttributeCount(); i++) {
    Attribute attribute = xomElement.getAttribute(i);
    xomElement.removeAttribute(attribute);
    element.xomElement.addAttribute(attribute);
  }
}

代码示例来源:origin: concordion/concordion

public void moveAttributesTo(Element element) {
  for (int i=0; i<xomElement.getAttributeCount(); i++) {
    Attribute attribute = xomElement.getAttribute(i);
    xomElement.removeAttribute(attribute);
    element.xomElement.addAttribute(attribute);
  }
}

代码示例来源:origin: org.xml-cml/cmlxom

void substituteNameByValue(Attribute att) {
  // do not substitute refs
  if (att instanceof RefAttribute) {
  } else {
    String value = att.getValue();
    String value1 = value;
    String newValue = this.getValue().trim();
    if (!newValue.equals(S_EMPTY)) {
      value1 = value1.replaceAll(S_UNDER+this.getName()+S_UNDER, newValue);
      if (!value.equals(value1)) {
        Element parent = (Element) att.getParent();
        // remove attribute so as not to triffer reset error
        parent.removeAttribute(parent.getAttribute(att.getLocalName()));
        att.setValue(value1);
        parent.addAttribute(att);
      } else {
      }
    }
  }
}

代码示例来源:origin: cdk/cdk

if (isotopeInfo != null) element.removeAttribute(isotopeInfo);

代码示例来源:origin: org.openscience.cdk/cdk-pdbcml

if (isotopeInfo != null) element.removeAttribute(isotopeInfo);

相关文章