Class ReporterIndexer
java.lang.Object
com.atlassian.jira.search.issue.index.indexers.impl.ReporterIndexer
- All Implemented Interfaces:
FieldIndexer,FieldWithVisibilityIndexer
- Since:
- 10.4
-
Field Summary
Fields inherited from interface com.atlassian.jira.search.issue.index.indexers.FieldIndexer
LABELS_NO_VALUE_INDEX_VALUE, NO_VALUE_INDEX_VALUE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionDeclares the fields to be added to the index schemagetId()voidindexFieldsWithVisibility(FieldValueCollector collector, Issue issue, CustomFieldPrefetchedData prefetchedData, boolean visible) Enforce implementing indexFieldWithVisibility instead of indexFields.booleanisFieldVisibleAndInScope(Issue issue) This method is used to determine if the indexer is relevant for the provided issue.booleanUsed to declare how the indexer handles nulls.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.atlassian.jira.search.issue.index.indexers.FieldWithVisibilityIndexer
indexFields
-
Constructor Details
-
ReporterIndexer
-
-
Method Details
-
getId
- Specified by:
getIdin interfaceFieldIndexer- Returns:
- the String representation of the field id that this indexer is indexing, this must be unique for each independent FieldIndexer. If the Indexer does not represent a System or Custom field in Jira this should still return a unique string that describes the indexer.
-
getFields
Description copied from interface:FieldIndexerDeclares the fields to be added to the index schema- Specified by:
getFieldsin interfaceFieldIndexer
-
indexFieldsWithVisibility
public void indexFieldsWithVisibility(FieldValueCollector collector, Issue issue, CustomFieldPrefetchedData prefetchedData, boolean visible) Description copied from interface:FieldWithVisibilityIndexerEnforce implementing indexFieldWithVisibility instead of indexFields.- Specified by:
indexFieldsWithVisibilityin interfaceFieldIndexer- Specified by:
indexFieldsWithVisibilityin interfaceFieldWithVisibilityIndexer- Parameters:
collector- the collector for collecting indexed valuesissue- that is having a document created from.prefetchedData- if the custom field type implementedCustomFieldType.getNonNullCustomFieldProvider()this reference will hold the matching value returned fromNonNullCustomFieldProvider.getCustomFieldInfo(List <Issue>)*
-
isFieldVisibleAndInScope
Description copied from interface:FieldIndexerThis method is used to determine if the indexer is relevant for the provided issue. This method must check the fields visibility, in relation to the field configuration scheme, must check any global flags that would enable or disable a field (such as enable votes flag), and must check, if the field is a custom field, if the custom field is relevant for this issue.All these checks should take into account the
IssueContextas defined by the passed in issue.The result of this method is used to determine the correct values that should be returned when performing an empty search.
- Specified by:
isFieldVisibleAndInScopein interfaceFieldIndexer- Parameters:
issue- that is having a document created from.- Returns:
- if true then this field is relevant for the issue, otherwise it is not.
-
skipsIndexingNull
public boolean skipsIndexingNull()Description copied from interface:FieldIndexerUsed to declare how the indexer handles nulls.- Specified by:
skipsIndexingNullin interfaceFieldIndexer- Returns:
- true if the indexer doesn't do anything when the field value is null
-