private void handleWriteLimitReached() throws WriteLimitReachedException {
        writeLimitReached = true;
        writeCount = writeLimit;
        if (throwOnWriteLimitReached) {
            throw new WriteLimitReachedException(writeLimit);
        } else {
            ParseRecord parseRecord = parseContext.get(ParseRecord.class);
            if (parseRecord != null) {
                parseRecord.setWriteLimitReached(true);
            }
        }
    }
Writes the given characters to the given character stream.
tika-core/src/main/java/org/apache/tika/sax/WriteOutContentHandler.java