org.apache.axiom.om.OMFactory.createOMProcessingInstruction()方法的使用及代码示例

x33g5p2x  于2022-01-25 转载在 其他  
字(3.2k)|赞(0)|评价(0)|浏览(71)

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

OMFactory.createOMProcessingInstruction介绍

[英]Creates a PI.
[中]创建一个PI。

代码示例

代码示例来源:origin: org.apache.ws.commons.axiom/axiom-impl

protected void createOMProcessingInstruction(OMContainer parent, String piTarget, String piData) {
  factory.createOMProcessingInstruction(parent, piTarget, piData);
}

代码示例来源:origin: org.apache.ws.commons.axiom/om-aspects

protected void createOMProcessingInstruction(OMContainer parent, String piTarget, String piData) {
  factory.createOMProcessingInstruction(parent, piTarget, piData);
}

代码示例来源:origin: org.springframework.ws/org.springframework.ws

public void processingInstruction(String target, String data) throws SAXException {
  OMContainer parent = getParent();
  factory.createOMProcessingInstruction(parent, target, data);
}

代码示例来源:origin: org.ballerinalang/ballerina-core

/**
 * Create a processing instruction type BXML.
 *
 * @param tartget PI target
 * @param data PI data
 * @return BXML Processing instruction type BXML
 */
public static BXML<?> createXMLProcessingInstruction(String tartget, String data) {
  OMProcessingInstruction omText = OM_FACTORY.createOMProcessingInstruction(OM_FACTORY.createOMDocument(),
      tartget, data);
  return new BXMLItem(omText);
}

代码示例来源:origin: org.apache.abdera/abdera-parser

public Document<T> addProcessingInstruction(String target, String value) {
  OMProcessingInstruction pi = this.factory.createOMProcessingInstruction(null, target, value);
  if (this.getOMDocumentElement() != null) {
    this.getOMDocumentElement().insertSiblingBefore(pi);
  } else {
    this.addChild(pi);
  }
  return this;
}

代码示例来源:origin: org.apache.abdera/abdera-parser

public Object clone() {
    Document<T> doc = ((FOMFactory)factory).newDocument();
    OMDocument omdoc = (OMDocument)doc;
    for (Iterator i = getChildren(); i.hasNext();) {
      OMNode node = (OMNode)i.next();
      switch (node.getType()) {
        case OMNode.COMMENT_NODE:
          OMComment comment = (OMComment)node;
          factory.createOMComment(omdoc, comment.getValue());
          break;
        // TODO: Decide what to do with this code; it will no longer work in Axiom 1.2.14 (because of AXIOM-437).
        //       On the other hand, since we filter out DTDs, this code is never triggered.
//                case OMNode.DTD_NODE:
//                    OMDocType doctype = (OMDocType)node;
//                    factory.createOMDocType(omdoc, doctype.getValue());
//                    break;
        case OMNode.ELEMENT_NODE:
          Element el = (Element)node;
          omdoc.addChild((OMNode)el.clone());
          break;
        case OMNode.PI_NODE:
          OMProcessingInstruction pi = (OMProcessingInstruction)node;
          factory.createOMProcessingInstruction(omdoc, pi.getTarget(), pi.getValue());
          break;
      }
    }
    return doc;
  }

代码示例来源:origin: org.apache.abdera/abdera-parser

} else if (node.getType() == OMNode.PI_NODE) {
  OMProcessingInstruction pi = (OMProcessingInstruction)node;
  factory.createOMProcessingInstruction(dest, pi.getTarget(), pi.getValue());
} else if (node.getType() == OMNode.SPACE_NODE) {
  OMText text = (OMText)node;

代码示例来源:origin: org.bluestemsoftware.open.eoa.ext/open-eoa-aspect-axiom

OMProcessingInstruction importedPI = (OMProcessingInstruction) child;
OMProcessingInstruction newPI = this.factory
    .createOMProcessingInstruction(this,
                    importedPI.getTarget(),
                    importedPI.getValue());

相关文章