Class DuplicateContentConfiguration
- java.lang.Object
-
- org.ametys.cms.duplicate.contents.DuplicateContentConfiguration
-
public class DuplicateContentConfiguration extends Object
Represents the global configuration of content duplicate detection configuration
-
-
Constructor Summary
Constructors Constructor Description DuplicateContentConfiguration(Configuration configuration, DuplicateContentsManager duplicateContentsManager)
Create a new DuplicateContentConfiguration
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DuplicateContentTypeConfiguration
get(String duplicateContentTypeId)
Get the DuplicateContentTypeConfiguration related to a given content typeMap<String,DuplicateContentTypeConfiguration>
getContentTypes()
Get the content type configuration mapSet<String>
getDuplicatesContentTypes()
Get the list of duplicate content typesList<Pair<String,List<Object>>>
getErrors()
get the list of errorsList<Pair<String,List<Object>>>
getWarns()
get the list of warnsvoid
setContentTypes(Map<String,DuplicateContentTypeConfiguration> contentTypes)
Set the content type configuration map
-
-
-
Constructor Detail
-
DuplicateContentConfiguration
public DuplicateContentConfiguration(Configuration configuration, DuplicateContentsManager duplicateContentsManager) throws ConfigurationException
Create a new DuplicateContentConfiguration- Parameters:
configuration
- the configuration used to create the DuplicateContentConfigurationduplicateContentsManager
- the duplicate contents manager, only use this parameter to get linked components- Throws:
ConfigurationException
- if the configuration is not valid.
-
-
Method Detail
-
getContentTypes
public Map<String,DuplicateContentTypeConfiguration> getContentTypes()
Get the content type configuration map- Returns:
- the content type configuration map
-
setContentTypes
public void setContentTypes(Map<String,DuplicateContentTypeConfiguration> contentTypes)
Set the content type configuration map- Parameters:
contentTypes
- the content type configuration map
-
getDuplicatesContentTypes
public Set<String> getDuplicatesContentTypes()
Get the list of duplicate content types- Returns:
- the list of duplicate content types
-
get
public DuplicateContentTypeConfiguration get(String duplicateContentTypeId)
Get the DuplicateContentTypeConfiguration related to a given content type- Parameters:
duplicateContentTypeId
- the id of the content type- Returns:
- the DuplicateContentTypeConfiguration
-
getErrors
public List<Pair<String,List<Object>>> getErrors()
get the list of errors- Returns:
- the error list
-
-