Here you can find the source of getFirstMiddleDayOfMonth(Date date)
public static Date getFirstMiddleDayOfMonth(Date date)
//package com.java2s; //License from project: Open Source License import java.util.Calendar; import java.util.Date; public class Main { public static Date getFirstMiddleDayOfMonth(Date date) { Calendar todayCalendar = Calendar.getInstance(); todayCalendar.setTime(date);/*www . j a v a 2 s. co m*/ Calendar firstMiddleDayOfmonthCalendar = Calendar.getInstance(); firstMiddleDayOfmonthCalendar.set(todayCalendar.get(Calendar.YEAR), todayCalendar.get(Calendar.MONTH), 16, 0, 0, 0); return firstMiddleDayOfmonthCalendar.getTime(); } }