Пример #1
0
 // For the ending date, we want the end of the selected day which is
 public Date getEndDate() {
   gc.set(Calendar.DAY_OF_MONTH, (date + 1));
   gc.set(Calendar.AM_PM, Calendar.AM);
   gc.set(Calendar.HOUR, 23);
   gc.set(Calendar.MINUTE, 59);
   gc.set(Calendar.SECOND, 59);
   return (gc.getTime());
 }
Пример #2
0
 /** Refreshes the label's text according to the current date. */
 private void refresh() {
   setText(dateFormat.format(calendar.getTime()));
 }
Пример #3
0
 /**
  * Obtains the date associated with the label.
  *
  * @return The date.
  */
 Date getDate() {
   return calendar.getTime();
 }