Serializable
, Comparable<Weekday>
public enum Weekday extends Enum<Weekday>
Enum Constant | Description |
---|---|
FRIDAY |
|
MONDAY |
|
SATURDAY |
|
SUNDAY |
|
THURSDAY |
|
TUESDAY |
|
WEDNESDAY |
Modifier and Type | Method | Description |
---|---|---|
static Weekday |
fromCalendar(Calendar calendar) |
|
static Weekday |
fromNumber(int number) |
|
int |
number() |
|
int |
toCalendarDayOfWeek() |
|
static Weekday |
valueOf(String name) |
Returns the enum constant of this type with the specified name.
|
static Weekday[] |
values() |
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Weekday MONDAY
public static final Weekday TUESDAY
public static final Weekday WEDNESDAY
public static final Weekday THURSDAY
public static final Weekday FRIDAY
public static final Weekday SATURDAY
public static final Weekday SUNDAY
public static Weekday[] values()
for (Weekday c : Weekday.values()) System.out.println(c);
public static Weekday valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic int number()
public int toCalendarDayOfWeek()
public static Weekday fromNumber(int number)
number
- day of week.number
:th day of the week, starting with 1 for Monday.Copyright © 2021 Apptus Technologies AB. All rights reserved.