public class XDOMOfficeDocument extends Object implements OfficeDocument
OfficeDocument
backed by an XDOM
document.Constructor and Description |
---|
XDOMOfficeDocument(XDOM xdom,
Map<String,byte[]> artifacts,
org.xwiki.component.manager.ComponentManager componentManager)
Creates a new
XDOMOfficeDocument . |
Modifier and Type | Method and Description |
---|---|
Map<String,byte[]> |
getArtifacts()
Returns all the artifacts for this office document.
|
String |
getContentAsString()
Returns the content of this document as a string.
|
String |
getContentAsString(String syntaxId)
Renders the XDOM encapsulated by this document into the given syntax.
|
XDOM |
getContentDocument()
Returns the content of this office document.
|
String |
getTitle()
Tries to extract a title suitable for this document.
|
public XDOMOfficeDocument(XDOM xdom, Map<String,byte[]> artifacts, org.xwiki.component.manager.ComponentManager componentManager)
XDOMOfficeDocument
.xdom
- XDOM
corresponding to office document content.artifacts
- artifacts for this office document.componentManager
- ComponentManager
used to lookup for various renderers.public XDOM getContentDocument()
OfficeDocument
getContentDocument
in interface OfficeDocument
public String getContentAsString()
OfficeDocument
getContentAsString
in interface OfficeDocument
public String getContentAsString(String syntaxId)
syntaxId
- string identifier of the syntax.public Map<String,byte[]> getArtifacts()
OfficeDocument
getArtifacts
in interface OfficeDocument
Copyright © 2004–2019 XWiki. All rights reserved.