View | Details | Raw Unified | Return to bug 47517
Collapse All | Expand All

(-)a/src/ooxml/java/org/apache/poi/extractor/ExtractorFactory.java (+9 lines)
Lines 102-113 public class ExtractorFactory { Link Here
102
                if(corePart.getContentType().equals(XSSFRelation.TEMPLATE_WORKBOOK.getContentType())) {
102
                if(corePart.getContentType().equals(XSSFRelation.TEMPLATE_WORKBOOK.getContentType())) {
103
                        return new XSSFExcelExtractor(pkg);
103
                        return new XSSFExcelExtractor(pkg);
104
                }
104
                }
105
                if(corePart.getContentType().equals(XSSFRelation.MACRO_WORKBOOK.getContentType())) {
106
                        return new XSSFExcelExtractor(pkg);
107
                }
105
		if(corePart.getContentType().equals(XWPFRelation.DOCUMENT.getContentType())) {
108
		if(corePart.getContentType().equals(XWPFRelation.DOCUMENT.getContentType())) {
106
			return new XWPFWordExtractor(pkg);
109
			return new XWPFWordExtractor(pkg);
107
		}
110
		}
108
                if(corePart.getContentType().equals(XWPFRelation.TEMPLATE.getContentType())) {
111
                if(corePart.getContentType().equals(XWPFRelation.TEMPLATE.getContentType())) {
109
                        return new XWPFWordExtractor(pkg);
112
                        return new XWPFWordExtractor(pkg);
110
                }
113
                }
114
                if(corePart.getContentType().equals(XWPFRelation.MACRO_DOCUMENT.getContentType())) {
115
                        return new XWPFWordExtractor(pkg);
116
                }
117
                if(corePart.getContentType().equals(XWPFRelation.MACRO_TEMPLATE_DOCUMENT.getContentType())) {
118
                        return new XWPFWordExtractor(pkg);
119
                }
111
		if(corePart.getContentType().equals(XSLFSlideShow.MAIN_CONTENT_TYPE)) {
120
		if(corePart.getContentType().equals(XSLFSlideShow.MAIN_CONTENT_TYPE)) {
112
			return new XSLFPowerPointExtractor(pkg);
121
			return new XSLFPowerPointExtractor(pkg);
113
		}
122
		}
(-)a/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFRelation.java (+6 lines)
Lines 72-77 public final class XSSFRelation extends POIXMLRelation { Link Here
72
                  "/xl/workbook.xml",
72
                  "/xl/workbook.xml",
73
                  null
73
                  null
74
        );
74
        );
75
        public static final XSSFRelation MACRO_WORKBOOK = new XSSFRelation(
76
                  "application/vnd.ms-excel.sheet.macroEnabled.main+xml",
77
                  "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
78
                  "/xl/workbook.xml",
79
                  null
80
        );
75
	public static final XSSFRelation WORKSHEET = new XSSFRelation(
81
	public static final XSSFRelation WORKSHEET = new XSSFRelation(
76
			"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml",
82
			"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml",
77
			"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",
83
			"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",
(-)a/src/ooxml/java/org/apache/poi/xwpf/usermodel/XWPFRelation.java (+12 lines)
Lines 46-51 public final class XWPFRelation extends POIXMLRelation { Link Here
46
          "/word/document.xml",
46
          "/word/document.xml",
47
          null
47
          null
48
    );
48
    );
49
    public static final XWPFRelation MACRO_DOCUMENT = new XWPFRelation(
50
            "application/vnd.ms-word.document.macroEnabled.main+xml",
51
            "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
52
            "/word/document.xml",
53
            null
54
    );
55
    public static final XWPFRelation MACRO_TEMPLATE_DOCUMENT = new XWPFRelation(
56
            "application/vnd.ms-word.template.macroEnabledTemplate.main+xml",
57
            "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
58
            "/word/document.xml",
59
            null
60
    );
49
    public static final XWPFRelation FONT_TABLE = new XWPFRelation(
61
    public static final XWPFRelation FONT_TABLE = new XWPFRelation(
50
            "application/vnd.openxmlformats-officedocument.wordprocessingml.fontTable+xml",
62
            "application/vnd.openxmlformats-officedocument.wordprocessingml.fontTable+xml",
51
            "http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable",
63
            "http://schemas.openxmlformats.org/officeDocument/2006/relationships/fontTable",

Return to bug 47517