gpt4 book ai didi

net.sf.okapi.common.XMLWriter.writeLineBreak()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-27 04:41:05 29 4
gpt4 key购买 nike

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

XMLWriter.writeLineBreak介绍

[英]Writes a line-break, and if the writer is in a start tag, close it before.
[中]写入换行符,如果写入程序位于开始标记中,请在之前将其关闭。

代码示例

代码示例来源:origin: net.sf.okapi.lib/okapi-lib-persistence

@Override
protected void startWriting(OutputStream outStream) {		
  //this.outStream = outStream;
  prWriter = new PrintWriter(outStream);
  writer = new XMLWriter(prWriter);
  writer.writeStartDocument();
  writer.writeStartElement("body");
  writer.writeLineBreak();
}

代码示例来源:origin: net.sf.okapi/okapi-core

/**
 * Writes the start of a XHTML document, including the head and start of body element.
 * @param title the title of the document (can be null).
 */
public void writeStartHTMLDocument (String title) {
    write("<html>"+lineBreak);
    
    write("<head>"+lineBreak);
    write("<meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">"+lineBreak);
    if ( title != null ) {
      writeElementString("title", title);
      writeLineBreak();
    }
    write("</head>"+lineBreak);
}

代码示例来源:origin: net.sf.okapi/okapi-core

/**
 * Writes the start of a &lt;group&gt; element.
 * @see #writeEndGroup()
 */
public void writeStartGroup (StartGroup resource) {
  if ( !inFile ) {
    writeStartFile(original, dataType, skeletonPath, fwConfigId, fwInputEncoding, null);
  }
  String id = resource.getId();
  String resName = resource.getName();
  String resType = resource.getType();
  writer.writeStartElement("group");
  writer.writeAttributeString("id", id);
  if ( !Util.isEmpty(resName) ) {
    writer.writeAttributeString("resname", resName);
  }
  if ( !Util.isEmpty(resType) ) {
    if ( resType.startsWith("x-") || ( RESTYPEVALUES.contains(";"+resType+";")) ) {
      writer.writeAttributeString("restype", resType);
    }
    else { // Make sure the value is valid
      writer.writeAttributeString("restype", "x-"+resType);
    }
  }
  writeAnnotatorsRefIfNeeded();
  writeSizeProperties(writer, resource);
  writer.writeLineBreak();
}

代码示例来源:origin: net.sf.okapi.steps/okapi-step-rainbowkit

report.writeStartDocument();
report.writeRawXML("<h1>Transifex Package Summary</h1>");
report.writeLineBreak();
report.writeRawXML(String.format("<p>Resources uploaded to Transifex in the project "
  + "<b><a target='_blank' href='%s'>%s</a></b></p>",
  options.getServerWithoutAPI() + "projects/p/" + options.getProjectId() + "/",
  options.getProjectName()));
report.writeLineBreak();
report.writeRawXML("<table border='1' cellspacing='0' cellpadding='5'>");
report.writeRawXML("<tr><th>Transifex Resource</th><th>Original Source File</th></tr>");
report.writeLineBreak();
    resourceFile));
  report.writeRawXML(String.format("<td>%s</td></tr>", info.getRelativeInputPath()));
  report.writeLineBreak();

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeLineBreak();
  writer.writeComment(message, false);
writer.writeLineBreak();

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeLineBreak();
writer.writeStartElement("prop");
writer.writeAttributeString("type", name);
writer.writeLineBreak();

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeAttributeString("tuid", tuid);
writer.writeLineBreak();

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeLineBreak();

代码示例来源:origin: net.sf.okapi.lib/okapi-lib-segmentation

writer.writeLineBreak();
writer.writeAttributeString("segmentsubflows", (segmentSubFlows ? "yes" : "no"));
writer.writeAttributeString("cascade", (cascade ? "yes" : "no"));
writer.writeLineBreak();
writer.writeLineBreak();
writer.writeLineBreak();
for (String ruleName : langRules.keySet()) {
  writer.writeStartElement("languagerule");
  writer.writeAttributeString("languagerulename", ruleName);
  writer.writeLineBreak();
  ArrayList<Rule> langRule = langRules.get(ruleName);
  for (Rule rule : langRule) {
    writer.writeLineBreak();
    writer.writeElementString("beforebreak", rule.before);
    writer.writeLineBreak();
    writer.writeElementString("afterbreak", rule.after);
    writer.writeLineBreak();
writer.writeLineBreak();
for (LanguageMap langMap : langMaps) {
  writer.writeStartElement("languagemap");

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeLineBreak();
writer.writeLineBreak();

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeLineBreak();

代码示例来源:origin: net.sf.okapi/okapi-core

writer.writeLineBreak();

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