Class DocumentModelWriter
- java.lang.Object
-
- org.nuxeo.ecm.core.io.impl.AbstractDocumentWriter
-
- org.nuxeo.ecm.core.io.impl.AbstractDocumentModelWriter
-
- org.nuxeo.ecm.core.io.impl.plugins.DocumentModelWriter
-
- All Implemented Interfaces:
DocumentWriter
- Direct Known Subclasses:
ExtensibleDocumentWriter
public class DocumentModelWriter extends AbstractDocumentModelWriter
A writer which is creating new docs or updating existing docs.- Author:
- Bogdan Stefanescu
-
-
Field Summary
-
Fields inherited from class org.nuxeo.ecm.core.io.impl.AbstractDocumentModelWriter
root, session, unsavedDocuments
-
-
Constructor Summary
Constructors Constructor Description DocumentModelWriter(CoreSession session, String parentPath)
DocumentModelWriter(CoreSession session, String parentPath, int saveInterval)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DocumentTranslationMap
write(ExportedDocument xdoc)
Writes a single document.-
Methods inherited from class org.nuxeo.ecm.core.io.impl.AbstractDocumentModelWriter
beforeCreateDocument, beforeSaveDocument, close, createDocument, getFieldClass, getSaveInterval, getTranslationMap, loadFacetsInfo, loadSchema, loadSchemas, loadSystemInfo, saveIfNeeded, setSaveInterval, updateDocument
-
Methods inherited from class org.nuxeo.ecm.core.io.impl.AbstractDocumentWriter
createCompactFormat, createPrettyPrint, write, write
-
-
-
-
Constructor Detail
-
DocumentModelWriter
public DocumentModelWriter(CoreSession session, String parentPath)
- Parameters:
session
- the session to the repository where to writeparentPath
- where to write the tree. this document will be used as the parent of all top level documents passed as input. Note that you may have
-
DocumentModelWriter
public DocumentModelWriter(CoreSession session, String parentPath, int saveInterval)
-
-
Method Detail
-
write
public DocumentTranslationMap write(ExportedDocument xdoc) throws IOException
Description copied from interface:DocumentWriter
Writes a single document.- Specified by:
write
in interfaceDocumentWriter
- Specified by:
write
in classAbstractDocumentWriter
- Parameters:
xdoc
- the document to write- Returns:
- the translation map.
- Throws:
IOException
-
-