Package org.ametys.plugins.odfsync.scc
Class PersonSynchronizableContentsCollection
- java.lang.Object
-
- org.ametys.plugins.contentio.synchronize.AbstractStaticSynchronizableContentsCollection
-
- org.ametys.plugins.contentio.synchronize.AbstractSynchronizableContentsCollection
-
- org.ametys.plugins.contentio.synchronize.AbstractSimpleSynchronizableContentsCollection
-
- org.ametys.plugins.contentio.synchronize.impl.AbstractDataSourceSynchronizableContentsCollection
-
- org.ametys.plugins.contentio.synchronize.impl.LDAPSynchronizableContentsCollection
-
- org.ametys.plugins.odfsync.scc.PersonSynchronizableContentsCollection
-
- All Implemented Interfaces:
SynchronizableContentsCollection
,Initializable
,Component
,Configurable
,Serviceable
public class PersonSynchronizableContentsCollection extends LDAPSynchronizableContentsCollection
Class to import ODF persons. Import a person only in one language.
-
-
Field Summary
Fields Modifier and Type Field Description protected String
_odfLang
Default language configured for ODF-
Fields inherited from class org.ametys.plugins.contentio.synchronize.impl.LDAPSynchronizableContentsCollection
_ldapHelper, _pageSize
-
Fields inherited from class org.ametys.plugins.contentio.synchronize.impl.AbstractDataSourceSynchronizableContentsCollection
__PARAM_DATASOURCE_ID, __PARAM_FIELD_ID, __PARAM_MAPPING, __PARAM_MAPPING_ATTRIBUTE, __PARAM_MAPPING_METADATA_REF, __PARAM_MAPPING_SYNCHRO, _columnsAndCriteria, _extFields, _jsonUtils, _mapping, _syncFields
-
Fields inherited from class org.ametys.plugins.contentio.synchronize.AbstractSimpleSynchronizableContentsCollection
_contentHelper, _sccHelper, _synchronizingContentOperatorEP
-
Fields inherited from class org.ametys.plugins.contentio.synchronize.AbstractSynchronizableContentsCollection
_contentDAO, _contentTypeEP, _currentUserProvider, _hasGlobalError, _i18nUtils, _nbCreatedContents, _nbDeletedContents, _nbError, _nbNotChangedContents, _nbSynchronizedContents, _observationManager, _resolver, _synchroComponent, SCC_UNIQUE_ID
-
Fields inherited from class org.ametys.plugins.contentio.synchronize.AbstractStaticSynchronizableContentsCollection
_contentPrefix, _contentType, _id, _initialActionId, _label, _languages, _modelId, _modelParamValues, _removalSync, _reportMails, _restrictedField, _searchModelConfiguration, _synchronizeActionId, _synchronizeExistingContentsOnly, _synchronizingContentOperator, _validateActionId, _validateAfterImport, _workflowName
-
Fields inherited from interface org.ametys.plugins.contentio.synchronize.SynchronizableContentsCollection
COLLECTION_ID_PROPERTY
-
-
Constructor Summary
Constructors Constructor Description PersonSynchronizableContentsCollection()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected List<ModifiableDefaultContent>
_importOrSynchronizeContent(String idValue, Map<String,List<Object>> remoteValues, boolean forceImport, org.slf4j.Logger logger)
Imports or synchronizes a content for each available languageprotected void
configureDataSource(Configuration configuration)
Configure the data source parameters.List<ModifiableDefaultContent>
importContent(String idValue, Map<String,Object> importParams, org.slf4j.Logger logger)
Import a content from remote values.-
Methods inherited from class org.ametys.plugins.contentio.synchronize.impl.LDAPSynchronizableContentsCollection
configureSearchModel, getFilter, getRelativeDN, getSearchScope, initialize, internalSearch, service
-
Methods inherited from class org.ametys.plugins.contentio.synchronize.impl.AbstractDataSourceSynchronizableContentsCollection
getDataSourceId, getExternalOnlyFields, getIdField, getLocalAndExternalFields, getMapping, getRemoteValues, putIdParameter
-
Methods inherited from class org.ametys.plugins.contentio.synchronize.AbstractSimpleSynchronizableContentsCollection
_fillContent, _getContentsToRemove, _getIdFieldValue, _handleContent, _importContent, _importOrSynchronizeContent, _importOrSynchronizeContents, _internalPopulate, _isHandled, _synchronizeContent, additionalCommonOperations, additionalImportOperations, additionalSynchronizeOperations, configure, createContentAction, getContent, getTotalCount, getTransformedRemoteValues, populate, search, synchronizeContent, updateSyncInformations, validateContent
-
Methods inherited from class org.ametys.plugins.contentio.synchronize.AbstractSynchronizableContentsCollection
_getContentPathQuery, _getExpressionsList, _getMetadataHolder, _isParamNotEmpty, _removeEmptyParameters, _removeMetadataIfExists, _synchronizeMetadata, _updateRelation, _updateRelation, applyChanges, applyChanges, createContentAction, deleteUnexistingContents, sendErrorMail, updateSCCProperty, validateContent
-
Methods inherited from class org.ametys.plugins.contentio.synchronize.AbstractStaticSynchronizableContentsCollection
_parseLanguages, _parseParameters, configureStaticParams, getContentPrefix, getContentType, getId, getInitialActionId, getLabel, getLanguages, getParameterValues, getReportMails, getRestrictedField, getSearchModelConfiguration, getSynchronizeActionId, getSynchronizeCollectionModelId, getSynchronizingContentOperator, getValidateActionId, getWorkflowName, removalSync, synchronizeExistingContentsOnly, validateAfterImport
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ametys.plugins.contentio.synchronize.SynchronizableContentsCollection
handleRightAssignmentContext
-
-
-
-
Constructor Detail
-
PersonSynchronizableContentsCollection
public PersonSynchronizableContentsCollection()
-
-
Method Detail
-
configureDataSource
protected void configureDataSource(Configuration configuration) throws ConfigurationException
Description copied from class:AbstractStaticSynchronizableContentsCollection
Configure the data source parameters.- Overrides:
configureDataSource
in classLDAPSynchronizableContentsCollection
- Parameters:
configuration
- Configuration to read- Throws:
ConfigurationException
- If an error occurs
-
_importOrSynchronizeContent
protected List<ModifiableDefaultContent> _importOrSynchronizeContent(String idValue, Map<String,List<Object>> remoteValues, boolean forceImport, org.slf4j.Logger logger)
Description copied from class:AbstractSimpleSynchronizableContentsCollection
Imports or synchronizes a content for each available language- Overrides:
_importOrSynchronizeContent
in classAbstractSimpleSynchronizableContentsCollection
- Parameters:
idValue
- The unique identifier of the contentremoteValues
- The remote valuesforceImport
- To force import and ignoring the synchronize existing contents only optionlogger
- The logger- Returns:
- The list of synchronized or imported contents
-
importContent
public List<ModifiableDefaultContent> importContent(String idValue, Map<String,Object> importParams, org.slf4j.Logger logger) throws Exception
Description copied from interface:SynchronizableContentsCollection
Import a content from remote values.- Specified by:
importContent
in interfaceSynchronizableContentsCollection
- Overrides:
importContent
in classAbstractSimpleSynchronizableContentsCollection
- Parameters:
idValue
- Id (for import/synchronization) of the content to importimportParams
- Additional parameterslogger
- The logger- Returns:
- A list of created contents
- Throws:
Exception
- if an error occurs.
-
-