|
IMC Epclient 5.0.3 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectat.spardat.enterprise.fmt.IFmt
at.spardat.enterprise.fmt.ADateFmt
at.spardat.enterprise.fmt.ADateFmtJavaUtilText
This class wraps the default behaviour of the JDK regarding formatting and parsing of Dates. The provided styles are mapped to the corresponding styles of the class java.text.DateFormat.
| Field Summary |
| Fields inherited from class at.spardat.enterprise.fmt.ADateFmt |
FULL, LONG, MEDIUM, SHORT |
| Fields inherited from class at.spardat.enterprise.fmt.IFmt |
DEFAULT, LAST_STYLE, MANDATORY, style_ |
| Constructor Summary | |
ADateFmtJavaUtilText(int style,
java.util.Locale l)
Constructs an ADateFmt providing a style and a locale. |
|
ADateFmtJavaUtilText(java.lang.String pattern,
int style)
Constructs an ADateFmt providing a pattern as specified in java.text.SimpleDateFormat. |
|
ADateFmtJavaUtilText(java.lang.String pattern,
int style,
java.util.Locale locale)
Constructs an ADateFmt providing a pattern as specified in java.text.SimpleDateFormat. |
|
| Method Summary | |
java.lang.Object |
clone()
Returns a clone of this; |
java.lang.String |
format(java.lang.String internal)
Transforms an internal encoding to an external. |
boolean |
isLegalExternalChar(char aChar)
Examines whether a given character may be part of an external representation. |
boolean |
isOneWay()
An IFmt is one way, if the external encoding may be generated out of the internal, but not vice versa. |
int |
maxLenOfExternal()
Returns the maximum length an external string representation may have. |
java.lang.String |
parse(java.lang.String external)
Tries to transform an external encoding to an internal. |
| Methods inherited from class at.spardat.enterprise.fmt.ADateFmt |
checkDateRange, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getMax, getMaxDate, getMin, getMinDate, isLegalInternal, mayBeAppliedTo, setMax, setMaxDate, setMin, setMinDate |
| Methods inherited from class at.spardat.enterprise.fmt.IFmt |
checkMandatory, getStyle, isMandatory, setMandatory |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ADateFmtJavaUtilText(int style,
java.util.Locale l)
style - one of MANDATORY, SHORT, MEDIUM, LONG or FULL.l - the locale to use
public ADateFmtJavaUtilText(java.lang.String pattern,
int style)
pattern - see java.text.SimpleDateFormatstyle - may be MANDATORY
public ADateFmtJavaUtilText(java.lang.String pattern,
int style,
java.util.Locale locale)
pattern - see java.text.SimpleDateFormatstyle - may be MANDATORY| Method Detail |
public java.lang.String parse(java.lang.String external)
throws AParseException
IFmt
parse in class IFmtexternal - the external encoding
AParseException - if the external encoding cannot be successfully parsed.IFmt.parse(String)public java.lang.String format(java.lang.String internal)
IFmt
format in class IFmtinternal - the provided internal encoding. This String must satisfy the
condition isLegalInternal(), otherwise the behaviour of this
method is undefined.
IFmt.format(String)public int maxLenOfExternal()
IFmt
maxLenOfExternal in class IFmtIFmt.maxLenOfExternal()public boolean isLegalExternalChar(char aChar)
IFmt
isLegalExternalChar in class IFmtaChar - the character to check
IFmt.isLegalExternalChar(char)public boolean isOneWay()
IFmt
isOneWay in class IFmtIFmt.isOneWay()public java.lang.Object clone()
IFmt
clone in class IFmtIFmt.clone()
|
IMC Epclient 5.0.3 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||