edu.nrao.sss.model.proposal
Enum ProfessionalStatus

java.lang.Object
  extended by java.lang.Enum<ProfessionalStatus>
      extended by edu.nrao.sss.model.proposal.ProfessionalStatus
All Implemented Interfaces:
Serializable, Comparable<ProfessionalStatus>

public enum ProfessionalStatus
extends Enum<ProfessionalStatus>

Placeholder for time when we integrate proposal work. An enumeration of professional status types.

Since:
2006-03-09
Version:
1.1

Enum Constant Summary
ALL_OTHERS
          Any status not covered by the other types.
GRADUATE
          The graduate student status.
UNDERGRADUATE
          The undergraduate student status.
 
Method Summary
static ProfessionalStatus fromString(String text)
          Returns the professional status represented by text.
static ProfessionalStatus getDefault()
          Returns a default professional status.
 String toString()
           
static ProfessionalStatus valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ProfessionalStatus[] 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, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

UNDERGRADUATE

public static final ProfessionalStatus UNDERGRADUATE
The undergraduate student status.

The acceptable names of this element (for use with getInstanceFromName(String)) are UNDERGRADUATE and Undergraduate Student.


GRADUATE

public static final ProfessionalStatus GRADUATE
The graduate student status.

The acceptable names of this element (for use with getInstanceFromName(String)) are GRADUATE and Graduate Student.


ALL_OTHERS

public static final ProfessionalStatus ALL_OTHERS
Any status not covered by the other types.

The acceptable names of this element (for use with getInstanceFromName(String)) are ALL_OTHERS and All Others.

This element is used to implement the Null Object Pattern. In situations where a method might be tempted to return null, this element is returned instead.

Method Detail

values

public static ProfessionalStatus[] 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 (ProfessionalStatus c : ProfessionalStatus.values())
    System.out.println(c);

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

valueOf

public static ProfessionalStatus 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

getDefault

public static ProfessionalStatus getDefault()
Returns a default professional status.

Returns:
a default professional status.

toString

public String toString()
Overrides:
toString in class Enum<ProfessionalStatus>

fromString

public static ProfessionalStatus fromString(String text)
Returns the professional status represented by text.

For details about the transformation, see EnumerationUtility.enumFromString(Class, String).

Parameters:
text - a text representation of a professional status.
Returns:
the professional status represented by text.


Copyright © 2009. All Rights Reserved.