biweekly.util
Enum Recurrence.DayOfWeek

java.lang.Object
  extended by java.lang.Enum<Recurrence.DayOfWeek>
      extended by biweekly.util.Recurrence.DayOfWeek
All Implemented Interfaces:
Serializable, Comparable<Recurrence.DayOfWeek>
Enclosing class:
Recurrence

public static enum Recurrence.DayOfWeek
extends Enum<Recurrence.DayOfWeek>

Represents each of the seven days of the week.

Author:
Michael Angstadt

Enum Constant Summary
FRIDAY
           
MONDAY
           
SATURDAY
           
SUNDAY
           
THURSDAY
           
TUESDAY
           
WEDNESDAY
           
 
Method Summary
 String getAbbr()
          Gets the day's abbreviation.
static Recurrence.DayOfWeek valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Recurrence.DayOfWeek valueOfAbbr(String abbr)
          Gets a day by its abbreviation.
static Recurrence.DayOfWeek[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

MONDAY

public static final Recurrence.DayOfWeek MONDAY

TUESDAY

public static final Recurrence.DayOfWeek TUESDAY

WEDNESDAY

public static final Recurrence.DayOfWeek WEDNESDAY

THURSDAY

public static final Recurrence.DayOfWeek THURSDAY

FRIDAY

public static final Recurrence.DayOfWeek FRIDAY

SATURDAY

public static final Recurrence.DayOfWeek SATURDAY

SUNDAY

public static final Recurrence.DayOfWeek SUNDAY
Method Detail

values

public static Recurrence.DayOfWeek[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (Recurrence.DayOfWeek c : Recurrence.DayOfWeek.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Recurrence.DayOfWeek valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getAbbr

public String getAbbr()
Gets the day's abbreviation.

Returns:
the abbreviation (e.g. "MO" for Monday)

valueOfAbbr

public static Recurrence.DayOfWeek valueOfAbbr(String abbr)
Gets a day by its abbreviation.

Parameters:
abbr - the abbreviation (case-insensitive, e.g. "MO" for Monday)
Returns:
the day or null if not found


Copyright © 2013 Michael Angstadt. All Rights Reserved.