Here you can find the source of getMonthName(int index)
public static String getMonthName(int index)
//package com.java2s; //License from project: Apache License public class Main { /**//from www .j a va 2 s .c o m * This method returns the numeric value in string so that further it can be * concanated with other value strings like day,hours,min,seconds at the * time of getting eraseTime at savingTransaction. * * @param month - * String values like "Jan","Feb"....etc. * @return String */ private static String[] monthNames = { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" }; public static String getMonthName(int index) { if (index >= 1 && index <= 12) { return monthNames[index - 1]; } return ""; } }