Created
February 24, 2019 18:39
-
-
Save caneryilmaz/a0a174d44206ac488c2effe605ff105c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class TimeHelper { | |
DateFormat df = new SimpleDateFormat("EEE, d MMM yyyy, HH:mm"); | |
String date = df.format(Calendar.getInstance().getTime()); | |
/* | |
"yyyy.MM.dd G 'at' HH:mm:ss z" ---- 2001.07.04 AD at 12:08:56 PDT | |
"hh 'o''clock' a, zzzz" ----------- 12 o'clock PM, Pacific Daylight Time | |
"EEE, d MMM yyyy HH:mm:ss Z"------- Wed, 4 Jul 2001 12:08:56 -0700 | |
"yyyy-MM-dd'T'HH:mm:ss.SSSZ"------- 2001-07-04T12:08:56.235-0700 | |
"yyMMddHHmmssZ"-------------------- 010704120856-0700 | |
"K:mm a, z" ----------------------- 0:08 PM, PDT | |
"h:mm a" -------------------------- 12:08 PM | |
"EEE, MMM d, ''yy" ---------------- Wed, Jul 4, '01 | |
*/ | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment