public static Parser tryToFindExistingLeafParser(Class clazz, ParseContext context) {
        Parser p = context.get(Parser.class);
        if (equals(p, clazz)) {
            return p;
        }
        Parser returnParser = null;
        if (p != null) {
            if (p instanceof ParserDecorator) {
                p = findInDecorated((ParserDecorator) p, clazz);
            }
            if (equals(p, clazz)) {
                return p;
            }
            if (p instanceof CompositeParser) {
                returnParser = findInComposite((CompositeParser) p, clazz, context);
            }
        }
        if (returnParser != null && equals(returnParser, clazz)) {
            return returnParser;
        }

        return null;
    }
Tries to find an existing parser within the ParseContext.
It looks inside of CompositeParsers and ParserDecorators.
The use case is when a parser needs to parse an internal stream
that is _part_ of the document, e.g. rtf body inside an msg.
<p/>
Can return <code>null</code> if the context contains no parser or
the correct parser can't be found.

@param clazz   parser class to search for
@param context
@return
tika-core/src/main/java/org/apache/tika/extractor/EmbeddedDocumentUtil.java