List of utility methods to do Day
String | getDay(Date date) get Day DateFormat df = new SimpleDateFormat("dd"); df.setLenient(false); String day = df.format(date); if (day.startsWith("0")) return day.substring(1); return day; |
String | getDay(Date date) get Day return new SimpleDateFormat("dd").format(date); |
int | getDay(Date date) get Day calendar = Calendar.getInstance();
calendar.setTime(date);
return calendar.get(Calendar.DAY_OF_MONTH);
|
String | getDay(Date date) get Day return FormatDate(date, "dd"); |
int | getDay(Date date, HashMap get Day SimpleDateFormat dateformatYYYYMMDD = new SimpleDateFormat("yyyyMMdd"); String today = dateformatYYYYMMDD.format(date); int day = date2day.get(today); return day; |
java.util.Date | getDay(java.util.Date date) get Day java.util.Calendar cal = java.util.Calendar.getInstance(); cal.setTime(date); String s = new java.text.SimpleDateFormat("yyyy-MM-dd").format(cal.getTime()); SimpleDateFormat sf = new SimpleDateFormat("yyyy-MM-dd"); try { return sf.parse(s); } catch (ParseException e) { return null; ... |
int | getDay(SimpleDateFormat df, String dateStr) get Day Calendar c = Calendar.getInstance(); try { c.setTime(df.parse(dateStr)); } catch (ParseException e) { e.printStackTrace(); return c.get(Calendar.DATE); |
int | getDay(String aDate) get Day int myDay = -1; if (isValidObjectModelDate(aDate)) { Integer Day = new Integer(aDate.substring(8)); myDay = Day.intValue(); return myDay; |
String | GetDay(String agmipDate) Get Day Date date = apsim.parse(agmipDate); Calendar c = Calendar.getInstance(); c.setTime(date); return c.get(Calendar.DAY_OF_YEAR) + ""; |
int | getDAY(String strDate) Regresa el dia de la semana, dada la fecha DOMINGO, LUNES, MARTES, MIERCOLES, JUEVES, VIERNES, SABADO String dia = null;
Calendar calendar = Calendar.getInstance();
calendar.setTime(convertStringToDate(strDate));
return calendar.get(Calendar.DAY_OF_WEEK);
|