org.gcube.indexmanagement.common
Enum ForwardIndexField.DataType

java.lang.Object
  extended by java.lang.Enum<ForwardIndexField.DataType>
      extended by org.gcube.indexmanagement.common.ForwardIndexField.DataType
All Implemented Interfaces:
Serializable, Comparable<ForwardIndexField.DataType>
Enclosing class:
ForwardIndexField

public static enum ForwardIndexField.DataType
extends Enum<ForwardIndexField.DataType>

An enumeration of accepted data types, along with their respective Class objects and default byte size


Enum Constant Summary
DATE
          The DATE data type.
FLOAT
          The FLOAT data type.
INT
          The INT data type
STRING
          The STRING data type.
 
Method Summary
static ForwardIndexField.DataType getByName(String name)
          A case insensitive version of valueOf(String).
 int getDefaultSize()
          Getter method for the default byte size of this data type
 Class getTypeClass()
          Getter method for the Class object of this data type
static ForwardIndexField.DataType valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ForwardIndexField.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

INT

public static final ForwardIndexField.DataType INT
The INT data type


DATE

public static final ForwardIndexField.DataType DATE
The DATE data type.


FLOAT

public static final ForwardIndexField.DataType FLOAT
The FLOAT data type.


STRING

public static final ForwardIndexField.DataType STRING
The STRING data type.

Method Detail

values

public static ForwardIndexField.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 (ForwardIndexField.DataType c : ForwardIndexField.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 ForwardIndexField.DataType 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

getByName

public static ForwardIndexField.DataType getByName(String name)
                                            throws Exception
A case insensitive version of valueOf(String).

Parameters:
name - - the string value to gte the type for
Returns:
DataType of the input string name.
Throws:
IndexException - - in case of failure.
Exception

getTypeClass

public Class getTypeClass()
Getter method for the Class object of this data type

Returns:
the Class object of this data type

getDefaultSize

public int getDefaultSize()
Getter method for the default byte size of this data type

Returns:
the default byte size of this data type


Copyright © 2013. All Rights Reserved.