com.jgoodies.common.format
public final class EmptyDateFormat extends AbstractWrappedDateFormat
Often the empty value is {@code null} but you can construct an EmptyDateFormat with a given {@code Date}.
Examples:
new EmptyDateFormat(DateFormat.getDateInstance()); new EmptyDateFormat(DateFormat.getDateInstance(), new Date()); new EmptyDateFormat(DateFormat.getDateInstance(DateFormat.SHORT)); new EmptyDateFormat(DateFormat.getDateInstance(DateFormat.SHORT), new Date());
Version: $Revision: 1.6 $
Constructor Summary | |
---|---|
EmptyDateFormat(DateFormat delegate)
Constructs an {@code EmptyFormat} that wraps the given format
to convert {@code null} to the empty string and vice versa.
| |
EmptyDateFormat(DateFormat delegate, Date emptyValue)
Constructs an {@code EmptyFormat} that wraps the given format
to convert the given {@code emptyValue} to the empty string
and vice versa.
|
Parameters: delegate the format that handles the standard cases
Parameters: delegate the format that handles non-{@code null} values emptyValue the representation of the empty string