public abstract class AbstractDocumentModelFactory extends Object implements ImporterDocumentModelFactory
ImporterDocumentModelFactory. Contains common methods.| Modifier and Type | Class and Description | 
|---|---|
protected static class  | 
AbstractDocumentModelFactory.CompatFilenameNormalizer  | 
protected static class  | 
AbstractDocumentModelFactory.DefaultFilenameNormalizer  | 
protected static interface  | 
AbstractDocumentModelFactory.FilenameNormalizer  | 
| Modifier and Type | Field and Description | 
|---|---|
protected AbstractDocumentModelFactory.FilenameNormalizer | 
filenameNormalizer  | 
| Constructor and Description | 
|---|
AbstractDocumentModelFactory()  | 
| Modifier and Type | Method and Description | 
|---|---|
protected String | 
getValidNameFromFileName(String fileName)
Returns a valid Nuxeo name from the given  
fileName. | 
boolean | 
isTargetDocumentModelFolderish(SourceNode node)  | 
boolean | 
processFolderishNodeCreationError(CoreSession session,
                                 DocumentModel parent,
                                 SourceNode node)
By default there is no process bound to a folderish node creation error, and the global import task will
 continue. 
 | 
boolean | 
processLeafNodeCreationError(CoreSession session,
                            DocumentModel parent,
                            SourceNode node)
By default there is no process bound to a leaf node creation error, and the global import task will continue. 
 | 
protected DocumentModel | 
setDocumentProperties(CoreSession session,
                     Map<String,Serializable> properties,
                     DocumentModel doc)
Set all the properties to the given  
doc. | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcreateFolderishNode, createLeafNodeprotected final AbstractDocumentModelFactory.FilenameNormalizer filenameNormalizer
public AbstractDocumentModelFactory()
public boolean processFolderishNodeCreationError(CoreSession session, DocumentModel parent, SourceNode node)
You should override this method if you want a specific process to be executed after such an error and/or if you want the global import task to stop immediately after the error occurs, in which case the method should return false.
processFolderishNodeCreationError in interface ImporterDocumentModelFactorypublic boolean processLeafNodeCreationError(CoreSession session, DocumentModel parent, SourceNode node)
You should override this method if you want a specific process to be executed after such an error and/or if you want the global import task to stop immediately after the error occurs, in which case the method should return false.
processLeafNodeCreationError in interface ImporterDocumentModelFactorypublic boolean isTargetDocumentModelFolderish(SourceNode node)
isTargetDocumentModelFolderish in interface ImporterDocumentModelFactoryprotected String getValidNameFromFileName(String fileName)
fileName.PropertyExceptionprotected DocumentModel setDocumentProperties(CoreSession session, Map<String,Serializable> properties, DocumentModel doc)
doc. The key is field xpath, the value is the value to set on the
 document.Copyright © 2019 Nuxeo. All rights reserved.