Class QuoteExpirationTimeConverter
- java.lang.Object
-
- de.hybris.platform.yacceleratorstorefront.util.QuoteExpirationTimeConverter
-
public final class QuoteExpirationTimeConverter extends java.lang.ObjectUtility class for converting quote expiration time.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.StringconvertDateToString(java.util.Date date, java.lang.String pattern, java.util.Locale locale)Converts quote expiration time fromDatetoString.static java.util.DateconvertStringToDate(java.lang.String date, java.lang.String pattern, java.util.Locale locale)Converts quote expiration time fromStringtoDateby adjusting the time part to end of day (23:59:59).
-
-
-
Method Detail
-
convertDateToString
public static java.lang.String convertDateToString(java.util.Date date, java.lang.String pattern, java.util.Locale locale)Converts quote expiration time fromDatetoString.- Parameters:
date- the date to be convertedpattern- the date pattern to be used for conversionlocale- the locale to be used for conversion- Returns:
- null or the string representation of the date as per provided date pattern
-
convertStringToDate
public static java.util.Date convertStringToDate(java.lang.String date, java.lang.String pattern, java.util.Locale locale)Converts quote expiration time fromStringtoDateby adjusting the time part to end of day (23:59:59).- Parameters:
date- the string representation of quote expiration timepattern- the date pattern to be used for conversionlocale- the locale to be used for conversion- Returns:
- null if the string representation of expiration time is null or empty, otherwise the
Dateobject
-
-