Here you can find the source of getCurrentMonth()
@SuppressWarnings("deprecation") public static int getCurrentMonth()
//package com.java2s; import java.util.*; public class Main { @SuppressWarnings("deprecation") public static int getCurrentMonth() { return getCurrentDate().getMonth(); }/* w w w. java 2 s . c o m*/ @SuppressWarnings("deprecation") public static int getMonth(int i) { return getCurrentDate().getMonth(); } public static Date getCurrentDate() { return new Date(System.currentTimeMillis()); } }