Java Date Create createDates(int yy, int mm, int dd, int hh, int min, int ss)

Here you can find the source of createDates(int yy, int mm, int dd, int hh, int min, int ss)

Description

create Dates

License

Apache License

Declaration

public static Date createDates(int yy, int mm, int dd, int hh, int min, int ss) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.util.Calendar;
import java.util.Date;

public class Main {

    public static Date createDates(int yy, int mm, int dd, int hh, int min, int ss) {
        Calendar c1 = Calendar.getInstance();
        c1.set(Calendar.YEAR, yy);
        c1.set(Calendar.MONTH, mm);
        c1.set(Calendar.DAY_OF_MONTH, dd);
        c1.set(Calendar.HOUR_OF_DAY, hh);
        c1.set(Calendar.MINUTE, min);
        c1.set(Calendar.SECOND, ss);
        return c1.getTime();
    }/* w w  w.ja  v  a2s  . co m*/
}

Related

  1. createDate(int year, int month, int day)
  2. createDate(int year, int month, int day)
  3. createDate(int year, int month, int day, int hour, int minute, int second)
  4. createDate(int year, int month, int day, int hour, int minute, int second, int millisecond)
  5. createDateObject(Integer year, Integer month, Integer dayOfMonth, Integer hourOfDay, Integer minute, Integer second, Integer milissecond)
  6. createDateString(long startDate, long endDate)
  7. createDateTime(Date date, Date time)
  8. createDateTime(int year, int month, int day, int hour, int minute, int second, String timezone)
  9. createFutureDate()