Java Week Day isoDayOfWeek(int javaDayOfWeek)

Here you can find the source of isoDayOfWeek(int javaDayOfWeek)

Description

iso Day Of Week

License

Open Source License

Declaration

private static int isoDayOfWeek(int javaDayOfWeek) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import java.util.Calendar;

public class Main {
    private static int isoDayOfWeek(int javaDayOfWeek) {

        switch (javaDayOfWeek) {
        case Calendar.MONDAY:
            return 1;
        case Calendar.TUESDAY:
            return 2;
        case Calendar.WEDNESDAY:
            return 3;
        case Calendar.THURSDAY:
            return 4;
        case Calendar.FRIDAY:
            return 5;
        case Calendar.SATURDAY:
            return 6;
        case Calendar.SUNDAY:
            return 7;
        default:/*from   w  w  w  . j  a v a2 s .  co m*/
            throw new IllegalArgumentException("Invalid day of week " + javaDayOfWeek);
        }
    }
}

Related

  1. getWeekendDays(Locale locale)
  2. getWeekFirstDay(Date date)
  3. isDayOfWeek(int day)
  4. isDayOfWeek(String str, int dayOfWeek)
  5. isFirseDayOfCurrentWeek(Date date)
  6. isWeekday(String dateStr, String format)
  7. isWeekendDay(String strDay, DateFormat dateFormatter)
  8. isWeekendToday()
  9. lastDayOfWeek(int year, int month)