Class DateConverter
- java.lang.Object
-
- org.verapdf.metadata.fixer.gf.utils.DateConverter
-
public class DateConverter extends Object
Utility class for converting dates to different formats- Author:
- Maksim Bezrukov
-
-
Constructor Summary
Constructors Constructor Description DateConverter()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Calendar
toCalendar(String date)
Convert string representation of date toCalendar
objectstatic String
toPDFFormat(String date)
Convert string representation of date to string representation of date in PDF formatstatic String
toPDFFormat(Calendar date)
ConvertCalendar
date to string representation of date in PDF formatstatic String
toUTCString(String date)
Convert string date representation to string representation in UTC form.static String
toUTCString(Calendar calendar)
ConvertCalendar
object to string representation in UTC formstatic String
toUTCString(Date time)
ConvertDate
object to string representation in UTC form
-
-
-
Method Detail
-
toUTCString
public static String toUTCString(Calendar calendar)
ConvertCalendar
object to string representation in UTC form- Parameters:
calendar
- passed date- Returns:
- string representation of passed date
-
toUTCString
public static String toUTCString(Date time)
ConvertDate
object to string representation in UTC form- Parameters:
time
- passed date- Returns:
- string representation of passed date
-
toUTCString
public static String toUTCString(String date)
Convert string date representation to string representation in UTC form. Note: current implementation is not effective- Parameters:
date
- passed date- Returns:
- UTC string representation of passed date
-
toCalendar
public static Calendar toCalendar(String date)
Convert string representation of date toCalendar
object- Parameters:
date
- passed string date- Returns:
Calendar
date
-
toPDFFormat
public static String toPDFFormat(String date)
Convert string representation of date to string representation of date in PDF format- Parameters:
date
- passed date- Returns:
- PDF string representation of passed date
-
-