|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.JFormattedTextField.AbstractFormatter
com.sibvisions.rad.ui.swing.ext.text.DateFormatter
public class DateFormatter
The DateFormatter can handle null values and empty Strings and handle complex date formats.
| Constructor Summary | |
|---|---|
DateFormatter()
Constructs a new date formatter with default date format. |
|
DateFormatter(DateFormat pDateFormat)
Constructs a new date formatter that supports empty Strings and null values. |
|
| Method Summary | |
|---|---|
DateFormat |
getDateFormat()
Gets the date format. |
String |
getDatePattern()
Gets the date format pattern. |
void |
setDateFormat(DateFormat pDateFormat)
Gets the date format. |
void |
setDatePattern(String pDatePattern)
Gets the date format pattern. |
Object |
stringToValue(String pText)
|
String |
valueToString(Object pValue)
|
| Methods inherited from class javax.swing.JFormattedTextField.AbstractFormatter |
|---|
clone, getActions, getDocumentFilter, getFormattedTextField, getNavigationFilter, install, invalidEdit, setEditValid, uninstall |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DateFormatter()
public DateFormatter(DateFormat pDateFormat)
pDateFormat - the formatter that should support empty Strings and null values.| Method Detail |
|---|
public Object stringToValue(String pText)
throws ParseException
stringToValue in class JFormattedTextField.AbstractFormatterParseException
public String valueToString(Object pValue)
throws ParseException
valueToString in class JFormattedTextField.AbstractFormatterParseExceptionpublic DateFormat getDateFormat()
public void setDateFormat(DateFormat pDateFormat)
pDateFormat - the date format.public String getDatePattern()
public void setDatePattern(String pDatePattern)
pDatePattern - the date format pattern.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||