Class ExtensibleDocumentTreeReader
- java.lang.Object
-
- org.nuxeo.ecm.core.io.impl.AbstractDocumentReader
-
- org.nuxeo.ecm.core.io.impl.plugins.DocumentModelReader
-
- org.nuxeo.ecm.core.io.impl.plugins.ExtensibleDocumentTreeReader
-
- All Implemented Interfaces:
DocumentReader
public class ExtensibleDocumentTreeReader extends DocumentModelReader
Compared to the defaultDocumentReader
implementation this one does handle versions and allows to plugExportExtension
- Since:
- 7.4
-
-
Field Summary
Fields Modifier and Type Field Description protected List<ExportExtension>
extensions
protected DocumentTreeIterator
iterator
protected int
pathSegmentsToRemove
protected List<DocumentModel>
pendingVersions
static String
VERSION_VIRTUAL_PATH_SEGMENT
-
Fields inherited from class org.nuxeo.ecm.core.io.impl.plugins.DocumentModelReader
inlineBlobs, session
-
-
Constructor Summary
Constructors Constructor Description ExtensibleDocumentTreeReader(CoreSession session, DocumentModel root)
ExtensibleDocumentTreeReader(CoreSession session, DocumentModel root, boolean excludeRoot)
ExtensibleDocumentTreeReader(CoreSession session, DocumentRef root)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Closes the reader.ExportedDocument
read()
Reads a single document.void
registerExtension(ExportExtension ext)
-
Methods inherited from class org.nuxeo.ecm.core.io.impl.plugins.DocumentModelReader
getInlineBlobs, setInlineBlobs
-
Methods inherited from class org.nuxeo.ecm.core.io.impl.AbstractDocumentReader
read
-
-
-
-
Field Detail
-
iterator
protected DocumentTreeIterator iterator
-
pathSegmentsToRemove
protected int pathSegmentsToRemove
-
pendingVersions
protected List<DocumentModel> pendingVersions
-
extensions
protected List<ExportExtension> extensions
-
VERSION_VIRTUAL_PATH_SEGMENT
public static final String VERSION_VIRTUAL_PATH_SEGMENT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ExtensibleDocumentTreeReader
public ExtensibleDocumentTreeReader(CoreSession session, DocumentModel root, boolean excludeRoot)
-
ExtensibleDocumentTreeReader
public ExtensibleDocumentTreeReader(CoreSession session, DocumentRef root)
-
ExtensibleDocumentTreeReader
public ExtensibleDocumentTreeReader(CoreSession session, DocumentModel root)
-
-
Method Detail
-
registerExtension
public void registerExtension(ExportExtension ext)
-
close
public void close()
Description copied from interface:DocumentReader
Closes the reader.- Specified by:
close
in interfaceDocumentReader
- Overrides:
close
in classDocumentModelReader
-
read
public ExportedDocument read() throws IOException
Description copied from interface:DocumentReader
Reads a single document.- Specified by:
read
in interfaceDocumentReader
- Specified by:
read
in classDocumentModelReader
- Returns:
- the document read or null if there are no more documents to read
- Throws:
IOException
-
-