Package org.gvsig.remoteclient.utils
Class DateTime
java.lang.Object
org.gvsig.remoteclient.utils.DateTime
This class contains static methods to manage Dates. It was principally
created because of some problems doing the "String do DateTime"
and the "DateTime to String" conversions.
- Author:
- Jorge Piera Llodr� (piera_jor@gva.es)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringdateToString(Date dtK, String sFormat) It trnasforms one date in one Stringstatic Datereturns the current datestatic DatestringToDate(String sDate) It transfoms one String in one Date
-
Constructor Details
-
DateTime
public DateTime()
-
-
Method Details
-
getCurrentDate
returns the current date- Returns:
- java.util.Date
-
dateToString
It trnasforms one date in one String- Parameters:
dtK- DatesFormat- Date format. Example: "Y-m-d H:i:s.Z";- Returns:
- A String
-
stringToDate
It transfoms one String in one Date- Parameters:
sDate- String- Returns:
- Date
-