List of usage examples for java.util Locale US
Locale US
To view the source code for java.util Locale US.
Click Source Link
From source file:Main.java
public static String getDay() { return Calendar.getInstance().getDisplayName(Calendar.DAY_OF_WEEK, Calendar.SHORT, Locale.US); }
From source file:Main.java
public static SimpleDateFormat getDateFormat() { SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd", Locale.US); format.setTimeZone(java.util.TimeZone.getTimeZone("UTC")); return format; }
From source file:Main.java
static String currentDate() { SimpleDateFormat sdf = new SimpleDateFormat("yyyy.MM.dd", Locale.US); return sdf.format(new Date()); }
From source file:Main.java
public static SimpleDateFormat getDateFormat() { SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.US); format.setTimeZone(java.util.TimeZone.getTimeZone("UTC")); return format; }
From source file:Main.java
public static SimpleDateFormat getDateFormat() { SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.US); format.setTimeZone(TimeZone.getTimeZone("UTC")); return format; }
From source file:Main.java
static String getDateString(String format) { SimpleDateFormat sdf = new SimpleDateFormat(format, Locale.US); return sdf.format(new Date()); }
From source file:Main.java
static String currentDateTime() { SimpleDateFormat sdf = new SimpleDateFormat("yyyy.MM.dd-hh:mm", Locale.US); return sdf.format(new Date()); }
From source file:Main.java
public static String getMapTileURL(String mapID, String accessToken, int zoom, int x, int y) { return String.format(Locale.US, "https://a.tiles.mapbox.com/v4/%s/%d/%d/%d%s.%s?access_token=%s", mapID, zoom, x, y, "@2x", "png", accessToken); }
From source file:Main.java
public static SimpleDateFormat getDateTimeFormat() { SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.US); format.setTimeZone(java.util.TimeZone.getTimeZone("UTC")); return format; }
From source file:Main.java
public static String getRecentDateFormat(long time) { return new SimpleDateFormat("yyyy/MM/dd/a h:mm", Locale.US).format(new Date(time)); }