gov.nih.nci.caarray.domain.data
Enum DataType

java.lang.Object
  extended by java.lang.Enum<DataType>
      extended by gov.nih.nci.caarray.domain.data.DataType
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<DataType>

public enum DataType
extends java.lang.Enum<DataType>

Enumerates the data types allowed for quantitation types.


Enum Constant Summary
BOOLEAN
          Values should be represented as Java boolean primitives.
DOUBLE
          Values should be represented as Java double primitives.
FLOAT
          Values should be represented as Java float primitives.
INTEGER
          Values should be represented as Java int primitives.
LONG
          Values should be represented as Java long primitives.
SHORT
          Values should be represented as Java short primitives.
STRING
          Values should be represented as Java Strings.
 
Method Summary
static DataType fromTypeClass(java.lang.Class<?> typeClass)
          Returns the DataType enumeration value corresponding to the given type class.
 java.lang.String getName()
           
 java.lang.Class<?> getTypeClass()
          Returns the Java class that corresponds to the data type.
static DataType valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static DataType[] 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

BOOLEAN

public static final DataType BOOLEAN
Values should be represented as Java boolean primitives.


SHORT

public static final DataType SHORT
Values should be represented as Java short primitives.


INTEGER

public static final DataType INTEGER
Values should be represented as Java int primitives.


LONG

public static final DataType LONG
Values should be represented as Java long primitives.


FLOAT

public static final DataType FLOAT
Values should be represented as Java float primitives.


DOUBLE

public static final DataType DOUBLE
Values should be represented as Java double primitives.


STRING

public static final DataType STRING
Values should be represented as Java Strings.

Method Detail

values

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

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

valueOf

public static DataType valueOf(java.lang.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:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

fromTypeClass

public static DataType fromTypeClass(java.lang.Class<?> typeClass)
Returns the DataType enumeration value corresponding to the given type class.

Parameters:
typeClass - the type class
Returns:
the matching DataType

getTypeClass

public java.lang.Class<?> getTypeClass()
Returns the Java class that corresponds to the data type.

Returns:
the corresponding class.

getName

public java.lang.String getName()
Returns:
result of calling name(), to enable retrieving it using JavaBean conventions.