Package com.atlassian.jira.issue.history
Class AbstractDateRangeBuilder
java.lang.Object
com.atlassian.jira.issue.history.AbstractDateRangeBuilder
- All Implemented Interfaces:
DateRangeBuilder
- Direct Known Subclasses:
AssigneeDateRangeBuilder,PriorityDateRangeBuilder,ReporterDateRangeBuilder,ResolutionDateRangeBuilder,StatusDateRangeBuilder,VersionDateRangeBuilder
Abstract implementation of DateRangeBuilder - gprovides a buildDateRanges that will work for all single value system fields.
- Since:
- v4.4
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final LongConvenient constant for date range builders to use as the initial value provided toChangeHistoryItem.Builder.withId(Long)andChangeHistoryItem.Builder.inChangeGroup(Long), since thelong(non-object) argument forms have been deprecated. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuildDateRanges(Issue issue, List<ChangeHistoryItem> items) protected ChangeHistoryItem.BuilderchangeItemBuilder(Issue issue) protected ChangeHistoryItemcreateChangeItem(ChangeHistoryItem changeItem, Timestamp nextChange) protected abstract ChangeHistoryItemcreateInitialChangeItem(Issue issue) protected StringgetField()
-
Field Details
-
MINUS_1
Convenient constant for date range builders to use as the initial value provided toChangeHistoryItem.Builder.withId(Long)andChangeHistoryItem.Builder.inChangeGroup(Long), since thelong(non-object) argument forms have been deprecated.- Since:
- 6.0
-
-
Constructor Details
-
AbstractDateRangeBuilder
-
-
Method Details
-
buildDateRanges
- Specified by:
buildDateRangesin interfaceDateRangeBuilder- Parameters:
issue- The issue that is being currently indexeditems- A Collection of all the @link ChangeHistoryItem)s for that issue.- Returns:
- A list of items with date ranges This method then iterates the list and creates the date ranges - it also ensures there is always an 'initial' change state.
-
createChangeItem
-
changeItemBuilder
-
createInitialChangeItem
-
getField
-
getEmptyValue
- Specified by:
getEmptyValuein interfaceDateRangeBuilder
-