Class RemoteImportCDMFrComponent
java.lang.Object
org.ametys.plugins.odfsync.cdmfr.components.AbstractImportCDMFrComponent
org.ametys.plugins.odfsync.cdmfr.components.impl.RemoteImportCDMFrComponent
- All Implemented Interfaces:
ImportCDMFrComponent
,Initializable
,Component
,Configurable
,Contextualizable
,Serviceable
- Direct Known Subclasses:
CoAccreditedRemoteImportCDMFrComponent
Component to import a CDM-fr input stream from a remote server.
-
Field Summary
Modifier and TypeFieldDescriptionprotected String
Forced catalogprotected boolean
Validate after importstatic final String
Avalon RoleFields inherited from class org.ametys.plugins.odfsync.cdmfr.components.AbstractImportCDMFrComponent
_catalogsManager, _cdmFrSyncExtensionPoint, _cocoonContext, _contentPrefix, _contentTypeEP, _contentWorkflowHelper, _currentUserProvider, _domParser, _importedContents, _nbError, _observationManager, _odfHelper, _odfLang, _odfRefTableHelper, _resolver, _rootOUProvider, _sccHelper, _shareableCourseHelper, _syncFieldsByContentType, _SYNCHRONIZE_WORKFLOW_ACTION_ID, _synchronizedContents, _TAG_CONTAINER, _TAG_COURSELIST, _TAG_COURSEPART, _TAG_PROGRAM, _TAG_SUBPROGRAM, _valuesExtractorFactory, _xPathProcessor
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
additionalParameters
(Map<String, Object> parameters) Additional parameters for specific treatments.getCatalogName
(Element contentElement) Get the name of catalog to use for importprotected boolean
If true, bypass the rights check during the import processprotected boolean
When returns true, a content created by a previous synchro will be removed if it does not exist anymore during the current synchro.protected Document
Transform the document depending of it structure.protected boolean
True to validate the contents after importMethods inherited from class org.ametys.plugins.odfsync.cdmfr.components.AbstractImportCDMFrComponent
_createContent, _editContent, _getAdditionalValuesToSynchronize, _getExpressionsList, _getInputsForContentCreation, _getNotSynchronizedRelatedContentIds, _getOrCreateContent, _initializeShareableCoursesFields, _linkTranslationsIfExist, _setOrgUnitParent, _synchronizeContent, additionalOperations, configure, contextualize, getContent, getIdField, getIdFromCDMThenCode, getLocalAndExternalFields, handleInputStream, importOrSynchronizeContent, initialize, service, validateContent
-
Field Details
-
ROLE
Avalon Role -
_forcedCatalog
Forced catalog -
_validateAfterImport
Validate after import
-
-
Constructor Details
-
RemoteImportCDMFrComponent
public RemoteImportCDMFrComponent()
-
-
Method Details
-
additionalParameters
Description copied from class:AbstractImportCDMFrComponent
Additional parameters for specific treatments.- Specified by:
additionalParameters
in classAbstractImportCDMFrComponent
- Parameters:
parameters
- The parameters map to get
-
getCatalogName
Description copied from interface:ImportCDMFrComponent
Get the name of catalog to use for import- Specified by:
getCatalogName
in interfaceImportCDMFrComponent
- Overrides:
getCatalogName
in classAbstractImportCDMFrComponent
- Parameters:
contentElement
- Element of the content- Returns:
- The catalog to used
-
transformDocument
protected Document transformDocument(Document document, Map<String, Object> parameters, Logger logger) throws IOException, SAXException, ProcessingExceptionDescription copied from class:AbstractImportCDMFrComponent
Transform the document depending of it structure.- Overrides:
transformDocument
in classAbstractImportCDMFrComponent
- Parameters:
document
- Document to transform.parameters
- Optional parameters for transformationlogger
- The logger- Returns:
- The transformed document.
- Throws:
IOException
- if an error occurs.SAXException
- if an error occurs.ProcessingException
- if an error occurs.
-
validateAfterImport
Description copied from class:AbstractImportCDMFrComponent
True to validate the contents after import- Specified by:
validateAfterImport
in classAbstractImportCDMFrComponent
- Returns:
- True to validate the contents after import
-
removalSync
Description copied from class:AbstractImportCDMFrComponent
When returns true, a content created by a previous synchro will be removed if it does not exist anymore during the current synchro.- Specified by:
removalSync
in classAbstractImportCDMFrComponent
- Returns:
- true if a content created by a previous synchro has to be removed if it does not exist anymore during the current synchro.
-
ignoreRights
Description copied from class:AbstractImportCDMFrComponent
If true, bypass the rights check during the import process- Overrides:
ignoreRights
in classAbstractImportCDMFrComponent
- Returns:
- True if the rights check are bypassed during the import process
-