private void handleDataStream(InputStream dataStream, String objID, String progId,
                                  XHTMLContentHandler xhtml) {
        //TODO -- inject progId into the metadata of the embedded file
        try (TikaInputStream stream = TikaInputStream.get(dataStream)) {
            String mediaType = null;
            if ("Excel.Chart.8".equals(progId)) {
                mediaType = "application/vnd.ms-excel";
            } else {
                MediaType mt =
                        getTikaConfig().getDetector().detect(stream, new Metadata());
                mediaType = mt.toString();
            }
            if (mediaType
                    .equals("application/x-tika-msoffice-embedded; format=comp_obj") ||
                    mediaType.equals("application/x-tika-msoffice")) {
                POIFSFileSystem poifs = new POIFSFileSystem(CloseShieldInputStream.wrap(stream));

                try {
                    handleEmbeddedOfficeDoc(poifs.getRoot(), objID, xhtml, false);
                } finally {
                    if (poifs != null) {
                        poifs.close();
                    }
                }
            } else {
                handleEmbeddedResource(stream, objID, objID, mediaType, xhtml, false);
            }
        } catch (SecurityException e) {
            throw e;
        } catch (Exception e) {
            EmbeddedDocumentUtil.recordException(e, parentMetadata);
        }
    }
This is the catch-all for embedded objects.  If we didn't come across
them in the shapes in the slides, headers/footers, etc, try to
extract them here.
tika-parsers/tika-parsers-standard/tika-parsers-standard-modules/tika-parser-microsoft-module/src/main/java/org/apache/tika/parser/microsoft/HSLFExtractor.java