|
||||||||||
| 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(DateUtil pDateUtil)
Constructs a new date formatter that supports empty Strings and null values. |
|
| Method Summary | |
|---|---|
java.text.DateFormat |
getDateFormat()
Gets the date format. |
java.lang.String |
getDatePattern()
Gets the date format pattern. |
void |
setDateFormat(java.text.DateFormat pDateFormat)
Gets the date format. |
void |
setDatePattern(java.lang.String pDatePattern)
Gets the date format pattern. |
java.lang.Object |
stringToValue(java.lang.String pText)
|
java.lang.String |
valueToString(java.lang.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(DateUtil pDateUtil)
pDateUtil - the formatter that should support empty Strings and null values.| Method Detail |
|---|
public java.lang.Object stringToValue(java.lang.String pText)
throws java.text.ParseException
stringToValue in class javax.swing.JFormattedTextField.AbstractFormatterjava.text.ParseException
public java.lang.String valueToString(java.lang.Object pValue)
throws java.text.ParseException
valueToString in class javax.swing.JFormattedTextField.AbstractFormatterjava.text.ParseExceptionpublic java.text.DateFormat getDateFormat()
public void setDateFormat(java.text.DateFormat pDateFormat)
pDateFormat - the date format.public java.lang.String getDatePattern()
public void setDatePattern(java.lang.String pDatePattern)
pDatePattern - the date format pattern.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||