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

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

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

Element.setNamespaceURI介绍

暂无

代码示例

代码示例来源:origin: resteasy/Resteasy

  1. public static byte[] createPermissionsXml(Permission... permissions) {
  2. final Element permissionsElement = new Element("permissions");
  3. permissionsElement.setNamespaceURI("http://xmlns.jcp.org/xml/ns/javaee");
  4. permissionsElement.addAttribute(new Attribute("version", "7"));
  5. for (Permission permission : permissions) {

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

  1. /** override setNamespaceURI(String namespaceURI) to make it immutable.
  2. * if namespaceURI is not set, sets it, else no-op
  3. * @param namespaceURI
  4. */
  5. public void setNamespaceURI(String namespaceURI) {
  6. String nURI = this.getNamespaceURI();
  7. if (nURI == null) {
  8. super.setNamespaceURI(namespaceURI);
  9. }
  10. }

代码示例来源:origin: zanata/zanata-platform

  1. /**
  2. * Supported children are currently {@code <prop>} and {@code <note>}.
  3. *
  4. * @param child
  5. * @param childrenXml
  6. */
  7. private static void addChildIfSupported(Element child,
  8. Builder<String> childrenXml) {
  9. String uri = child.getNamespaceURI();
  10. String name = child.getLocalName();
  11. if (inTmxNamespace(uri)
  12. && (name.equals("prop") || name.equals("note"))) {
  13. Element copy = (Element) child.copy();
  14. copy.setNamespacePrefix("");
  15. copy.setNamespaceURI("");
  16. childrenXml.add(copy.toXML());
  17. }
  18. }

代码示例来源:origin: wildfly/wildfly-core

  1. public static byte[] createPermissionsXml(Permission... permissions) {
  2. final Element permissionsElement = new Element("permissions");
  3. permissionsElement.setNamespaceURI("http://xmlns.jcp.org/xml/ns/javaee");
  4. permissionsElement.addAttribute(new Attribute("version", "7"));
  5. for (Permission permission : permissions) {

代码示例来源:origin: org.wildfly/wildfly-testsuite-shared

  1. public static Asset createPermissionsXmlAsset(Permission... permissions) {
  2. final Element permissionsElement = new Element("permissions");
  3. permissionsElement.setNamespaceURI("http://xmlns.jcp.org/xml/ns/javaee");
  4. permissionsElement.addAttribute(new Attribute("version", "7"));
  5. for (Permission permission : permissions) {

相关文章