Java Calendar Create getCalendar(int dayOfWeek, int atHour, int atMinute)

Here you can find the source of getCalendar(int dayOfWeek, int atHour, int atMinute)

Description

get Calendar

License

Open Source License

Declaration

public static Calendar getCalendar(int dayOfWeek, int atHour, int atMinute) 

Method Source Code

//package com.java2s;
// The MIT License (MIT)

import java.util.Calendar;

import java.util.GregorianCalendar;

public class Main {
    public static Calendar getCalendar(int dayOfWeek, int atHour, int atMinute) {
        Calendar cal = new GregorianCalendar();

        cal.set(Calendar.DAY_OF_WEEK, dayOfWeek);
        cal.set(Calendar.HOUR_OF_DAY, atHour);
        cal.set(Calendar.MINUTE, atMinute);

        cal.set(Calendar.SECOND, 0);
        cal.set(Calendar.MILLISECOND, 0);
        return cal;
    }/*from   www.j  av  a  2  s  .c om*/
}

Related

  1. getCalendar(Calendar cal, int relativeDay)
  2. getCalendar(final Date dateAndTime)
  3. getCalendar(final long timeInMillis)
  4. getCalendar(final String isodate)
  5. getCalendar(int d, int m, int y)
  6. getCalendar(int year, int month, int date)
  7. getCalendar(int year, int month, int day)
  8. getCalendar(int year, int month, int day)
  9. getCalendar(int year, int month, int day, int hour, int min, int sec, String timezone)