Package com.atlassian.jira.issue.history
Class DateTimeFieldChangeLogHelperImpl
java.lang.Object
com.atlassian.jira.issue.history.DateTimeFieldChangeLogHelperImpl
- All Implemented Interfaces:
DateTimeFieldChangeLogHelper
public class DateTimeFieldChangeLogHelperImpl
extends Object
implements DateTimeFieldChangeLogHelper
- Since:
- v4.4
-
Constructor Summary
ConstructorsConstructorDescriptionDateTimeFieldChangeLogHelperImpl(DateTimeFormatterFactory dateTimeFormatterFactory) -
Method Summary
Modifier and TypeMethodDescriptionConverts a Date into a string representation for the issue change history.Converts a Date into a string representation for the issue change history.renderChangeHistoryValueDate(String dateValue, String dateStr) Use this method to render a value for the issue change history that has been stored using the method createChangelogValueForDateField().renderChangeHistoryValueDateTime(String dateTimeValue, String dateTimeString) Use this method to render a value for the issue change history that has been stored using the method createChangelogValueForDateTimeField().
-
Constructor Details
-
DateTimeFieldChangeLogHelperImpl
-
-
Method Details
-
createChangelogValueForDateTimeField
Description copied from interface:DateTimeFieldChangeLogHelperConverts a Date into a string representation for the issue change history. Call this method, if you want to store a change history value for a (custom)field which stores date AND time information.- Specified by:
createChangelogValueForDateTimeFieldin interfaceDateTimeFieldChangeLogHelper- Parameters:
date- the value Date of the (custome)field- Returns:
- a string representation of the date, which contains date AND time.
-
createChangelogValueForDateField
Description copied from interface:DateTimeFieldChangeLogHelperConverts a Date into a string representation for the issue change history. Call this method, if you want to store a change history value for a (custom)field which stores ONLY calendar date (day, month, year) information.- Specified by:
createChangelogValueForDateFieldin interfaceDateTimeFieldChangeLogHelper- Parameters:
date- date the value Date of the (custome)field- Returns:
- a string representation of the date.
-
renderChangeHistoryValueDate
Description copied from interface:DateTimeFieldChangeLogHelperUse this method to render a value for the issue change history that has been stored using the method createChangelogValueForDateField(). This value should contain only date information. Theformatter is used to render the change history value.invalid reference
com.atlassian.jira.datetime.DateTimeStyle.DATE- Specified by:
renderChangeHistoryValueDatein interfaceDateTimeFieldChangeLogHelper- Parameters:
dateValue- the value of theChangeHistoryItemdateStr- the string of theChangeHistoryItem, if it can't convert the dateValue it will return the dateStr.- Returns:
- either a formatted date string, if it failed to convert the value it return the dateStr.
-
renderChangeHistoryValueDateTime
Description copied from interface:DateTimeFieldChangeLogHelperUse this method to render a value for the issue change history that has been stored using the method createChangelogValueForDateTimeField(). This value should contain time AND time information. Theformatter is used to render the change history value.invalid reference
com.atlassian.jira.datetime.DateTimeStyle.DATE_TIME_PICKER- Specified by:
renderChangeHistoryValueDateTimein interfaceDateTimeFieldChangeLogHelper- Parameters:
dateTimeValue- the value of theChangeHistoryItemdateTimeString- the string of theChangeHistoryItem, if it can't convert the dateTimeValue it will return the dateStr.- Returns:
- either a formatted date string, if it failed to convert the value it return the dateTimeString.
-