borland Packages Class Hierarchy dx.text Package
java.lang.Object +----com.borland.dx.text.ItemFormatter +----com.borland.dx.text.VariantFormatter +----com.borland.dx.text.DateFormatter
Constructors Properties Methods
Implements Serializable
The DateFormatter
class uses a Variant
of type Variant.DATE
, which stores data in a java.sql.Date
object. This object is able to store time information; however, all time-related operations on java.sql.Date
objects are deprecated.
To work with time data, use TimeFormatter
or TimestampFormatter
.
public DateFormatter()Constructs a
DateFormatter
object.
public int getVariantType()Returns the
Variant
type, which is always Variant.DATE
for DateFormatter
classes.
public final String format(Variant value)Returns a
String
representing the given date stored in the Variant
. A returned empty string indicates a null or empty input value. null means the formatting failed.
value
String
.
public final void parse(String stringValue, Variant value)Analyzes the given
String
and produces as output a Variant
containing the approriate value.
stringValue
value
Variant
that receives the parsed result.