gpt4 book ai didi

com.opensymphony.util.XMLUtils.print()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-18 11:20:40 24 4
gpt4 key购买 nike

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

XMLUtils.print介绍

[英]Pretty-print a Document back to String of XML.
[中]将文档打印回XML字符串。

代码示例

代码示例来源:origin: com.opensymphony.oscore/com.springsource.com.opensymphony.util

/**
 * Pretty-print a Document to OutputStream.
 */
public final static void print(Document document, OutputStream out) throws IOException {
  print(document, new OutputStreamWriter(out));
}

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

/**
 * Pretty-print a Document to File.
 */
public final static void print(Document document, File file) throws IOException {
  print(document, new FileWriter(file));
}

代码示例来源:origin: com.opensymphony.oscore/com.springsource.com.opensymphony.util

/**
 * Pretty-print a Document to File.
 */
public final static void print(Document document, File file) throws IOException {
  print(document, new FileWriter(file));
}

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

/**
 * Pretty-print a Document to OutputStream.
 */
public final static void print(Document document, OutputStream out) throws IOException {
  print(document, new OutputStreamWriter(out));
}

代码示例来源:origin: com.opensymphony.oscore/com.springsource.com.opensymphony.util

/**
 * Pretty-print a Document back to String of XML.
 */
public final static String print(Document document) throws IOException {
  StringWriter result = new StringWriter();
  print(document, result);
  return result.toString();
}

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

/**
 * Pretty-print a Document back to String of XML.
 */
public final static String print(Document document) throws IOException {
  StringWriter result = new StringWriter();
  print(document, result);
  return result.toString();
}

代码示例来源:origin: com.opensymphony.propertyset/core

/**
* Save properties to XML output.
*/
public void save(OutputStream out) throws ParserConfigurationException, IOException {
  XMLUtils.print(saveToDocument(), out);
}

代码示例来源:origin: com.opensymphony.propertyset/core

/**
* Save properties to XML output.
*/
public void save(Writer out) throws ParserConfigurationException, IOException {
  XMLUtils.print(saveToDocument(), out);
}

代码示例来源:origin: com.opensymphony.propertyset.providers/ejb3

/**
 * Serialize (print) XML document to byte array (as String).
 */
private String writeXML(Document doc)
{
 try
 {
  return XMLUtils.print(doc);
 }
 catch(IOException e)
 {
  throw new PropertyImplementationException("Cannot serialize XML", e);
 }
}

代码示例来源:origin: com.atlassian.cargo-test-runner/cargo-test-runner

/**
 * Convenience method - Use ElectricXML to access the HTML in the response for easy access.
 */
protected Document getDocument( WebResponse rs ) throws IOException, SAXException, ParseException {
  return new Document( new StringReader( XMLUtils.print( rs.getDOM() ) ) );
}

代码示例来源:origin: com.opensymphony.propertyset/core

valueNode = doc.createCDATASection(XMLUtils.print((Document) value));
} catch (IOException ioe) {
  return; // cannot serialize XML - carry on with rest of properties.

代码示例来源:origin: com.opensymphony.propertyset/core

value = XMLUtils.print((Document) valueEntry.getValue());

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com