Package org.opencms.search
Class CmsDependencyIndexer
- java.lang.Object
-
- org.opencms.search.CmsVfsIndexer
-
- org.opencms.search.CmsDependencyIndexer
-
- All Implemented Interfaces:
I_CmsIndexer
public class CmsDependencyIndexer extends CmsVfsIndexer
A VFS indexer that resolves locale dependent documents.- Since:
- 8.5.0
-
-
Field Summary
-
Fields inherited from class org.opencms.search.CmsVfsIndexer
m_cms, m_index, m_report
-
-
Constructor Summary
Constructors Constructor Description CmsDependencyIndexer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.util.Map<java.lang.String,java.util.List<CmsResource>>
createFolderLookupMap(java.util.List<CmsResource> resources)
Creates a folder based lookup map for the given resource list.CmsSearchIndexUpdateData
getUpdateData(CmsSearchIndexSource source, java.util.List<CmsPublishedResource> publishedResources)
Calculates the data for an incremental search index update.boolean
isLocaleDependenciesEnable()
The default indexer is not able to resolve locale dependencies between documents.void
rebuildIndex(I_CmsIndexWriter writer, CmsIndexingThreadManager threadManager, CmsSearchIndexSource source)
Rebuilds the index for the given configured index source.-
Methods inherited from class org.opencms.search.CmsVfsIndexer
addResourceToUpdateData, deleteResource, deleteResources, getCms, getIndex, getReport, isResourceInTimeWindow, newInstance, updateResource, updateResource, updateResources
-
-
-
-
Constructor Detail
-
CmsDependencyIndexer
public CmsDependencyIndexer()
-
-
Method Detail
-
getUpdateData
public CmsSearchIndexUpdateData getUpdateData(CmsSearchIndexSource source, java.util.List<CmsPublishedResource> publishedResources)
Description copied from interface:I_CmsIndexer
Calculates the data for an incremental search index update.- Specified by:
getUpdateData
in interfaceI_CmsIndexer
- Overrides:
getUpdateData
in classCmsVfsIndexer
- Parameters:
source
- the search index source to updatepublishedResources
- a list of
objects that are to be updatedCmsPublishedResource
- Returns:
- a container with the information about the resources to delete and / or update
- See Also:
CmsVfsIndexer.getUpdateData(org.opencms.search.CmsSearchIndexSource, java.util.List)
-
isLocaleDependenciesEnable
public boolean isLocaleDependenciesEnable()
Description copied from class:CmsVfsIndexer
The default indexer is not able to resolve locale dependencies between documents.- Specified by:
isLocaleDependenciesEnable
in interfaceI_CmsIndexer
- Overrides:
isLocaleDependenciesEnable
in classCmsVfsIndexer
- Returns:
true
if this VFS indexer is able to resolve locale dependencies between documents- See Also:
CmsVfsIndexer.isLocaleDependenciesEnable()
-
rebuildIndex
public void rebuildIndex(I_CmsIndexWriter writer, CmsIndexingThreadManager threadManager, CmsSearchIndexSource source)
Description copied from interface:I_CmsIndexer
Rebuilds the index for the given configured index source.This is used when the index is fully rebuild, not for updating only some parts of an existing index.
- Specified by:
rebuildIndex
in interfaceI_CmsIndexer
- Overrides:
rebuildIndex
in classCmsVfsIndexer
- Parameters:
writer
- the index writer to write the update tothreadManager
- the thread manager to use when extracting the document textsource
- the search index source to update- See Also:
I_CmsIndexer.rebuildIndex(org.opencms.search.I_CmsIndexWriter, org.opencms.search.CmsIndexingThreadManager, org.opencms.search.CmsSearchIndexSource)
-
createFolderLookupMap
protected java.util.Map<java.lang.String,java.util.List<CmsResource>> createFolderLookupMap(java.util.List<CmsResource> resources)
Creates a folder based lookup map for the given resource list.- Parameters:
resources
- the list of resource to build the lookup map for- Returns:
- a folder based lookup map for the given resource list
-
-