class LinkNode extends LinkNodeBase implements DoNotLinkDecorate, TextContainer {

    public LinkNode() {
    }

    public LinkNode(BasedSequence chars) {
        super(chars);
    }

    @Override
    public boolean collectText(ISequenceBuilder<? extends ISequenceBuilder<?, BasedSequence>, BasedSequence> out, int flags, NodeVisitor nodeVisitor) {<FILL_FUNCTION_BODY>}
}

        int urlType = flags & F_LINK_TEXT_TYPE;

        BasedSequence url;

        switch (urlType) {
            case F_LINK_PAGE_REF:
                url = getPageRef();
                break;
            case F_LINK_ANCHOR:
                url = getAnchorRef();
                break;
            case F_LINK_URL:
                url = getUrl();
                break;

            case F_LINK_NODE_TEXT:
                url = BasedSequence.NULL; // not used
                break;

            default:
            case F_LINK_TEXT:
                return true;
        }

        if (urlType == F_LINK_NODE_TEXT) {
            out.append(getChars());
        } else {
            ReplacedTextMapper textMapper = new ReplacedTextMapper(url);
            BasedSequence unescaped = Escaping.unescape(url, textMapper);
            BasedSequence percentDecoded = Escaping.percentDecodeUrl(unescaped, textMapper);
            out.append(percentDecoded);
        }

        return false;
    
<methods>public void <init>() ,public void <init>(com.vladsch.flexmark.util.sequence.BasedSequence) ,public com.vladsch.flexmark.util.sequence.BasedSequence getAnchorMarker() ,public com.vladsch.flexmark.util.sequence.BasedSequence getAnchorRef() ,public com.vladsch.flexmark.util.sequence.BasedSequence getPageRef() ,public com.vladsch.flexmark.util.sequence.BasedSequence getTitle() ,public com.vladsch.flexmark.util.sequence.BasedSequence getTitleClosingMarker() ,public com.vladsch.flexmark.util.sequence.BasedSequence getTitleOpeningMarker() ,public com.vladsch.flexmark.util.sequence.BasedSequence getUrl() ,public com.vladsch.flexmark.util.sequence.BasedSequence getUrlClosingMarker() ,public com.vladsch.flexmark.util.sequence.BasedSequence getUrlOpeningMarker() ,public void setAnchorMarker(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setAnchorRef(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setPageRef(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setTitle(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setTitleChars(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setTitleClosingMarker(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setTitleOpeningMarker(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setUrl(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setUrlChars(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setUrlClosingMarker(com.vladsch.flexmark.util.sequence.BasedSequence) ,public void setUrlOpeningMarker(com.vladsch.flexmark.util.sequence.BasedSequence) <variables>protected com.vladsch.flexmark.util.sequence.BasedSequence anchorMarker,protected com.vladsch.flexmark.util.sequence.BasedSequence anchorRef,protected com.vladsch.flexmark.util.sequence.BasedSequence pageRef,protected com.vladsch.flexmark.util.sequence.BasedSequence title,protected com.vladsch.flexmark.util.sequence.BasedSequence titleClosingMarker,protected com.vladsch.flexmark.util.sequence.BasedSequence titleOpeningMarker,protected com.vladsch.flexmark.util.sequence.BasedSequence url,protected com.vladsch.flexmark.util.sequence.BasedSequence urlClosingMarker,protected com.vladsch.flexmark.util.sequence.BasedSequence urlOpeningMarker