private static POIXMLTextExtractor tryXSLF(OPCPackage pkg, boolean eventBased)
            throws TikaException, XmlException, OpenXML4JException, IOException {

        PackageRelationshipCollection packageRelationshipCollection = pkg.getRelationshipsByType(
                "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument");
        if (packageRelationshipCollection.size() == 0) {
            packageRelationshipCollection = pkg.getRelationshipsByType(
                    "http://purl.oclc.org/ooxml/officeDocument/relationships/officeDocument");
        }

        if (packageRelationshipCollection.size() == 0) {
            return null;
        }
        PackagePart corePart = pkg.getPart(packageRelationshipCollection.getRelationship(0));
        if (corePart == null) {
            throw new TikaException("Couldn't find core part");
        }
        String targetContentType = corePart.getContentType();

        for (int i = 0; i < XSLF_RELATIONS.length; i++) {
            XSLFRelation xslfRelation = XSLF_RELATIONS[i];
            if (xslfRelation.getContentType().equals(targetContentType)) {
                if (eventBased) {
                    return new XSLFEventBasedPowerPointExtractor(pkg);
                } else {
                    return new XSLFExtractor(new XMLSlideShow(pkg));
                }
            }
        }

        if (XSLFRelation.THEME_MANAGER.getContentType().equals(targetContentType)) {
            if (eventBased) {
                return new XSLFEventBasedPowerPointExtractor(pkg);
            } else {
                return new XSLFExtractor(new XMLSlideShow(pkg));
            }
        }
        return null;
    }
Figures out the correct {@link OOXMLExtractor} for the supplied document and
returns it.
tika-parsers/tika-parsers-standard/tika-parsers-standard-modules/tika-parser-microsoft-module/src/main/java/org/apache/tika/parser/microsoft/ooxml/OOXMLExtractorFactory.java