Class MailDateTime
- java.lang.Object
-
- com.levigo.jadice.server.javamail.MailDateTime
-
public class MailDateTime extends Object
Utility class to format a date in RFC 2822 date syntax (e.g. "Thu, 03 Apr 2008 20:14:49 XXXXX (CEST)") into localized variants. This class is used in the XSL:FO stylesheetemail-conversion/lib.xsl"
because there is no java library which implements the date-time functions of XSLT 2.0.- Since:
- jadice server 5.3.1.0
-
-
Constructor Summary
Constructors Constructor Description MailDateTime(String date, String dateStyle, String timeStyle, String lang)
Constructs a formatted date time instance.
-
-
-
Constructor Detail
-
MailDateTime
public MailDateTime(String date, String dateStyle, String timeStyle, String lang) throws ParseException
Constructs a formatted date time instance.- Parameters:
date
- A date in RFC 2822 syntaxdateStyle
- The requested date style (allowed values:FULL
,MEDIUM
,SHORT
andDEFAULT
)timeStyle
- The requested time style (see parameterdateStyle
)lang
- The requested language (IETF BCP 47, e.g.en
orde
)- Throws:
ParseException
- If the given date is not in RFC 2822 syntax- See Also:
DateFormat
,Locale.forLanguageTag(String)
-
-
Method Detail
-
parse
public static Date parse(String s) throws ParseException
- Throws:
ParseException
-
-