public class DateFieldFormatImpl extends Object implements DateFieldFormat
| Constructor and Description |
|---|
DateFieldFormatImpl(DateTimeFormatterFactory dateTimeFormatterFactory) |
| Modifier and Type | Method and Description |
|---|---|
String |
format(Date date)
Formats a date using the JIRA date format.
|
String |
formatDatePicker(Date date)
Formats the given date for usage in a date picker.
|
String |
getFormatHint()
Returns a string containing the format that this class is capable of parsing.
|
boolean |
isParseable(String releaseDate)
Returns a boolean indicating whether the given text contains a valid date.
|
Date |
parseDatePicker(String text)
Returns a date that is obtained by parsing the given text.
|
public DateFieldFormatImpl(DateTimeFormatterFactory dateTimeFormatterFactory)
public String format(Date date)
DateFieldFormatformat in interface DateFieldFormatdate - a Datepublic String formatDatePicker(Date date)
DateFieldFormatformatDatePicker in interface DateFieldFormatdate - a Datepublic Date parseDatePicker(String text) throws IllegalArgumentException
DateFieldFormatparseDatePicker in interface DateFieldFormattext - a String representation of a dateIllegalArgumentException - if the text cannot be parsedpublic boolean isParseable(String releaseDate)
DateFieldFormatisParseable in interface DateFieldFormatreleaseDate - a String representation of a datepublic String getFormatHint()
DateFieldFormatgetFormatHint in interface DateFieldFormatCopyright © 2002-2018 Atlassian. All Rights Reserved.