Class | Line # | Actions | |||||
---|---|---|---|---|---|---|---|
OfficeDocument | 30 | 0 | - | 0 | 0 |
1 | /* | |
2 | * See the NOTICE file distributed with this work for additional | |
3 | * information regarding copyright ownership. | |
4 | * | |
5 | * This is free software; you can redistribute it and/or modify it | |
6 | * under the terms of the GNU Lesser General Public License as | |
7 | * published by the Free Software Foundation; either version 2.1 of | |
8 | * the License, or (at your option) any later version. | |
9 | * | |
10 | * This software is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 | * Lesser General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU Lesser General Public | |
16 | * License along with this software; if not, write to the Free | |
17 | * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA | |
18 | * 02110-1301 USA, or see the FSF site: http://www.fsf.org. | |
19 | */ | |
20 | package org.xwiki.officeimporter.document; | |
21 | ||
22 | import java.util.Map; | |
23 | ||
24 | /** | |
25 | * Represents an office document being imported. | |
26 | * | |
27 | * @version $Id: 2efd8c6da290d3a31232b8e7b7f6736d6919f2ec $ | |
28 | * @since 2.1M1 | |
29 | */ | |
30 | public interface OfficeDocument | |
31 | { | |
32 | /** | |
33 | * Returns the content of this office document. Content document type may vary depending on the implementation. For | |
34 | * an example, a particular implementation might return an html DOM object while another implementation might return | |
35 | * an XDOM. | |
36 | * | |
37 | * @return content of this document. | |
38 | */ | |
39 | Object getContentDocument(); | |
40 | ||
41 | /** | |
42 | * Returns the content of this document as a string. | |
43 | * | |
44 | * @return content of this document as a string. | |
45 | */ | |
46 | String getContentAsString(); | |
47 | ||
48 | /** | |
49 | * Returns all the artifacts for this office document. Artifacts are generated during the import operation if the | |
50 | * original office document contains embedded non-textual elements. Also, some office formats (like presentations) | |
51 | * result in multiple output files when converted into html. In this case all these output files will be considered | |
52 | * as artifacts. | |
53 | * | |
54 | * @return a map containing artifacts for this document. | |
55 | */ | |
56 | Map<String, byte[]> getArtifacts(); | |
57 | } |