Search in sources :

Example 1 with Mention

use of com.fastaccess.provider.markdown.extension.mention.Mention in project FastHub by k0shk0sh.

the class MentionDelimiterProcessor method process.

@Override
public void process(Text opener, Text closer, int delimiterCount) {
    Node mention = new Mention();
    Node tmp = opener.getNext();
    while (tmp != null && tmp != closer) {
        Node next = tmp.getNext();
        mention.appendChild(tmp);
        tmp = next;
    }
    opener.insertAfter(mention);
}
Also used : Node(org.commonmark.node.Node) Mention(com.fastaccess.provider.markdown.extension.mention.Mention)

Aggregations

Mention (com.fastaccess.provider.markdown.extension.mention.Mention)1 Node (org.commonmark.node.Node)1