Liferay 7.0-ce-b4

com.liferay.portal.kernel.search
Interface Indexer<T>

All Known Implementing Classes:
AssetCategoryIndexer, AssetEntryIndexer, AssetSearcher, AssetVocabularyIndexer, BaseIndexer, BaseSearcher, ContactIndexer, DLFileEntryIndexer, DLFileEntryMetadataIndexer, DLFolderIndexer, DLSearcher, DummyIndexer, FacetedSearcher, FolderSearcher, MBMessageIndexer, MBThreadIndexer, OrganizationIndexer, PluginPackageIndexer, TrashIndexer, UserIndexer

public interface Indexer<T>


Field Summary
static int DEFAULT_INTERVAL
           
 
Method Summary
 void delete(long companyId, String uid)
           
 void delete(T object)
           
 String getClassName()
           
 String[] getClassNames()
          Deprecated. As of 7.0.0, replaced by getSearchClassNames()
 Document getDocument(T object)
           
 BooleanFilter getFacetBooleanFilter(String className, SearchContext searchContext)
           
 BooleanQuery getFullQuery(SearchContext searchContext)
           
 IndexerPostProcessor[] getIndexerPostProcessors()
           
 String getPortletId()
          Deprecated. As of 7.0.0, replaced by getClassName()
 String[] getSearchClassNames()
           
 String getSearchEngineId()
           
 String getSortField(String orderByCol)
           
 String getSortField(String orderByCol, int sortType)
           
 Summary getSummary(Document document, Locale locale, String snippet)
          Deprecated. As of 7.0.0, replaced by getSummary(Document, String, PortletRequest, PortletResponse)
 Summary getSummary(Document document, String snippet, PortletRequest portletRequest, PortletResponse portletResponse)
           
 boolean hasPermission(PermissionChecker permissionChecker, String entryClassName, long entryClassPK, String actionId)
           
 boolean isCommitImmediately()
           
 boolean isFilterSearch()
          Return true if the indexer participates in post-search result filtering.
 boolean isIndexerEnabled()
           
 boolean isPermissionAware()
          Returns true if the indexer adds permission related filters to the search query prior to execution
 boolean isStagingAware()
           
 boolean isVisible(long classPK, int status)
           
 boolean isVisibleRelatedEntry(long classPK, int status)
           
 void postProcessContextBooleanFilter(BooleanFilter contextBooleanFilter, SearchContext searchContext)
           
 void postProcessContextQuery(BooleanQuery contextQuery, SearchContext searchContext)
          Deprecated. As of 7.0.0, replaced by postProcessContextBooleanFilter(BooleanFilter, SearchContext)
 void postProcessSearchQuery(BooleanQuery searchQuery, BooleanFilter fullQueryBooleanFilter, SearchContext searchContext)
           
 void postProcessSearchQuery(BooleanQuery searchQuery, SearchContext searchContext)
          Deprecated. As of 7.0.0, replaced by postProcessSearchQuery(BooleanQuery, BooleanFilter, SearchContext)
 void registerIndexerPostProcessor(IndexerPostProcessor indexerPostProcessor)
           
 void reindex(Collection<T> objects)
           
 void reindex(String[] ids)
           
 void reindex(String className, long classPK)
           
 void reindex(T object)
           
 Hits search(SearchContext searchContext)
           
 Hits search(SearchContext searchContext, String... selectedFieldNames)
           
 long searchCount(SearchContext searchContext)
           
 void setIndexerEnabled(boolean indexerEnabled)
           
 void unregisterIndexerPostProcessor(IndexerPostProcessor indexerPostProcessor)
           
 

Field Detail

DEFAULT_INTERVAL

static final int DEFAULT_INTERVAL
See Also:
Constant Field Values
Method Detail

delete

void delete(long companyId,
            String uid)
            throws SearchException
Throws:
SearchException

delete

@Bufferable
void delete(T object)
            throws SearchException
Throws:
SearchException

getClassName

String getClassName()

getClassNames

@Deprecated
String[] getClassNames()
Deprecated. As of 7.0.0, replaced by getSearchClassNames()


getDocument

Document getDocument(T object)
                     throws SearchException
Throws:
SearchException

getFacetBooleanFilter

BooleanFilter getFacetBooleanFilter(String className,
                                    SearchContext searchContext)
                                    throws Exception
Throws:
Exception

getFullQuery

BooleanQuery getFullQuery(SearchContext searchContext)
                          throws SearchException
Throws:
SearchException

getIndexerPostProcessors

IndexerPostProcessor[] getIndexerPostProcessors()

getPortletId

@Deprecated
String getPortletId()
Deprecated. As of 7.0.0, replaced by getClassName()


getSearchClassNames

String[] getSearchClassNames()

getSearchEngineId

String getSearchEngineId()

getSortField

String getSortField(String orderByCol)

getSortField

String getSortField(String orderByCol,
                    int sortType)

getSummary

@Deprecated
Summary getSummary(Document document,
                              Locale locale,
                              String snippet)
                   throws SearchException
Deprecated. As of 7.0.0, replaced by getSummary(Document, String, PortletRequest, PortletResponse)

Throws:
SearchException

getSummary

Summary getSummary(Document document,
                   String snippet,
                   PortletRequest portletRequest,
                   PortletResponse portletResponse)
                   throws SearchException
Throws:
SearchException

hasPermission

boolean hasPermission(PermissionChecker permissionChecker,
                      String entryClassName,
                      long entryClassPK,
                      String actionId)
                      throws Exception
Throws:
Exception

isCommitImmediately

boolean isCommitImmediately()

isFilterSearch

boolean isFilterSearch()
Return true if the indexer participates in post-search result filtering.

Returns:
true if the indexer participates in post-search result filtering; false otherwise
See Also:
SearchResultPermissionFilter

isIndexerEnabled

boolean isIndexerEnabled()

isPermissionAware

boolean isPermissionAware()
Returns true if the indexer adds permission related filters to the search query prior to execution

Returns:
true if the indexer adds permission related filters to the search query prior to execution; false otherwise
See Also:
SearchPermissionChecker

isStagingAware

boolean isStagingAware()

isVisible

boolean isVisible(long classPK,
                  int status)
                  throws Exception
Throws:
Exception

isVisibleRelatedEntry

boolean isVisibleRelatedEntry(long classPK,
                              int status)
                              throws Exception
Throws:
Exception

postProcessContextBooleanFilter

void postProcessContextBooleanFilter(BooleanFilter contextBooleanFilter,
                                     SearchContext searchContext)
                                     throws Exception
Throws:
Exception

postProcessContextQuery

@Deprecated
void postProcessContextQuery(BooleanQuery contextQuery,
                                        SearchContext searchContext)
                             throws Exception
Deprecated. As of 7.0.0, replaced by postProcessContextBooleanFilter(BooleanFilter, SearchContext)

Throws:
Exception

postProcessSearchQuery

void postProcessSearchQuery(BooleanQuery searchQuery,
                            BooleanFilter fullQueryBooleanFilter,
                            SearchContext searchContext)
                            throws Exception
Throws:
Exception

postProcessSearchQuery

@Deprecated
void postProcessSearchQuery(BooleanQuery searchQuery,
                                       SearchContext searchContext)
                            throws Exception
Deprecated. As of 7.0.0, replaced by postProcessSearchQuery(BooleanQuery, BooleanFilter, SearchContext)

Throws:
Exception

registerIndexerPostProcessor

void registerIndexerPostProcessor(IndexerPostProcessor indexerPostProcessor)

reindex

@Bufferable
void reindex(Collection<T> objects)
             throws SearchException
Throws:
SearchException

reindex

@Bufferable
void reindex(String className,
                        long classPK)
             throws SearchException
Throws:
SearchException

reindex

void reindex(String[] ids)
             throws SearchException
Throws:
SearchException

reindex

@Bufferable
void reindex(T object)
             throws SearchException
Throws:
SearchException

search

Hits search(SearchContext searchContext)
            throws SearchException
Throws:
SearchException

search

Hits search(SearchContext searchContext,
            String... selectedFieldNames)
            throws SearchException
Throws:
SearchException

searchCount

long searchCount(SearchContext searchContext)
                 throws SearchException
Throws:
SearchException

setIndexerEnabled

void setIndexerEnabled(boolean indexerEnabled)

unregisterIndexerPostProcessor

void unregisterIndexerPostProcessor(IndexerPostProcessor indexerPostProcessor)

Liferay 7.0-ce-b4