Here you can find the source of getDateOfYearWeek(int yearNum, int weekNum, int dayOfWeek)
private static Date getDateOfYearWeek(int yearNum, int weekNum, int dayOfWeek)
//package com.java2s; //License from project: Open Source License import java.util.Calendar; import java.util.Date; public class Main { private static final int DAYS_OF_A_WEEK = 7; private static Date getDateOfYearWeek(int yearNum, int weekNum, int dayOfWeek) { Calendar cal = Calendar.getInstance(); cal.setFirstDayOfWeek(Calendar.MONDAY); cal.set(Calendar.DAY_OF_WEEK, dayOfWeek); cal.setMinimalDaysInFirstWeek(DAYS_OF_A_WEEK); cal.set(Calendar.YEAR, yearNum); cal.set(Calendar.WEEK_OF_YEAR, weekNum); /*cal.set(Calendar.HOUR_OF_DAY, 0); cal.set(Calendar.MINUTE, 0);/*from w ww .ja v a2 s. com*/ cal.set(Calendar.SECOND, 0);*/ return cal.getTime(); } }