MCPcopy Create free account
hub / github.com/MenoData/Time4J / valueOf

Method valueOf

base/src/main/java/net/time4j/Weekday.java:213–221  ·  view source on GitHub ↗
(int dayOfWeek)

Source from the content-addressed store, hash-verified

211 * @see Weekmodel#ISO
212 */
213 public static Weekday valueOf(int dayOfWeek) {
214
215 if ((dayOfWeek < 1) || (dayOfWeek > 7)) {
216 throw new IllegalArgumentException("Out of range: " + dayOfWeek);
217 }
218
219 return ENUMS[dayOfWeek - 1];
220
221 }
222
223 /**
224 * <p>Gets the enum-constant which corresponds to the given localized

Callers 15

valueOf_intMethod · 0.95
valueOf_int_WeekmodelMethod · 0.95
valueOf_YearMonthDayMethod · 0.95
max1Method · 0.95
readWeekmodelMethod · 0.95
WeekmodelMethod · 0.95
ofMethod · 0.95
getDayOfWeekMethod · 0.95
getWeekdayStartMethod · 0.95
getDayOfWeekMethod · 0.95

Calls 3

getDayOfWeekMethod · 0.95
getFirstDayOfWeekMethod · 0.65
getValueMethod · 0.65

Tested by 5

valueOf_intMethod · 0.76
valueOf_int_WeekmodelMethod · 0.76
valueOf_YearMonthDayMethod · 0.76
max1Method · 0.76