org.commonmark.node.Node.appendChild()方法的使用及代码示例

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

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

Node.appendChild介绍

暂无

代码示例

代码示例来源:origin: atlassian/commonmark-java

  1. private void appendNode(Node node) {
  2. block.appendChild(node);
  3. }

代码示例来源:origin: atlassian/commonmark-java

  1. @Override
  2. public void process(Text opener, Text closer, int delimiterCount) {
  3. // Wrap nodes between delimiters in strikethrough.
  4. Node strikethrough = new Strikethrough();
  5. Node tmp = opener.getNext();
  6. while (tmp != null && tmp != closer) {
  7. Node next = tmp.getNext();
  8. strikethrough.appendChild(tmp);
  9. tmp = next;
  10. }
  11. opener.insertAfter(strikethrough);
  12. }
  13. }

代码示例来源:origin: atlassian/commonmark-java

  1. @Override
  2. public void process(Text opener, Text closer, int delimiterCount) {
  3. // Wrap nodes between delimiters in ins.
  4. Node ins = new Ins();
  5. Node tmp = opener.getNext();
  6. while (tmp != null && tmp != closer) {
  7. Node next = tmp.getNext();
  8. ins.appendChild(tmp);
  9. tmp = next;
  10. }
  11. opener.insertAfter(ins);
  12. }
  13. }

代码示例来源:origin: atlassian/commonmark-java

  1. @Override
  2. public void process(Text opener, Text closer, int delimiterUse) {
  3. String singleDelimiter = String.valueOf(getOpeningCharacter());
  4. Node emphasis = delimiterUse == 1
  5. ? new Emphasis(singleDelimiter)
  6. : new StrongEmphasis(singleDelimiter + singleDelimiter);
  7. Node tmp = opener.getNext();
  8. while (tmp != null && tmp != closer) {
  9. Node next = tmp.getNext();
  10. emphasis.appendChild(tmp);
  11. tmp = next;
  12. }
  13. opener.insertAfter(emphasis);
  14. }
  15. }

代码示例来源:origin: atlassian/commonmark-java

  1. section.appendChild(tableRow);

代码示例来源:origin: atlassian/commonmark-java

  1. while (node != null) {
  2. Node next = node.getNext();
  3. linkOrImage.appendChild(node);
  4. node = next;

代码示例来源:origin: com.atlassian.commonmark/commonmark

  1. private void appendNode(Node node) {
  2. block.appendChild(node);
  3. }

代码示例来源:origin: org.symphonyoss.symphony/messageml

  1. /**
  2. * Traverse the element and its children to construct its representation as a Markdown tree.
  3. */
  4. void buildMarkdown(Node parent) throws InvalidInputException {
  5. for (Element child : this.children) {
  6. Node node = child.asMarkdown();
  7. if (node != null) {
  8. parent.appendChild(node);
  9. } else {
  10. node = parent;
  11. }
  12. child.buildMarkdown(node);
  13. }
  14. }

代码示例来源:origin: com.atlassian.commonmark/commonmark-ext-gfm-strikethrough

  1. @Override
  2. public void process(Text opener, Text closer, int delimiterCount) {
  3. // Wrap nodes between delimiters in strikethrough.
  4. Node strikethrough = new Strikethrough();
  5. Node tmp = opener.getNext();
  6. while (tmp != null && tmp != closer) {
  7. Node next = tmp.getNext();
  8. strikethrough.appendChild(tmp);
  9. tmp = next;
  10. }
  11. opener.insertAfter(strikethrough);
  12. }
  13. }

代码示例来源:origin: com.atlassian.commonmark/commonmark

  1. @Override
  2. public void process(Text opener, Text closer, int delimiterUse) {
  3. String singleDelimiter = String.valueOf(getOpeningCharacter());
  4. Node emphasis = delimiterUse == 1
  5. ? new Emphasis(singleDelimiter)
  6. : new StrongEmphasis(singleDelimiter + singleDelimiter);
  7. Node tmp = opener.getNext();
  8. while (tmp != null && tmp != closer) {
  9. Node next = tmp.getNext();
  10. emphasis.appendChild(tmp);
  11. tmp = next;
  12. }
  13. opener.insertAfter(emphasis);
  14. }
  15. }

代码示例来源:origin: com.atlassian.commonmark/commonmark-ext-gfm-tables

  1. section.appendChild(tableRow);

代码示例来源:origin: com.atlassian.commonmark/commonmark

  1. while (node != null) {
  2. Node next = node.getNext();
  3. linkOrImage.appendChild(node);
  4. node = next;

相关文章