markwon-html/src/main/java/ru/noties/markwon/html/jsoup/parser/CharacterReader.java
public String consumeToAny(final char... chars) {
        bufferUp();
        final int start = bufPos;
        final int remaining = bufLength;
        final char[] val = charBuf;

        OUTER:
        while (bufPos < remaining) {
            for (char c : chars) {
                if (val[bufPos] == c)
                    break OUTER;
            }
            bufPos++;
        }

        return bufPos > start ? cacheString(charBuf, stringCache, start, bufPos - start) : "";
    }
public String consumeToAny(final char... chars) {
        bufferUp();
        final int start = bufPos;
        final int remaining = bufLength;
        final char[] val = charBuf;

        OUTER:
        while (bufPos < remaining) {
            for (char c : chars) {
                if (val[bufPos] == c)
                    break OUTER;
            }
            bufPos++;
        }

        return bufPos > start ? cacheString(charBuf, stringCache, start, bufPos - start) : "";
    }
Read characters until the first of any delimiters is found.

@param chars delimiters to scan for
@return characters read up to the matched delimiter.