Calendar.setWeekDate(int weekYear, int weekOfYear, int dayOfWeek) has the following syntax.
public void setWeekDate(int weekYear, int weekOfYear, int dayOfWeek)
In the following code shows how to use Calendar.setWeekDate(int weekYear, int weekOfYear, int dayOfWeek) method.
//w w w .j av a 2 s.c o m import java.util.Calendar; public class Main { public static void main(String[] args) { Calendar now = Calendar.getInstance(); System.out.println(now.getTime()); now.setWeekDate(2013,12,2); System.out.println(now.getTime()); } }
The code above generates the following result.