Here you can find the source of monthDaysToIntWeekDays(String dayOfMonth)
public static int monthDaysToIntWeekDays(String dayOfMonth)
//package com.java2s; public class Main { static String[] daysOfWeek = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" }; /**/*from ww w . ja v a2 s. c o m*/ this would give the days in the range of 0-6 0 = Sun and 6= Sat*/ public static int monthDaysToIntWeekDays(String dayOfMonth) { int i; for (i = 0; i < daysOfWeek.length; i++) { if (dayOfMonth.equals(daysOfWeek[i])) { break; } } return i; } }