Java Calendar Create getCalendarDate()

Here you can find the source of getCalendarDate()

Description

Retrieve Calendar date.

License

Apache License

Declaration

public static Calendar getCalendarDate() 

Method Source Code

//package com.java2s;
/*// ww w  .  jav a  2s.c  o m
 ************************************************************************************
 * Copyright (C) 2001-2011 encuestame: system online surveys Copyright (C) 2011
 * encuestame Development Team.
 * Licensed under the Apache Software License version 2.0
 * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
 * Unless required by applicable law or agreed to  in writing,  software  distributed
 * under the License is distributed  on  an  "AS IS"  BASIS,  WITHOUT  WARRANTIES  OR
 * CONDITIONS OF ANY KIND, either  express  or  implied.  See  the  License  for  the
 * specific language governing permissions and limitations under the License.
 ************************************************************************************
 */

import java.util.Calendar;

public class Main {
    /**
     * Retrieve Calendar date.
     * @return
     */
    public static Calendar getCalendarDate() {
        final Calendar currentDate = Calendar.getInstance();
        currentDate.set(Calendar.SECOND, 0);
        return currentDate;
    }
}

Related

  1. getCalendarAtMidnight(Date d)
  2. getCalendarBefore(int i)
  3. getCalendarByName(String timeZone)
  4. getCalendarBySpecific(int year, int month, int date, int hour)
  5. getCalendarByValue(String timeZone)
  6. getCalendarDate(Calendar calendar)
  7. getCalendarDateFromToday(final int numDays)
  8. getCalendarDayString(Calendar date)
  9. getCalendarField(char c)